On Tue, Nov 26, 2013 at 09:05:59PM +0100, Aurelien Jarno wrote: > Most of the userland code seems to pass an int to this ioctl, but a few > others (e.g.: bup, libexplain) passes a long. While it doesn't make a > difference on little endian machines, it does make a difference on > 64-bit big endian machines. > > Could you please tell me if I am wrong in my analysis or if there is a > actually real problem? The problem is that as you indeed pointed out the ABI is that an int needs to be passed. The _IOR/_IOW generate a ioctl number based on a few inputs including the type of the argument, which is just passed to sizeof. So the supposedly self-documenting ioctl defintions disagree with the actual ABI. There's nothing that can be fixed in the kernel except for better documenting the actual ABI, and why the ioctl defintion is very misleading in this case. The userspace programs that were mislead by this will need to fixed. -- To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html