Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
linux
Commits
5772f6de
Commit
5772f6de
authored
Feb 27, 2010
by
Ralf Baechle
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
MIPS: SB1250: Convert IRQ controller lock to raw spinlock.
Signed-off-by:
Ralf Baechle
<
ralf@linux-mips.org
>
parent
f2c194a0
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
7 deletions
+7
-7
arch/mips/sibyte/sb1250/irq.c
arch/mips/sibyte/sb1250/irq.c
+7
-7
No files found.
arch/mips/sibyte/sb1250/irq.c
View file @
5772f6de
...
...
@@ -72,20 +72,20 @@ static struct irq_chip sb1250_irq_type = {
/* Store the CPU id (not the logical number) */
int
sb1250_irq_owner
[
SB1250_NR_IRQS
];
static
DEFINE_SPINLOCK
(
sb1250_imr_lock
);
static
DEFINE_
RAW_
SPINLOCK
(
sb1250_imr_lock
);
void
sb1250_mask_irq
(
int
cpu
,
int
irq
)
{
unsigned
long
flags
;
u64
cur_ints
;
spin_lock_irqsave
(
&
sb1250_imr_lock
,
flags
);
raw_
spin_lock_irqsave
(
&
sb1250_imr_lock
,
flags
);
cur_ints
=
____raw_readq
(
IOADDR
(
A_IMR_MAPPER
(
cpu
)
+
R_IMR_INTERRUPT_MASK
));
cur_ints
|=
(((
u64
)
1
)
<<
irq
);
____raw_writeq
(
cur_ints
,
IOADDR
(
A_IMR_MAPPER
(
cpu
)
+
R_IMR_INTERRUPT_MASK
));
spin_unlock_irqrestore
(
&
sb1250_imr_lock
,
flags
);
raw_
spin_unlock_irqrestore
(
&
sb1250_imr_lock
,
flags
);
}
void
sb1250_unmask_irq
(
int
cpu
,
int
irq
)
...
...
@@ -93,13 +93,13 @@ void sb1250_unmask_irq(int cpu, int irq)
unsigned
long
flags
;
u64
cur_ints
;
spin_lock_irqsave
(
&
sb1250_imr_lock
,
flags
);
raw_
spin_lock_irqsave
(
&
sb1250_imr_lock
,
flags
);
cur_ints
=
____raw_readq
(
IOADDR
(
A_IMR_MAPPER
(
cpu
)
+
R_IMR_INTERRUPT_MASK
));
cur_ints
&=
~
(((
u64
)
1
)
<<
irq
);
____raw_writeq
(
cur_ints
,
IOADDR
(
A_IMR_MAPPER
(
cpu
)
+
R_IMR_INTERRUPT_MASK
));
spin_unlock_irqrestore
(
&
sb1250_imr_lock
,
flags
);
raw_
spin_unlock_irqrestore
(
&
sb1250_imr_lock
,
flags
);
}
#ifdef CONFIG_SMP
...
...
@@ -115,7 +115,7 @@ static int sb1250_set_affinity(unsigned int irq, const struct cpumask *mask)
cpu
=
cpu_logical_map
(
i
);
/* Protect against other affinity changers and IMR manipulation */
spin_lock_irqsave
(
&
sb1250_imr_lock
,
flags
);
raw_
spin_lock_irqsave
(
&
sb1250_imr_lock
,
flags
);
/* Swizzle each CPU's IMR (but leave the IP selection alone) */
old_cpu
=
sb1250_irq_owner
[
irq
];
...
...
@@ -137,7 +137,7 @@ static int sb1250_set_affinity(unsigned int irq, const struct cpumask *mask)
____raw_writeq
(
cur_ints
,
IOADDR
(
A_IMR_MAPPER
(
cpu
)
+
R_IMR_INTERRUPT_MASK
));
}
spin_unlock_irqrestore
(
&
sb1250_imr_lock
,
flags
);
raw_
spin_unlock_irqrestore
(
&
sb1250_imr_lock
,
flags
);
return
0
;
}
...
...
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