qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] -icount changes physical address assignments in QEMU 2.10/2.11
@ 2018-02-23  0:39 alarson
  2018-03-15 16:55 ` Peter Maydell
  0 siblings, 1 reply; 18+ messages in thread
From: alarson @ 2018-02-23  0:39 UTC (permalink / raw)
  To: qemu-devel

When porting our RTOS from QEMU 2.8 to 2.10/2.11, I ran into a problem
where 16-bit writes to the "bochs dispi interface" were being reported
differently depending on whether or not "-icount" was given to QEMU.

For example, info mtree:
  ...
  11000500-11000515 (prio 0, i/o): bochs dispi interface

A 16-bit write to 0x11000500 was delivered to pci_vga_bochs_write() as 
having
address 0, when -icount was not specified, but as address 2 when
-icount was specified.  Correspondingly writes to 0x11000502 were 2
and 0 respectively.  Essentially the words were swapped depending on
the presence of -icount.

I suspect a similar problem for the AARCH64 GIC (generic interrupt
controller), but other than observing the GIC changing from working to
non-working depending on the absence/presence of -icount I haven't
confirmed the underlying cause.

2.10 and 2.11 were built from source on Cygwin using mingw, 2.8 from a
"native" MinGW.  The results are consistent for 2.10 and 2.11.  2.8
does not have the -icount dependency.  The "broken" command line was:

qemu-system-aarch64 -m 1077 -name "arm" -M virt,virtualization=on 
  -cpu cortex-a53 -icount align=off,shift=0,sleep=on 
  -vga std -device secondary-vga 
  -device 
virtio-net,netdev=vlan0,addr=2,disable-modern=false,mac=52:54:00:12:67:56 
  -kernel ...deosBoot.bin -initrd "deosBoot.qemu" -netdev 
tap,id=vlan0,ifname="DDCI-tap0" 

The "working" command line omitted -icount and its argument.

FWIW, the error from the GIC with -icount was:

  qemu: fatal: IO on conditional branch instruction

Any pointers?

^ permalink raw reply	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2018-04-06 20:15 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-02-23  0:39 [Qemu-devel] -icount changes physical address assignments in QEMU 2.10/2.11 alarson
2018-03-15 16:55 ` Peter Maydell
2018-03-22  5:31   ` alarson
2018-04-05 14:05     ` Peter Maydell
2018-04-05 16:44       ` alarson
2018-04-05 17:28         ` Peter Maydell
2018-04-05 21:23           ` alarson
2018-04-06  9:41             ` Peter Maydell
2018-04-06 10:26               ` Stefan Weil
2018-04-06 13:28               ` alarson
2018-04-06 13:33                 ` Peter Maydell
2018-04-06 14:51                   ` Peter Maydell
2018-04-06 16:16                     ` Peter Maydell
2018-04-06 17:06                     ` alarson
2018-04-06 17:21                       ` Peter Maydell
2018-04-06 20:08                         ` alarson
2018-04-06 14:14                 ` Mark Cave-Ayland
2018-04-06 20:15                   ` alarson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).