Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
linux-davinci-2.6.23
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
linux
linux-davinci-2.6.23
Commits
3c97b5e9
Commit
3c97b5e9
authored
Dec 07, 2006
by
Kyle McMartin
Committed by
Kyle McMartin
Dec 08, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[PARISC] Move spinlock_t out of struct cpu_data
Signed-off-by:
Kyle McMartin
<
kyle@parisc-linux.org
>
parent
6858f3bf
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
5 deletions
+7
-5
arch/parisc/kernel/smp.c
arch/parisc/kernel/smp.c
+7
-4
include/asm-parisc/processor.h
include/asm-parisc/processor.h
+0
-1
No files found.
arch/parisc/kernel/smp.c
View file @
3c97b5e9
...
@@ -76,6 +76,7 @@ cpumask_t cpu_possible_map __read_mostly = CPU_MASK_ALL; /* Bitmap of Present CP
...
@@ -76,6 +76,7 @@ cpumask_t cpu_possible_map __read_mostly = CPU_MASK_ALL; /* Bitmap of Present CP
EXPORT_SYMBOL
(
cpu_online_map
);
EXPORT_SYMBOL
(
cpu_online_map
);
EXPORT_SYMBOL
(
cpu_possible_map
);
EXPORT_SYMBOL
(
cpu_possible_map
);
DEFINE_PER_CPU
(
spinlock_t
,
ipi_lock
)
=
SPIN_LOCK_UNLOCKED
;
struct
smp_call_struct
{
struct
smp_call_struct
{
void
(
*
func
)
(
void
*
info
);
void
(
*
func
)
(
void
*
info
);
...
@@ -167,10 +168,11 @@ ipi_interrupt(int irq, void *dev_id)
...
@@ -167,10 +168,11 @@ ipi_interrupt(int irq, void *dev_id)
mb
();
/* Order interrupt and bit testing. */
mb
();
/* Order interrupt and bit testing. */
for
(;;)
{
for
(;;)
{
spin_lock_irqsave
(
&
(
p
->
lock
),
flags
);
spinlock_t
*
lock
=
&
per_cpu
(
ipi_lock
,
this_cpu
);
spin_lock_irqsave
(
lock
,
flags
);
ops
=
p
->
pending_ipi
;
ops
=
p
->
pending_ipi
;
p
->
pending_ipi
=
0
;
p
->
pending_ipi
=
0
;
spin_unlock_irqrestore
(
&
(
p
->
lock
),
flags
);
spin_unlock_irqrestore
(
lock
,
flags
);
mb
();
/* Order bit clearing and data access. */
mb
();
/* Order bit clearing and data access. */
...
@@ -275,12 +277,13 @@ static inline void
...
@@ -275,12 +277,13 @@ static inline void
ipi_send
(
int
cpu
,
enum
ipi_message_type
op
)
ipi_send
(
int
cpu
,
enum
ipi_message_type
op
)
{
{
struct
cpuinfo_parisc
*
p
=
&
cpu_data
[
cpu
];
struct
cpuinfo_parisc
*
p
=
&
cpu_data
[
cpu
];
spinlock_t
*
lock
=
&
per_cpu
(
ipi_lock
,
cpu
);
unsigned
long
flags
;
unsigned
long
flags
;
spin_lock_irqsave
(
&
(
p
->
lock
),
flags
);
spin_lock_irqsave
(
lock
,
flags
);
p
->
pending_ipi
|=
1
<<
op
;
p
->
pending_ipi
|=
1
<<
op
;
gsc_writel
(
IPI_IRQ
-
CPU_IRQ_BASE
,
cpu_data
[
cpu
].
hpa
);
gsc_writel
(
IPI_IRQ
-
CPU_IRQ_BASE
,
cpu_data
[
cpu
].
hpa
);
spin_unlock_irqrestore
(
&
(
p
->
lock
),
flags
);
spin_unlock_irqrestore
(
lock
,
flags
);
}
}
...
...
include/asm-parisc/processor.h
View file @
3c97b5e9
...
@@ -87,7 +87,6 @@ struct cpuinfo_parisc {
...
@@ -87,7 +87,6 @@ struct cpuinfo_parisc {
unsigned
long
hpa
;
/* Host Physical address */
unsigned
long
hpa
;
/* Host Physical address */
unsigned
long
txn_addr
;
/* MMIO addr of EIR or id_eid */
unsigned
long
txn_addr
;
/* MMIO addr of EIR or id_eid */
#ifdef CONFIG_SMP
#ifdef CONFIG_SMP
spinlock_t
lock
;
/* synchronization for ipi's */
unsigned
long
pending_ipi
;
/* bitmap of type ipi_message_type */
unsigned
long
pending_ipi
;
/* bitmap of type ipi_message_type */
unsigned
long
ipi_count
;
/* number ipi Interrupts */
unsigned
long
ipi_count
;
/* number ipi Interrupts */
#endif
#endif
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment