[Qemu-devel] [PATCH v5 01/17] target-m68k: sync CC_OP before gen_jmp_tb()

2018-01-01 Thread Laurent Vivier
And remove update_cc_op() from gen_exception() because there is one in gen_jmp_im(). Signed-off-by: Laurent Vivier --- target/m68k/translate.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/target/m68k/translate.c b/target/m68k/translate.c index bbda7399ec..0e9d651a2a 1006

[Qemu-devel] [PATCH v5 04/17] target-m68k: use insn_pc to generate instruction fault address

2018-01-01 Thread Laurent Vivier
Signed-off-by: Laurent Vivier --- target/m68k/translate.c | 40 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/target/m68k/translate.c b/target/m68k/translate.c index 1e9fb01252..a1e424e3db 100644 --- a/target/m68k/translate.c +++ b/target

[Qemu-devel] [PATCH v5 05/17] target/m68k: add CPU_LOG_INT trace

2018-01-01 Thread Laurent Vivier
Display the interrupts/exceptions information in QEMU logs (-d int) Signed-off-by: Laurent Vivier --- target/m68k/cpu.h | 8 target/m68k/op_helper.c | 112 2 files changed, 120 insertions(+) diff --git a/target/m68k/cpu.h b/target/m6

[Qemu-devel] [PATCH v5 03/17] linux-user, m68k: correctly manage SR in context

2018-01-01 Thread Laurent Vivier
Use cpu_m68k_get_ccr()/cpu_m68k_set_ccr() to setup and restore correctly the value of SR in the context structure. Fix target_rt_setup_ucontext(). Fixes: 3219de458c ("linux-user: correctly manage SR in ucontext") Signed-off-by: Laurent Vivier --- linux-user/signal.c | 7 --- 1 file changed,

[Qemu-devel] [PATCH v5 17/17] target/m68k: fix m68k_cpu_dump_state()

2018-01-01 Thread Laurent Vivier
Display correctly the Trace bits for 680x0 (2 bits instead of 1 for Coldfire). Signed-off-by: Laurent Vivier --- target/m68k/cpu.h | 3 ++- target/m68k/translate.c | 9 ++--- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/target/m68k/cpu.h b/target/m68k/cpu.h index fdb7

[Qemu-devel] [PATCH v5 11/17] target/m68k: add reset

2018-01-01 Thread Laurent Vivier
The instruction traps if the CPU is not in Supervisor state but the helper is empty because there is no easy way to reset all the peripherals without resetting the CPU itself. Signed-off-by: Laurent Vivier --- target/m68k/helper.c| 7 +++ target/m68k/helper.h| 4 target/m68k/t

[Qemu-devel] [PATCH v5 15/17] target/m68k: add andi/ori/eori to SR/CCR

2018-01-01 Thread Laurent Vivier
Signed-off-by: Laurent Vivier --- target/m68k/translate.c | 53 ++--- 1 file changed, 46 insertions(+), 7 deletions(-) diff --git a/target/m68k/translate.c b/target/m68k/translate.c index 1a462064be..ee59b5bad2 100644 --- a/target/m68k/translate.c +++

[Qemu-devel] [PATCH v5 06/17] target/m68k: manage 680x0 stack frames

2018-01-01 Thread Laurent Vivier
680x0 manages several stack frame formats: - format 0: four-word stack frame - format 1: four-word throwaway stack frame - format 2: six-word stack frame - format 3: Floating-Point post-instruction stack frame - format 4: eight-word stack frame - format 7: access-error stack frame Sign

[Qemu-devel] [PATCH v5 14/17] target/m68k: add 680x0 "move to SR" instruction

2018-01-01 Thread Laurent Vivier
Some cleanup, and allows SR to be moved from any addressing mode. Previous code was wrong for coldfire: coldfire also allows to use addressing mode to set SR/CCR. It only supports Data register to get SR/CCR (move from) Signed-off-by: Laurent Vivier --- target/m68k/translate.c | 38 +

[Qemu-devel] [PATCH v5 02/17] target/m68k: fix gen_get_ccr()

2018-01-01 Thread Laurent Vivier
As gen_helper_get_ccr() is able to compute CCR from cc_op and flags, we don't need to flush flags before to call it. flush_flags() and get_ccr() use COMPUTE_CCR() to compute flags. get_ccr() computes CCR value, whereas flush_flags update live cc_op and flags. Signed-off-by: Laurent Vivier --- ta

[Qemu-devel] [PATCH v5 07/17] target/m68k: add chk and chk2

2018-01-01 Thread Laurent Vivier
chk and chk2 compares a value to boundaries, and triggers a CHK exception if the values is out of bounds. Signed-off-by: Laurent Vivier --- linux-user/main.c | 7 +++ target/m68k/cpu.c | 2 + target/m68k/cpu.h | 1 + target/m68k/translate.c | 137 +

