Re: [Qemu-devel] [PATCH 10/14] timer: ds1338 remove vestige of un-modeled OSF

2018-07-15 Thread David Gibson
On Thu, Jul 05, 2018 at 11:19:57AM -0700, Michael Davidsaver wrote: > Oscillator stop has never been modeled, so the > Oscillator Stop Flag can never be set. > > Signed-off-by: Michael Davidsaver Reviewed-by: David Gibson > --- > hw/timer/ds-rtc.c | 14 +- > 1 file changed, 5

Re: [Qemu-devel] [PATCH 05/14] timer: ds1338 change write handling and fix wday_offset handling

2018-07-15 Thread David Gibson
On Thu, Jul 05, 2018 at 11:19:52AM -0700, Michael Davidsaver wrote: > instead of a read-modify-write, do direct translation > of device registers to struct tm members. > > This new ds1338_update() is the reverse of > the existing capture_current_time(). > > Simplifies later handling of CENTURY

Re: [Qemu-devel] hw/display/sm501* status

2018-07-15 Thread David Gibson
On Sun, Jul 15, 2018 at 11:29:56AM +0200, BALATON Zoltan wrote: > Hello, > > I plan to make more changes to sm501 emulation to make it more usable for > AmigaOS and other Amiga like OSes. This would include first cleaning up of > current state, then trying to optimise 2D ops and display updates

Re: [Qemu-devel] [PATCH v3 4/4] tests: Add centos VM testing

2018-07-15 Thread Fam Zheng
On Sun, 07/15 22:34, Philippe Mathieu-Daudé wrote: > Hi Fam, > > On 07/11/2018 10:28 PM, Fam Zheng wrote: > > This one does docker testing in the VM. It is intended to replace the > > native docker testing on patchew testers. > > > > Signed-off-by: Fam Zheng > > --- > >

[Qemu-devel] [PATCH] tests: vm: Add vm-clean-all

2018-07-15 Thread Fam Zheng
The images are big. Add a rule to clean up easily. Suggested-by: Philippe Mathieu-Daudé Signed-off-by: Fam Zheng --- tests/vm/Makefile.include | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tests/vm/Makefile.include b/tests/vm/Makefile.include index

Re: [Qemu-devel] [PATCH v2 for 3.0 11/16] docker: add expansion for docker-test-FOO to Makefile.include

2018-07-15 Thread Philippe Mathieu-Daudé
Hi Alex, On 07/13/2018 09:17 AM, Alex Bennée wrote: > This allows us to run a particular test on all docker images. For > example: > > make docker-test-unit > > Will run the unit tests on every supported image. At the same time > rename docker-test to docker-all-tests to be clearer. > >

Re: [Qemu-devel] [PATCH v3 4/4] tests: Add centos VM testing

2018-07-15 Thread Philippe Mathieu-Daudé
Hi Fam, On 07/13/2018 04:18 AM, Fam Zheng wrote: > On Thu, 07/12 12:02, Philippe Mathieu-Daudé wrote: >> Hi Fam, >> >> On 07/11/2018 10:28 PM, Fam Zheng wrote: >>> This one does docker testing in the VM. It is intended to replace the >>> native docker testing on patchew testers. >>> >>>

Re: [Qemu-devel] [PATCH v3 4/4] tests: Add centos VM testing

2018-07-15 Thread Philippe Mathieu-Daudé
Hi Fam, On 07/11/2018 10:28 PM, Fam Zheng wrote: > This one does docker testing in the VM. It is intended to replace the > native docker testing on patchew testers. > > Signed-off-by: Fam Zheng > --- > tests/vm/Makefile.include | 3 +- > tests/vm/centos | 84

Re: [Qemu-devel] [PATCH for 3.0] sm501: Fix warning about unreachable code

2018-07-15 Thread David Gibson
On Sun, Jul 15, 2018 at 10:59:21PM +0200, BALATON Zoltan wrote: > Coverity warned that the false arm of conditional expression is > unreachable when it is inside an if with the same condition. > Remove the unreachable code to avoid the warning. > > Fixes: CID 1394215 > Reported-by: Paolo Bonzini

Re: [Qemu-devel] [PATCH for 3.0] sam460ex: Correct use after free error

