Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 162721
b: refs/heads/master
c: 9264949
h: refs/heads/master
i:
  162719: 6517453
v: v3
  • Loading branch information
Mike Frysinger committed Sep 17, 2009
1 parent a2a8459 commit bd558a0
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 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: dac981740f4b990eadf523b0900859f189dd2b4e
refs/heads/master: 926494943b7d9dbc998adb298a92a708232ce46b
10 changes: 2 additions & 8 deletions trunk/arch/blackfin/kernel/process.c
Original file line number Diff line number Diff line change
Expand Up @@ -282,25 +282,19 @@ void finish_atomic_sections (struct pt_regs *regs)
{
int __user *up0 = (int __user *)regs->p0;

if (regs->pc < ATOMIC_SEQS_START || regs->pc >= ATOMIC_SEQS_END)
return;

switch (regs->pc) {
case ATOMIC_XCHG32 + 2:
put_user(regs->r1, up0);
regs->pc += 2;
regs->pc = ATOMIC_XCHG32 + 4;
break;

case ATOMIC_CAS32 + 2:
case ATOMIC_CAS32 + 4:
if (regs->r0 == regs->r1)
case ATOMIC_CAS32 + 6:
put_user(regs->r2, up0);
regs->pc = ATOMIC_CAS32 + 8;
break;
case ATOMIC_CAS32 + 6:
put_user(regs->r2, up0);
regs->pc += 2;
break;

case ATOMIC_ADD32 + 2:
regs->r0 = regs->r1 + regs->r0;
Expand Down
6 changes: 6 additions & 0 deletions trunk/arch/blackfin/mach-common/entry.S
Original file line number Diff line number Diff line change
Expand Up @@ -1025,6 +1025,12 @@ ENTRY(_schedule_and_signal_from_int)
#endif
sti r0;

/* finish the userspace "atomic" functions for it */
r1 = FIXED_CODE_END;
r2 = [sp + PT_PC];
cc = r1 <= r2;
if cc jump .Lresume_userspace (bp);

r0 = sp;
sp += -12;
call _finish_atomic_sections;
Expand Down

0 comments on commit bd558a0

Please sign in to comment.