[Qemu-devel] [PATCH v5 09/17] target/m68k: softmmu cleanup

2018-01-01 Thread Laurent Vivier
don't compile supervisor only instructions in linux-user mode Signed-off-by: Laurent Vivier --- target/m68k/translate.c | 37 - 1 file changed, 32 insertions(+), 5 deletions(-) diff --git a/target/m68k/translate.c b/target/m68k/translate.c index 9f13299bcf..d

[Qemu-devel] [PATCH v5 16/17] target/m68k: add the Interrupt Stack Pointer

2018-01-01 Thread Laurent Vivier
Add the third stack pointer, the Interrupt Stack Pointer (ISP) (680x0 only). This stack will be needed in softmmu mode. Update movec to set/get the value of the three stacks. Signed-off-by: Laurent Vivier --- target/m68k/cpu.c | 3 ++ target/m68k/cpu.h | 70

Re: [Qemu-devel] [PATCH v2] target/arm: Fix stlxp for aarch64_be

2018-01-01 Thread Richard Henderson
On 12/30/2017 02:56 PM, Michael Weiser wrote: > ldxp loads two consecutive doublewords from memory regardless of CPU > endianness. On store, stlxp currently assumes to work with a 128bit > value and consequently switches order in big-endian mode. With this > change it packs the doublewords in rever

[Qemu-devel] [PATCH v5 13/17] target/m68k: move CCR/SR functions

2018-01-01 Thread Laurent Vivier
The following patches will be clearer if we move functions before adding new ones. Signed-off-by: Laurent Vivier --- target/m68k/translate.c | 111 1 file changed, 55 insertions(+), 56 deletions(-) diff --git a/target/m68k/translate.c b/target/m6

[Qemu-devel] [PATCH v5 12/17] target/m68k: implement fsave/frestore

2018-01-01 Thread Laurent Vivier
Signed-off-by: Laurent Vivier --- target/m68k/translate.c | 23 +++ 1 file changed, 15 insertions(+), 8 deletions(-) diff --git a/target/m68k/translate.c b/target/m68k/translate.c index 68b67bc0a3..4fced68ceb 100644 --- a/target/m68k/translate.c +++ b/target/m68k/translate.c

[Qemu-devel] [PATCH v5 08/17] target/m68k: add move16

2018-01-01 Thread Laurent Vivier
move16 moves the source line to the destination line. Lines are aligned to 16-byte boundaries and are 16 bytes long. Signed-off-by: Laurent Vivier --- target/m68k/cpu.c | 10 ++- target/m68k/cpu.h | 1 + target/m68k/translate.c | 73 ++

[Qemu-devel] [PATCH v5 10/17] target/m68k: add cpush/cinv

2018-01-01 Thread Laurent Vivier
Add cache lines invalidate and cache lines push as no-op operations, as we don't have cache. These instructions are 68040 only. Signed-off-by: Laurent Vivier --- target/m68k/translate.c | 20 1 file changed, 20 insertions(+) diff --git a/target/m68k/translate.c b/target/m6

[Qemu-devel] [PATCH v5 00/17] target/m68k: supervisor mode (part 1)

2018-01-01 Thread Laurent Vivier
This series is the first series that will allow to introduce supervisor mode and execute privileged instructions. Some of these patches are only cleanup: sync CC_OP before gen_jmp_tb() fix gen_get_ccr() softmmu cleanup add CPU_LOG_INT trace use insn_pc to generate instruction fault addr

Re: [Qemu-devel] [RFC 0/3] Extend vhost-user to support VFIO based accelerators

2018-01-01 Thread Alexey Kardashevskiy
On 22/12/17 17:41, Tiwei Bie wrote: > This RFC patch set does some small extensions to vhost-user protocol > to support VFIO based accelerators, and makes it possible to get the > similar performance of VFIO passthru while keeping the virtio device > emulation in QEMU. > > When we have virtio ring

Re: [Qemu-devel] [PATCH v4] SDL2 various fixes

2018-01-01 Thread Jindřich Makovička
On Fri, 17 Nov 2017 12:22:55 +0100 Jindrich Makovicka wrote: > Hi, > > here is a respin of the three remaining patches, with checkpatch > errors corrected. > > Also added the Fixes: line for "sdl2 uses surface relative > coordinates", and an explaining comment to "sdl2: Ignore UI hotkeys". > >

Re: [Qemu-devel] [PATCH v5 00/17] target/m68k: supervisor mode (part 1)

2018-01-01 Thread no-reply
Hi, This series failed automatic build test. Please find the testing commands and their output below. If you have docker installed, you can probably reproduce it locally. Type: series Message-id: 20180102011032.30056-1-laur...@vivier.eu Subject: [Qemu-devel] [PATCH v5 00/17] target/m68k: supervis

