[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH] [linux-user] Fix ioctl code generation macros
From: |
Stuart Brady |
Subject: |
Re: [Qemu-devel] [PATCH] [linux-user] Fix ioctl code generation macros |
Date: |
Sun, 15 Mar 2009 09:45:17 +0000 |
User-agent: |
Mutt/1.5.13 (2006-08-11) |
On Sun, Mar 15, 2009 at 02:40:11AM +0100, Lionel Landwerlin wrote:
> Of course, the problem is solved if you're saving the result of the
> TARGET_IO* macros in an unsigned integer.
>
> So here is a little patch that forces TARGET_IO* macros to output
> abi_long sized integers.
Surely the value currently produced by TARGET_IOC() *is* an unsigned int
(provided you use the direction macros)? I'm not sure if any arch will
ever need more than 32 bits here, but even with the cast to abi_long,
the high bits would be truncated before the cast.
target_cmd in IOCTLEntry is an unsigned int, but the command is also
passed around as an abi_long is some places... I couldn't see any code
that's currently affected by this, though -- did I miss something?
Cheers,
--
Stuart Brady