Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 356699
b: refs/heads/master
c: 12890d0
h: refs/heads/master
i:
  356697: 046c600
  356695: 50ac3ae
v: v3
  • Loading branch information
Ralf Baechle committed Dec 27, 2012
1 parent 729833c commit a11af6a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 13 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: f2ace93136cade6904a71d26e2f4768eef3b9aa3
refs/heads/master: 12890d0f61fc4ed4c3afbb1982df382aa9905834
17 changes: 5 additions & 12 deletions trunk/arch/mips/kernel/syscall.c
Original file line number Diff line number Diff line change
Expand Up @@ -138,10 +138,10 @@ SYSCALL_DEFINE1(set_thread_area, unsigned long, addr)
return 0;
}

static inline int mips_atomic_set(struct pt_regs *regs,
unsigned long addr, unsigned long new)
static inline int mips_atomic_set(unsigned long addr, unsigned long new)
{
unsigned long old, tmp;
struct pt_regs *regs;
unsigned int err;

if (unlikely(addr & 3))
Expand Down Expand Up @@ -222,6 +222,7 @@ static inline int mips_atomic_set(struct pt_regs *regs,
if (unlikely(err))
return err;

regs = current_pt_regs();
regs->regs[2] = old;
regs->regs[7] = 0; /* No error */

Expand All @@ -238,19 +239,11 @@ static inline int mips_atomic_set(struct pt_regs *regs,
unreachable();
}

save_static_function(sys_sysmips);
static int __used noinline
_sys_sysmips(nabi_no_regargs struct pt_regs regs)
SYSCALL_DEFINE3(sysmips, long, cmd, long, arg1, long, arg2)
{
long cmd, arg1, arg2;

cmd = regs.regs[4];
arg1 = regs.regs[5];
arg2 = regs.regs[6];

switch (cmd) {
case MIPS_ATOMIC_SET:
return mips_atomic_set(&regs, arg1, arg2);
return mips_atomic_set(arg1, arg2);

case MIPS_FIXADE:
if (arg1 & ~3)
Expand Down

0 comments on commit a11af6a

Please sign in to comment.