Re: [Qemu-devel] [PATCH qemu v2] kvm: Add kvm_set_user_memory tracepoint

2018-01-01 Thread Alexey Kardashevskiy
On 15/12/17 20:46, Darren Kenny wrote: > On Fri, Dec 15, 2017 at 04:23:26PM +1100, Alexey Kardashevskiy wrote: >> This adds a tracepoint to trace the KVM_SET_USER_MEMORY_REGION ioctl >> parameters which is quite useful for debugging VFIO memory regions >> being actually registered with KVM. >> >> S

[Qemu-devel] [PATCH v8 4/4] contrib/vhost-user-blk: introduce a vhost-user-blk sample application

2018-01-01 Thread Changpeng Liu
This commit introcudes a vhost-user-blk backend device, it uses UNIX domain socket to communicate with QEMU. The vhost-user-blk sample application should be used with QEMU vhost-user-blk-pci device. To use it, complie with: make vhost-user-blk and start like this: vhost-user-blk -b /dev/sdb -s /p

[Qemu-devel] [PATCH v8 0/4] Introduce a new vhost-user-blk host device to QEMU

2018-01-01 Thread Changpeng Liu
Although virtio scsi specification was designed as a replacement for virtio_blk, there are still many users using virtio_blk. QEMU 2.9 introduced a new device vhost user scsi which can process I/O in user space for virtio_scsi, this commit introduces a new vhost user block host device, which can su

[Qemu-devel] [PATCH v8 1/4] vhost-user: add new vhost user messages to support virtio config space

2018-01-01 Thread Changpeng Liu
Add VHOST_USER_GET_CONFIG/VHOST_USER_SET_CONFIG messages which can be used for live migration of vhost user devices, also vhost user devices can benefit from the messages to get/set virtio config space from/to the I/O target. For the purpose to support virtio config space change, VHOST_USER_SLAVE_C

[Qemu-devel] [PATCH v8 2/4] vhost-user-blk: introduce a new vhost-user-blk host device

2018-01-01 Thread Changpeng Liu
This commit introduces a new vhost-user device for block, it uses a chardev to connect with the backend, same with Qemu virito-blk device, Guest OS still uses the virtio-blk frontend driver. To use it, start QEMU with command line like this: qemu-system-x86_64 \ -chardev socket,id=char0,path=

[Qemu-devel] [PATCH v8 3/4] contrib/libvhost-user: enable virtio config space messages

2018-01-01 Thread Changpeng Liu
Enable VHOST_USER_GET_CONFIG/VHOST_USER_SET_CONFIG messages in libvhost-user library, users can implement their own I/O target based on the library. This enable the virtio config space delivered between QEMU host device and the I/O target. Signed-off-by: Changpeng Liu --- contrib/libvhost-user/l

[Qemu-devel] [Bug 1246990] Re: [qemu-x86-64-linux-user 1.6.1] qemu: uncaught target signal 11 (Segmentation fault) - core dumped