2018-07-15 Thread David Gibson
On Sun, Jul 15, 2018 at 10:47:26PM +0200, BALATON Zoltan wrote: > Commit 51b0d834c changed error handling to report file name in error > message but forgot to move freeing it after usage. Noticed by Coverity. > > Fixes: CID 1394217 > Reported-by: Paolo Bonzini > Signed-off-by: BALATON Zoltan

Re: [Qemu-devel] insecure git submodule URLs

2018-07-15 Thread Jann Horn via Qemu-devel
On Sun, Jul 15, 2018 at 11:18 PM Peter Maydell wrote: > > On 15 July 2018 at 20:50, Jann Horn via Qemu-devel > wrote: > > I noticed that when I build QEMU from git for the first time, it pulls > > in submodules over the insecure git:// protocol - in other words, as > > far as I can tell, if I'm

Re: [Qemu-devel] [PATCH for-3.0] qga: fix file descriptor leak

2018-07-15 Thread Philippe Mathieu-Daudé
On 07/15/2018 01:21 PM, Paolo Bonzini wrote: > The file descriptor for /sys/power/state was never closed. Reported > by Coverity. > > Signed-off-by: Paolo Bonzini Reviewed-by: Philippe Mathieu-Daudé > --- > qga/commands-posix.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git

Re: [Qemu-devel] [PATCH for 3.0] sam460ex: Correct use after free error

2018-07-15 Thread Philippe Mathieu-Daudé
On 07/15/2018 05:47 PM, BALATON Zoltan wrote: > Commit 51b0d834c changed error handling to report file name in error > message but forgot to move freeing it after usage. Noticed by Coverity. > > Fixes: CID 1394217 > Reported-by: Paolo Bonzini > Signed-off-by: BALATON Zoltan Reviewed-by:

Re: [Qemu-devel] [PATCH for 3.0] sm501: Fix warning about unreachable code

2018-07-15 Thread Philippe Mathieu-Daudé
On 07/15/2018 05:59 PM, BALATON Zoltan wrote: > Coverity warned that the false arm of conditional expression is > unreachable when it is inside an if with the same condition. > Remove the unreachable code to avoid the warning. > > Fixes: CID 1394215 > Reported-by: Paolo Bonzini > Signed-off-by:

[Qemu-devel] [RFC PATCH] hw: arm: Add basic support for cprman (clock subsystem)

2018-07-15 Thread Guenter Roeck
Add basic support for BCM283x CPRMAN. Provide support for reading and writing CPRMAN registers and initialize registers with sensible default values. During runtime retain any written values. Basic CPRMAN support is necessary and sufficient to boot Linux on raspi2 and raspi3 systems.

Re: [Qemu-devel] insecure git submodule URLs

2018-07-15 Thread Peter Maydell
On 15 July 2018 at 20:50, Jann Horn via Qemu-devel wrote: > I noticed that when I build QEMU from git for the first time, it pulls > in submodules over the insecure git:// protocol - in other words, as > far as I can tell, if I'm e.g. on an open wifi network while building > QEMU for the first

[Qemu-devel] [PATCH for 3.0] sm501: Fix warning about unreachable code

2018-07-15 Thread BALATON Zoltan
Coverity warned that the false arm of conditional expression is unreachable when it is inside an if with the same condition. Remove the unreachable code to avoid the warning. Fixes: CID 1394215 Reported-by: Paolo Bonzini Signed-off-by: BALATON Zoltan --- hw/display/sm501.c | 2 +- 1 file

[Qemu-devel] [PATCH for 3.0] sam460ex: Correct use after free error

2018-07-15 Thread BALATON Zoltan
Commit 51b0d834c changed error handling to report file name in error message but forgot to move freeing it after usage. Noticed by Coverity. Fixes: CID 1394217 Reported-by: Paolo Bonzini Signed-off-by: BALATON Zoltan --- hw/ppc/sam460ex.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)

Re: [Qemu-devel] [PATCH] accel/tcg: Check whether TLB entry is RAM consistently with how we set it up

2018-07-15 Thread Peter Maydell
On 15 July 2018 at 01:37, Richard Henderson wrote: > On 07/13/2018 10:09 AM, Peter Maydell wrote: >> @@ -939,29 +935,21 @@ tb_page_addr_t get_page_addr_code(CPUArchState *env, >> target_ulong addr) >> } >> assert(tlb_hit(env->tlb_table[mmu_idx][index].addr_code, addr)); >>

