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

2017-10-05 Thread Marco A L Barbosa
Thanks, I submitted a patch:
https://lists.nongnu.org/archive/html/qemu-trivial/2017-10/msg00016.html

On Tue, Oct 3, 2017 at 12:30 PM, Peter Maydell 
wrote:

> On 3 October 2017 at 11:50, Marco Aurélio Lopes Barbosa
>  wrote:
> > if (ioctl(fd, RNDGETENTCNT, &entropy) == -1)
>
> > When I run this program with qemu-x86_64-static I got the error
> >
> > Unsupported ioctl: cmd=0x80045200
> > 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
>



-- 
Marco A L Barbosa
http://malbarbo.pro.br
--


[Qemu-discuss] Device not tied to a QemuConsole.

2017-10-05 Thread José Pekkarinen
Hi list,

I'm currently toying around with vfio mediated devices in qemu, and I'm 
having troubles defining a display through vnc for the mediated device. The 
error in question is this:

qemu-system-x86_64: -display vnc=0:1,display=video.1: Failed to start VNC 
server: Device video.1 (head 0) is not bound to a QemuConsole

The qemu parameters are like this:

sudo qemu-system-x86_64 -enable-kvm -cpu host -smp 2,cores=1,threads=2 \
-m 8G -mem-path /mnt/hugepages -vga qxl -display vnc=0:0 -display 
vnc=0:1,display=video.1 \
-device vfio-pci,id=video.1,sysfsdev=/sys/class/mdev_bus/:00:02.0/
$uuid,bus=pci.0,addr=06.0,rombar=0 \
-netdev user,id=user.0,smb=/home/pekkari/share -device 
e1000,netdev=user.0 \
-device ich9-usb-uhci3,id=uhci -device usb-ehci,id=ehci -device nec-
usb-xhci,id=xhci \
-device virtio-serial -device usb-tablet -device ich9-intel-hda -
device hda-duplex \
-object input-linux,id=kbd,evdev=/dev/input/by-path/platform-i8042-
serio-0-event-kbd \
-chardev socket,path=/tmp/virtio-serial.sock,server,nowait,id=serial-
log \
-device virtserialport,chardev=serial-log,name=ant.port.0 \
-cdrom /home/pekkari/machines/win8/virtio-win-0.1.141.iso \
-drive file=win8.img,format=raw,cache=none,aio=native,if=virtio

This is piece of a script that sets uuid to a value, and the vm is a 
windows 8.1 vm with RH qxl and intel qxl device driver.

Previously I tried using spice, replacing all -displays with the 
following:

-spice port=5900,disable-ticketing

The result was that just one display turn up, and intel was tied to a 
non 
pnp display that I wouldn't see. Switching the main display to it make the vm 
almost unusable, as everything renders in the invisible display.

Thanks in advance for any suggestions.

José.



Re: [Qemu-discuss] Coldfire 5282 Support

2017-10-05 Thread William Mahoney
OK I took a look at slirp.c as you suggested.
I put in some fprintf’s in slip.c for the ARP requests and also in 
arp_table_add and arp_table_search in arp_table.c. In the process I learned a 
lot about how the ARP services work within QEMU and in the process also 
realized what I was doing wrong. Long story. But now, if I do a redirect on the 
command line sending - for example - 6000 on the host to 5000 on the guest, and 
do a netcat listening on the guest, that works, I can “get in” from the host to 
the guest. And if I start up a listening netcat on the host and get the proper 
guestfwd on the command line that works fine as well.
(If anyone is interested… When uClinux starts up it sends an unsolicited ARP 
associating 10.0.2.15 with the correct MAC address. Suppose at that point I try 
to do “nc 10.0.2.15”. This connection is refused without ever even hitting the 
net drivers. If I do “nc 10.0.2.2” it does search the ARP table for the .15 
address (not the .2 address) and finds it, obviously. QEMU sends back the ARP 
reply and uClinux on the guest sees it. Then uClinux says “Connection refused” 
anyway. In slip.c it just rejects everything not on the same subnet, so had I 
realized this it’d have saved me some time, but now I learned how it works!)
Anyway it does work as advertised but I was misreading or not understanding 
somewhere along the line. Thanks everyone.

