[systemd-devel] [PATCH] Fix broken syscall(__NR_fanotify_mark... on 32bit mips.

David Daney ddaney at caviumnetworks.com
Wed Apr 20 18:05:36 PDT 2011


On 04/20/2011 06:02 PM, fykcee1 at gmail.com wrote:
> 2011/4/21 David Daney<ddaney at caviumnetworks.com>:
>>> Any comment whether this will break non-MIPS 32bit archs, like x86?
>>
>> It would break the MIPS n32 ABI userspace.
>>
>> On MIPS n32 we are still __LP64__, but 64-bit values are passed in a single
>> register.
> It isn't a problem. n32 syscall supports 64bit registers, and 64-bit
> values should be passed in a single register. see
> http://lxr.linux.no/linux+v2.6.38/arch/mips/kernel/scall64-n32.S#L426
> (calls sys_fanotify_mark instead of sys_32_fanotify_mark,
> sys_fanotify_mark won't merge_64(mask_low, merge_high))
>

What are you talking about?

If you split the mask argument across two registers, it will not work in 
n32.  That is why the mask splitting code must be confined to only the 
o32 ABI.

David Daney


More information about the systemd-devel mailing list