[Qemu-devel] [PULL 3/4] linux-user: fix mmap_find_vma_reserved()

2018-07-15 Thread Laurent Vivier
The value given by mmap_find_vma_reserved() is used with mmap(), so it is needed to be aligned with the host page size. Since commit 18e80c55bb, reserved_va is only aligned to TARGET_PAGE_SIZE, and it works well if this size is greater or equal to the host page size. But ppc64 hosts have 64kB

[Qemu-devel] [PULL 1/4] linux-user: ppc64: use the correct values for F_*LK64s

2018-07-15 Thread Laurent Vivier
From: Shivaprasad G Bhat Qemu includes the glibc headers for the host defines and target headers are part of the qemu source themselves. The glibc has the F_GETLK64, F_SETLK64 and F_SETLKW64 defined to 12, 13 and 14 for all archs in sysdeps/unix/sysv/linux/bits/fcntl-linux.h. The linux kernel

[Qemu-devel] [PULL 4/4] Zero out the host's `msg_control` buffer

2018-07-15 Thread Laurent Vivier
From: Jonas Schievink If this is not done, qemu would drop any control message after the first one. This is because glibc's `CMSG_NXTHDR` macro accesses the uninitialized cmsghdr's length field in order to find out if the message fits into the `msg_control` buffer, wrongly assuming that it

[Qemu-devel] [PULL 0/4] Linux user for 3.0 patches

2018-07-15 Thread Laurent Vivier
The following changes since commit 9277d81f5c2c6f4d0b5e47c8476eb7ee7e5c0beb: docs: Grammar and spelling fixes (2018-07-13 10:16:04 +0100) are available in the Git repository at: git://github.com/vivier/qemu.git tags/linux-user-for-3.0-pull-request for you to fetch changes up to

[Qemu-devel] [PULL 2/4] linux-user: convert remaining fcntl() to safe_fcntl()

2018-07-15 Thread Laurent Vivier
Commit 435da5e709 didn't convert a fcntl() call to safe_fcntl() for TARGET_NR_fcntl64 case. There is no reason to not use it in this case. Fixes: 435da5e709 linux-user: Use safe_syscall wrapper for fcntl Signed-off-by: Laurent Vivier Message-Id: <20180713125805.10749-1-laur...@vivier.eu> ---

[Qemu-devel] insecure git submodule URLs

2018-07-15 Thread Jann Horn via Qemu-devel
Hi! I noticed that when I build QEMU from git for the first time, it pulls in submodules over the insecure git:// protocol - in other words, as far as I can tell, if I'm e.g. on an open wifi network while building QEMU for the first time, even if I cloned the main repository over https, anyone

[Qemu-devel] [RFC 1/2] arm: Add nRF51 GPIO peripheral

2018-07-15 Thread Steffen Görtz
Signed-off-by: Steffen Görtz --- The general purpose i/o implementation supports tri-state inputs and outputs (HIGH-Z, LOW, HIGH). SENSE output is not supported and tests will follow in V2. hw/gpio/Makefile.objs| 1 + hw/gpio/nrf51_gpio.c | 302

[Qemu-devel] [RFC 2/2] arm: Add nRF51 GPIO tests

2018-07-15 Thread Steffen Görtz
Signed-off-by: Steffen Görtz --- Test stubs for GIPO. Tests will follow in v2. tests/microbit-test.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/tests/microbit-test.c b/tests/microbit-test.c index c502ee3976..a1e2f67855 100644 --- a/tests/microbit-test.c +++

[Qemu-devel] [PATCH for-3.0] qga: fix file descriptor leak

2018-07-15 Thread Paolo Bonzini
The file descriptor for /sys/power/state was never closed. Reported by Coverity. Signed-off-by: Paolo Bonzini --- qga/commands-posix.c | 1 + 1 file changed, 1 insertion(+) diff --git a/qga/commands-posix.c b/qga/commands-posix.c index 233f78a406..4160aceaed 100644 --- a/qga/commands-posix.c

Re: [Qemu-devel] [PATCH RFC v2 0/2] Fix UART serial implementation