Bill



On Oct 3, 2017, at 12:40 PM, Peter Maydell 
mailto:peter.mayd...@linaro.org>> wrote:

On 3 October 2017 at 18:14, Thomas Huth 
mailto:h...@tuxfamily.org>> wrote:
Not sure, but it might be normal that the host is not answering here.
The "user" networking is using NAT, so the host OS might think that it
is talking to itself here and thus ARP is not needed. You might want to
try "tap" networking instead. Or maybe try to connect to another host
from within the guest first (for example "nc 
www.google.com 80" ... and
then type "GET / HTTP/1.0").

With the user-mode networking QEMU should do all the handling
of guest ARP requests and responses internally; they'll never get out
to the host because the host will have no idea what to do with
them. (See arp_input() in slirp/slirp.c.)

thanks
-- PMM



Re: [Qemu-discuss] SunOS 4.1.4 on Qemu 2.10.0 on Mac OS X 10.12.6 on mid 2012 Intel MBP w/16GB RAM

2017-10-05 Thread Dennis Luehring
first i would should build lastest qemu release from source - and test 
with that version - its very easy


you only need some additional packages to build

https://www.qemu.org/download/#source
https://gns3.com/news/article/how-to-compile-qemu-2-2-0-in-ubu

no need for install - just make


Am 04.10.2017 um 01:20 schrieb Will Senn:

Hi,

I heard on the TUHs mailing list that it was possible to emulate sparc
on qemu and further that you could run SunOS. So, I did the following:

brew install qemu - which got qemu on my mac

rounded up the sunos 4.1.4 install media and the sparcstation 5 version
2.15 boot prom

and then followed the directions (and a bunch of variations) at
https://en.wikibooks.org/wiki/QEMU/SunOS_4.1.4

When I got to the post-install reboot, the VM booted up to the point
where it was starting network services and then reported a bunch of,
"rpc.lockd: Cannot contact status monitor!" and hung. I thought maybe it
was environmental, but I got the same errors on Linux Mint 18 with qemu
1.7, 2.0, and 2.14 as well as on FreeBSD with qemu 2.8.1, so I'm asking
for help.