2018-01-01 Thread Launchpad Bug Tracker
[Expired for QEMU because there has been no activity for 60 days.] ** Changed in: qemu Status: Incomplete => Expired -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1246990 Title: [qemu-x86-6

[Qemu-devel] [Bug 1246990] Re: [qemu-x86-64-linux-user 1.6.1] qemu: uncaught target signal 11 (Segmentation fault) - core dumped

2018-01-01 Thread Launchpad Bug Tracker
[Expired for qemu (Ubuntu) because there has been no activity for 60 days.] ** Changed in: qemu (Ubuntu) Status: Incomplete => Expired -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1246990 Ti

[Qemu-devel] [PATCH qemu 2/3] vfio/spapr: Use iommu memory region's get_attr()

2018-01-01 Thread Alexey Kardashevskiy
In order to enable TCE operations support in KVM, we have to inform the KVM about VFIO groups being attached to specific LIOBNs. The KVM already knows about VFIO groups, the only bit missing is which in-kernel TCE table (the one with user visible TCEs) should update the attached broups. There is an

[Qemu-devel] [PATCH qemu 1/3] memory/iommu: Add get_attr()

2018-01-01 Thread Alexey Kardashevskiy
This adds get_attr() to IOMMUMemoryRegionClass, like iommu_ops::domain_get_attr in the Linux kernel. This defines the first attribute - IOMMU_ATTR_SPAPR_TCE_FD - which will be used between the pSeries machine and VFIO-PCI. Signed-off-by: Alexey Kardashevskiy --- include/exec/memory.h | 22 +

[Qemu-devel] [PATCH qemu 0/3] spapr/iommu: Enable in-kernel TCE acceleration via VFIO KVM device

2018-01-01 Thread Alexey Kardashevskiy
This is my current queue of the in-kernel TCE acceleration enablement. Changes since https://lists.gnu.org/archive/html/qemu-devel/2017-12/msg01918.html : * 3 patches instead of one, one per maintainership area; * added memory_region_iommu_get_attr(); * removed set_attr() as there is no use for i

[Qemu-devel] [PATCH qemu 3/3] spapr/iommu: Enable in-kernel TCE acceleration via VFIO KVM device

2018-01-01 Thread Alexey Kardashevskiy
In order to enable TCE operations support in KVM, we have to inform the KVM about VFIO groups being attached to specific LIOBNs; the necessary bits are implemented already by IOMMU MR and VFIO. This defines get_attr() for the SPAPR TCE IOMMU MR which makes VFIO call the KVM_DEV_VFIO_GROUP_SET_SPAP

Re: [Qemu-devel] [PATCH qemu 0/3] spapr/iommu: Enable in-kernel TCE acceleration via VFIO KVM device

2018-01-01 Thread no-reply
Hi, This series seems to have some coding style problems. See output below for more information: Type: series Message-id: 20180102052805.20498-1-...@ozlabs.ru Subject: [Qemu-devel] [PATCH qemu 0/3] spapr/iommu: Enable in-kernel TCE acceleration via VFIO KVM device === TEST SCRIPT BEGIN === #!/b

Re: [Qemu-devel] [RFC 0/3] Extend vhost-user to support VFIO based accelerators

2018-01-01 Thread Alexey Kardashevskiy
On 02/01/18 16:49, Liang, Cunming wrote: > > >> -Original Message- >> From: Alexey Kardashevskiy [mailto:a...@ozlabs.ru] >> Sent: Tuesday, January 2, 2018 10:42 AM >> To: Bie, Tiwei ; virtio-...@lists.oasis-open.org; qemu- >> de...@nongnu.org; m...@redhat.com; alex.william...@redhat.com;

Re: [Qemu-devel] [PATCH qemu v3] RFC: ppc/spapr: Receive and store device tree blob from SLOF

2018-01-01 Thread Alexey Kardashevskiy
On 11/12/17 17:20, Alexey Kardashevskiy wrote: > On 09/11/17 17:38, David Gibson wrote: >> On Tue, Nov 07, 2017 at 06:14:04PM +1100, Alexey Kardashevskiy wrote: >>> On 20/10/17 11:46, Alexey Kardashevskiy wrote: On 19/10/17 17:24, David Gibson wrote: > On Tue, Oct 17, 2017 at 04:55:03PM +1

Re: [Qemu-devel] [PATCH v1] hmp: 'info snapshots' not showing the id

2018-01-01 Thread seeteena
On 12/22/2017 01:07 PM, Markus Armbruster wrote: Eric Blake writes: On 12/19/2017 08:20 AM, Max Reitz wrote: So there are three things: (1) We probably should not allow snapshot names that could be IDs. Easiest way to solve this: Names have to start with a non-digit. Yes, that would be a

Re: [Qemu-devel] [GPU and VFIO] qemu hang at startup, VFIO_IOMMU_MAP_DMA is extremely slow

2018-01-01 Thread Bob Chen
Ping... Was it because VFIO_IOMMU_MAP_DMA needs contiguous memory and my host was not able to provide them immediately? 2017-12-26 19:37 GMT+08:00 Bob Chen : > > > 2017-12-26 18:51 GMT+08:00 Liu, Yi L : > >> > -Original Message- >> > From: Qemu-devel [mailto:qemu-devel-bounces+yi.l.liu=

Re: [Qemu-devel] [RFC 0/3] Extend vhost-user to support VFIO based accelerators

2018-01-01 Thread Liang, Cunming
> -Original Message- > From: Alexey Kardashevskiy [mailto:a...@ozlabs.ru] > Sent: Tuesday, January 2, 2018 2:01 PM > To: Liang, Cunming ; Bie, Tiwei > ; > virtio-...@lists.oasis-open.org; qemu-devel@nongnu.org; m...@redhat.com; > alex.william...@redhat.com; pbonz...@redhat.com; stefa...@

Re: [Qemu-devel] [RFC 0/3] Extend vhost-user to support VFIO based accelerators

2018-01-01 Thread Liang, Cunming
> -Original Message- > From: Alexey Kardashevskiy [mailto:a...@ozlabs.ru] > Sent: Tuesday, January 2, 2018 10:42 AM > To: Bie, Tiwei ; virtio-...@lists.oasis-open.org; qemu- > de...@nongnu.org; m...@redhat.com; alex.william...@redhat.com; > pbonz...@redhat.com; stefa...@redhat.com > Cc: T