Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 60584
b: refs/heads/master
c: a354ab8
h: refs/heads/master
v: v3
  • Loading branch information
Geoff Levand authored and Paul Mackerras committed Jun 28, 2007
1 parent 73843e4 commit fb1a260
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 25 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: aab835007097122c3a1e7a7dddda0cf89a94cd4e
refs/heads/master: a354ab8557566e9462ea7af20345f6927e6665b3
26 changes: 2 additions & 24 deletions trunk/arch/powerpc/platforms/ps3/interrupt.c
Original file line number Diff line number Diff line change
Expand Up @@ -100,24 +100,13 @@ static DEFINE_PER_CPU(struct ps3_private, ps3_private);
static void ps3_chip_mask(unsigned int virq)
{
struct ps3_private *pd = get_irq_chip_data(virq);
u64 bit = 0x8000000000000000UL >> virq;
u64 *p = &pd->bmp.mask;
u64 old;
unsigned long flags;

pr_debug("%s:%d: thread_id %lu, virq %d\n", __func__, __LINE__,
pd->thread_id, virq);

local_irq_save(flags);
asm volatile(
"1: ldarx %0,0,%3\n"
"andc %0,%0,%2\n"
"stdcx. %0,0,%3\n"
"bne- 1b"
: "=&r" (old), "+m" (*p)
: "r" (bit), "r" (p)
: "cc" );

clear_bit(63 - virq, &pd->bmp.mask);
lv1_did_update_interrupt_mask(pd->ppe_id, pd->thread_id);
local_irq_restore(flags);
}
Expand All @@ -132,24 +121,13 @@ static void ps3_chip_mask(unsigned int virq)
static void ps3_chip_unmask(unsigned int virq)
{
struct ps3_private *pd = get_irq_chip_data(virq);
u64 bit = 0x8000000000000000UL >> virq;
u64 *p = &pd->bmp.mask;
u64 old;
unsigned long flags;

pr_debug("%s:%d: thread_id %lu, virq %d\n", __func__, __LINE__,
pd->thread_id, virq);

local_irq_save(flags);
asm volatile(
"1: ldarx %0,0,%3\n"
"or %0,%0,%2\n"
"stdcx. %0,0,%3\n"
"bne- 1b"
: "=&r" (old), "+m" (*p)
: "r" (bit), "r" (p)
: "cc" );

set_bit(63 - virq, &pd->bmp.mask);
lv1_did_update_interrupt_mask(pd->ppe_id, pd->thread_id);
local_irq_restore(flags);
}
Expand Down

0 comments on commit fb1a260

Please sign in to comment.