[Top] [All Lists]

Re: [PATCH] mips_atomic_set fixups (with LLSC)

Subject: Re: [PATCH] mips_atomic_set fixups (with LLSC)
From: Ralf Baechle <>
Date: Thu, 6 Dec 2001 15:17:59 -0200
In-reply-to: <>; from on Thu, Dec 06, 2001 at 03:43:54PM +1000
References: <>
User-agent: Mutt/1.2.5i
On Thu, Dec 06, 2001 at 03:43:54PM +1000, Liam Davies wrote:

> The kernel can be caused to crash when making the following syscall
> sysmips(MIPS_ATOMIC_SET, [unaligned addr], value, 0);
> The latest mips_atomic_set does not use the fixups that are defined
> for the ll/sc instructions.
> If an unaligned address is passed in we take the exception and
> unaligned.c:emulate_load_store_insn ignores the fixups for the
> ll/sc and sends a SIGBUS instead, thus causing the kernel to die.

An unaligned ll/sc instruction in the kernel is a bug in itself as such
it's not unaligned.c that is to blame.  As such I'm going to checkin
a patch that is close but not identical to your patch.

Blame me for this bug, I *knew* and forgot about it ...


<Prev in Thread] Current Thread [Next in Thread>