2018-07-15 Thread Paolo Bonzini
On 12/05/2018 02:05, Calvin Lee wrote: > While developing a serial implementation for my OS, I found several bugs > in QEMU's serial device. I confirmed (by testing on my x64 laptop) that > there are several inconsistancies between QEMU and hardware in this > regard. For both patches, I used

Re: [Qemu-devel] [PATCH] vhost-user-test: added proper TestServer *dest initialization in test_migrate()

2018-07-15 Thread Paolo Bonzini
On 26/06/2018 16:18, Emanuele Giuseppe Esposito wrote: > server->bus in _test_server_free() could be NULL, since TestServer *dest in > test_migrate() was not properly initialized like TestServer *s. > Added init_virtio_dev(dest) and uninit_virtio_dev(dest), so the fields are > properly set and

Re: [Qemu-devel] [PATCH] vhost-user-test: added proper TestServer *dest initialization in test_migrate()

2018-07-15 Thread Paolo Bonzini
On 27/06/2018 12:05, Laurent Vivier wrote: > On 26/06/2018 16:18, Emanuele Giuseppe Esposito wrote: >> server->bus in _test_server_free() could be NULL, since TestServer *dest in >> test_migrate() was not properly initialized like TestServer *s. >> Added init_virtio_dev(dest) and

Re: [Qemu-devel] [PATCH 0/2] hyperv: ensure VP index equal to QEMU cpu_index

2018-07-15 Thread Paolo Bonzini
On 02/07/2018 15:41, Roman Kagan wrote: > Make sure QEMU owns the VP index (which is the number used to identify > the vCPU in Hyper-V) and make it equal to QEMU cpu_index. > > Roman Kagan (2): > hyperv: rename vcpu_id to vp_index > hyperv: ensure VP index equal to QEMU cpu_index > > --- >

Re: [Qemu-devel] [PATCH sgabios] Makefile: Add HOSTCC

2018-07-15 Thread Paolo Bonzini
On 03/07/2018 16:40, Cole Robinson wrote: > I probably should have added more context here... > > We carry this patch to sgabios in Fedora to enable cross compilation. It > would be nice to get it into the qemu sgabios git repo so we don't have > to track it downstream anymore > > Thanks, > Cole

Re: [Qemu-devel] [PATCH] accel: Fix typo and grammar in comment

2018-07-15 Thread Paolo Bonzini
On 12/07/2018 21:44, Stefan Weil wrote: > The typo was found by codespell. > > Signed-off-by: Stefan Weil > --- > accel/tcg/translate-all.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/accel/tcg/translate-all.c b/accel/tcg/translate-all.c > index

Re: [Qemu-devel] bcm2835_aux: Swap RX and TX interrupt assignments

2018-07-15 Thread Paolo Bonzini
On 14/07/2018 15:53, Guenter Roeck wrote: > ping ... Queued, thanks. Paolo > On Mon, Jun 18, 2018 at 02:04:06PM -0700, Guenter Roeck wrote: >> RX and TX interrupt bits were reversed, resulting in an endless sequence >> of serial interupts in the emulated system and the following repeated >>

Re: [Qemu-devel] [PATCH v2] trace/simple: fix hang in child after fork(2)

2018-07-15 Thread Paolo Bonzini
On 13/07/2018 20:42, Stefan Hajnoczi wrote: > +#ifndef _WIN32 > +static void stop_writeout_thread(void) > +{ > +g_mutex_lock(_lock); > +trace_writeout_running = false; > +g_cond_signal(_available_cond); > +g_mutex_unlock(_lock); > + > +g_thread_join(trace_writeout_thread); > +

[Qemu-devel] hw/display/sm501* status

2018-07-15 Thread BALATON Zoltan
Hello, I plan to make more changes to sm501 emulation to make it more usable for AmigaOS and other Amiga like OSes. This would include first cleaning up of current state, then trying to optimise 2D ops and display updates because it was found these are currently quite slow. (Especially when

Re: [Qemu-devel] [PATCH 1/5] nvme: PCI/e configuration from specification

2018-07-15 Thread Daniel Verkamp
On Fri, Jun 22, 2018 at 4:22 AM, Shimi Gersner wrote: > PCI/e configuration currently does not meets specifications. > > Patch includes various configuration changes to support specifications > - BAR2 to return zero when read and CMD.IOSE is not set. > - Expose NVME configuration through IO space