qemu-discuss
[Top][All Lists]
Advanced

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

Re: [Qemu-discuss] Fwd: Why iocl with RNDGETENTCNT does not work?


From: Peter Maydell
Subject: Re: [Qemu-discuss] Fwd: Why iocl with RNDGETENTCNT does not work?
Date: Tue, 3 Oct 2017 16:30:51 +0100

On 3 October 2017 at 11:50, Marco Aurélio Lopes Barbosa
<address@hidden> wrote:
>         if (ioctl(fd, RNDGETENTCNT, &entropy) == -1)

> When I run this program with qemu-x86_64-static I got the error
>
> Unsupported ioctl: cmd=0xffffffff80045200
> ioctl failed

> I've patched qemu to forward the iocl with RNDGETENTCNT  to the host and it
> worked as expected. Can someone explain me why this does not work out of
> the box?

For the linux-user mode code in QEMU, every ioctl has to have
code (or at least a declaration) to support it. So when new
ioctls are added to the Linux kernel, they aren't supported
in QEMU unless support is also added to QEMU. The error message
is to tell the user that their program used an ioctl that
isn't supported in QEMU.

We don't have a lot of people maintaining the linux-user code,
so generally these are only fixed as people encounter them and
report bugs and provide us with patches.

If you've written a patch which adds support for this new
ioctl then you could send it to us via the qemu-devel mailing
list. If you're not sure how to do that then
https://wiki.qemu.org/Contribute/SubmitAPatch
has some information on sending us patches.

thanks
-- PMM



reply via email to

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