First question - is there a better/more up-to-date guide than what's on
the wiki (I googled but didn't find anything better)?

Second question - any idea why the error is happening or how to make it
stop (google returned a bunch of Sun notes saying stop and restart rpc,
but this isn't really helpful as it happens during boot and it hangs
without letting me make any changes)?

Third question - has anyone heard of this working on modern hardware and
software configurations (the Wiki article is pretty old and the few
videos I saw on youtube were Crunchbang - circa Ubuntu 8?

Any substantive help appreciated.

Thanks,

Will






Re: [Qemu-discuss] SunOS 4.1.4 on Qemu 2.10.0 on Mac OS X 10.12.6 on mid 2012 Intel MBP w/16GB RAM

2017-10-05 Thread Will Senn
I did that as well, but got the same errors - here's the version I'm 
running now on Fedora 26.


qemu-system-sparc --version
QEMU emulator version 2.10.50 (v2.10.0-991-gd147f7e815)
Copyright (c) 2003-2017 Fabrice Bellard and the QEMU Project developers


On 10/6/17 12:18 AM, Dennis Luehring wrote:
first i would should build lastest qemu release from source - and test 
with that version - its very easy


you only need some additional packages to build

https://www.qemu.org/download/#source
https://gns3.com/news/article/how-to-compile-qemu-2-2-0-in-ubu

no need for install - just make


Am 04.10.2017 um 01:20 schrieb Will Senn:

Hi,

I heard on the TUHs mailing list that it was possible to emulate sparc
on qemu and further that you could run SunOS. So, I did the following:

brew install qemu - which got qemu on my mac

rounded up the sunos 4.1.4 install media and the sparcstation 5 version
2.15 boot prom

and then followed the directions (and a bunch of variations) at
https://en.wikibooks.org/wiki/QEMU/SunOS_4.1.4

When I got to the post-install reboot, the VM booted up to the point
where it was starting network services and then reported a bunch of,
"rpc.lockd: Cannot contact status monitor!" and hung. I thought maybe it
was environmental, but I got the same errors on Linux Mint 18 with qemu
1.7, 2.0, and 2.14 as well as on FreeBSD with qemu 2.8.1, so I'm asking
for help.

First question - is there a better/more up-to-date guide than what's on
the wiki (I googled but didn't find anything better)?

Second question - any idea why the error is happening or how to make it
stop (google returned a bunch of Sun notes saying stop and restart rpc,
but this isn't really helpful as it happens during boot and it hangs
without letting me make any changes)?

Third question - has anyone heard of this working on modern hardware and
software configurations (the Wiki article is pretty old and the few
videos I saw on youtube were Crunchbang - circa Ubuntu 8?

Any substantive help appreciated.

Thanks,

Will






--
GPG Fingerprint: 68F4 B3BD 1730 555A 4462  7D45 3EAA 5B6D A982 BAAF




Re: [Qemu-discuss] SunOS 4.1.4 on Qemu 2.10.0 on Mac OS X 10.12.6 on mid 2012 Intel MBP w/16GB RAM

2017-10-05 Thread Dennis Luehring
then you need to wait for Michael Russo who wants "now to play with in 
my spare time, I'll see if I run into the same issue." or ask
Artyom Tarasenko 
(http://tyom.blogspot.de/2009/12/solaris-under-qemu-how-to.html) for 
help - he once helped to get linux on sparc64 running and was very helpfull


Am 06.10.2017 um 07:24 schrieb Will Senn:

I did that as well, but got the same errors - here's the version I'm
running now on Fedora 26.

qemu-system-sparc --version
QEMU emulator version 2.10.50 (v2.10.0-991-gd147f7e815)
Copyright (c) 2003-2017 Fabrice Bellard and the QEMU Project developers


On 10/6/17 12:18 AM, Dennis Luehring wrote:
> first i would should build lastest qemu release from source - and test 
> with that version - its very easy

>
> you only need some additional packages to build
>
> https://www.qemu.org/download/#source
> https://gns3.com/news/article/how-to-compile-qemu-2-2-0-in-ubu
>
> no need for install - just make
>
>
> Am 04.10.2017 um 01:20 schrieb Will Senn:
>> Hi,
>>
>> I heard on the TUHs mailing list that it was possible to emulate sparc
>> on qemu and further that you could run SunOS. So, I did the following:
>>
>> brew install qemu - which got qemu on my mac
>>
>> rounded up the sunos 4.1.4 install media and the sparcstation 5 version
>> 2.15 boot prom
>>
>> and then followed the directions (and a bunch of variations) at
>> https://en.wikibooks.org/wiki/QEMU/SunOS_4.1.4
>>
>> When I got to the post-install reboot, the VM booted up to the point
>> where it was starting network services and then reported a bunch of,
>> "rpc.lockd: Cannot contact status monitor!" and hung. I thought maybe it
>> was environmental, but I got the same errors on Linux Mint 18 with qemu
>> 1.7, 2.0, and 2.14 as well as on FreeBSD with qemu 2.8.1, so I'm asking
>> for help.
>>
>> First question - is there a better/more up-to-date guide than what's on
>> the wiki (I googled but didn't find anything better)?
>>
>> Second question - any idea why the error is happening or how to make it
>> stop (google returned a bunch of Sun notes saying stop and restart rpc,
>> but this isn't really helpful as it happens during boot and it hangs
>> without letting me make any changes)?
>>
>> Third question - has anyone heard of this working on modern hardware and
>> software configurations (the Wiki article is pretty old and the few
>> videos I saw on youtube were Crunchbang - circa Ubuntu 8?
>>
>> Any substantive help appreciated.
>>
>> Thanks,
>>
>> Will
>>
>
>