qemu-trivial
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v0] kvm: unsigned datatype in ioctl wrapper


From: Peter Maydell
Subject: Re: [PATCH v0] kvm: unsigned datatype in ioctl wrapper
Date: Mon, 30 Aug 2021 18:33:07 +0100

On Mon, 30 Aug 2021 at 16:47, Eric Blake <eblake@redhat.com> wrote:
>
> On Sun, Aug 29, 2021 at 10:09:19PM +0100, Peter Maydell wrote:
> > Of the various KVM_* ioctls we use via these functions, do
> > any actually have values that would result in invalid sign
> > extension here ? That is, is this fixing an existing bug, or is
> > it merely avoiding a potential future bug?
>
> My question as well.  If there is such a bug, calling it out in the
> commit message is essential; if the bug is just theoretical,
> mentioning that is still useful.

I found this glibc bug from 2012, filed by some random guy named
Linus Torvalds, and still open:
https://sourceware.org/bugzilla/show_bug.cgi?id=14362
where among other things he claims
# As noted, this does not actually cause problems on Linux, because
# unlike FreeBSD, Linux knows what the f*ck it is doing, and just
# ignores the upper bits exactly because of possible sign confusion.

Whether that's still true a decade later I have no idea :-)

-- PMM



reply via email to

[Prev in Thread] Current Thread [Next in Thread]