Skip to content

Commit

Permalink
sparc64: Use correct pt_regs in decode_access_size() error paths.
Browse files Browse the repository at this point in the history
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
David S. Miller committed Apr 19, 2010
1 parent 6c94b1e commit baa0677
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions arch/sparc/kernel/unaligned_64.c
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ static inline enum direction decode_direction(unsigned int insn)
}

/* 16 = double-word, 8 = extra-word, 4 = word, 2 = half-word */
static inline int decode_access_size(unsigned int insn)
static inline int decode_access_size(struct pt_regs *regs, unsigned int insn)
{
unsigned int tmp;

Expand All @@ -66,7 +66,7 @@ static inline int decode_access_size(unsigned int insn)
return 2;
else {
printk("Impossible unaligned trap. insn=%08x\n", insn);
die_if_kernel("Byte sized unaligned access?!?!", current_thread_info()->kregs);
die_if_kernel("Byte sized unaligned access?!?!", regs);

/* GCC should never warn that control reaches the end
* of this function without returning a value because
Expand Down Expand Up @@ -286,7 +286,7 @@ static void log_unaligned(struct pt_regs *regs)
asmlinkage void kernel_unaligned_trap(struct pt_regs *regs, unsigned int insn)
{
enum direction dir = decode_direction(insn);
int size = decode_access_size(insn);
int size = decode_access_size(regs, insn);
int orig_asi, asi;

current_thread_info()->kern_una_regs = regs;
Expand Down

0 comments on commit baa0677

Please sign in to comment.