Re: [RFC PATCH v6 1/2] hw/misc/sifive_u_otp: Add write function and write-once protection

2020-10-14 Thread Green Wan
On Wed, Oct 14, 2020 at 1:37 PM Bin Meng wrote: > > Hi Green, > > On Mon, Sep 28, 2020 at 6:12 PM Green Wan wrote: > > > > - Add write operation to update fuse data bit when PWE bit is on. > > - Add array, fuse_wo, to store the 'written' status for all bits > >of OTP to block the write oper

Re: [PATCH] vhost-user: add separate memslot counter for vhost-user

2020-10-14 Thread Michael S. Tsirkin
On Tue, Oct 13, 2020 at 08:58:59PM -0400, Raphael Norwitz wrote: > On Tue, Oct 6, 2020 at 5:48 AM Igor Mammedov wrote: > > > > On Mon, 28 Sep 2020 21:17:31 +0800 > > Jiajun Chen wrote: > > > > > Used_memslots is equal to dev->mem->nregions now, it is true for > > > vhost kernel, but not for vhost

Re: [RFC PATCH 0/3] target/mips: Make the number of TLB entries a CPU property

2020-10-14 Thread Richard Purdie
On Wed, 2020-10-14 at 01:36 +, Victor Kamensky (kamensky) wrote: > Thank you very much for looking at this. I gave a spin to > your 3 patch series in original setup, and as expected with > '-cpu 34Kf,tlb-entries=64' option it works great. > > If nobody objects, and your patches could be merged

Re: [RFC PATCH v6 1/2] hw/misc/sifive_u_otp: Add write function and write-once protection

2020-10-14 Thread Bin Meng
Hi Green, On Wed, Oct 14, 2020 at 3:02 PM Green Wan wrote: > > On Wed, Oct 14, 2020 at 1:37 PM Bin Meng wrote: > > > > Hi Green, > > > > On Mon, Sep 28, 2020 at 6:12 PM Green Wan wrote: > > > > > > - Add write operation to update fuse data bit when PWE bit is on. > > > - Add array, fuse_wo, t

Re: [RFC PATCH 0/3] target/mips: Make the number of TLB entries a CPU property

2020-10-14 Thread Richard Purdie
On Tue, 2020-10-13 at 19:22 -0700, Richard Henderson wrote: > On 10/13/20 4:11 PM, Richard Henderson wrote: > > On 10/13/20 6:25 AM, Philippe Mathieu-Daudé wrote: > > > Yocto developers have expressed interest in running MIPS32 > > > CPU with custom number of TLB: > > > https://lists.gnu.org/archiv

[PATCH 03/10] Reduce the time of checkpoint for COLO

2020-10-14 Thread Zhang Chen
From: "Rao, Lei" we should set ram_bulk_stage to false after ram_state_init, otherwise the bitmap will be unused in migration_bitmap_find_dirty. all pages in ram cache will be flushed to the ram of secondary guest for each checkpoint. Signed-off-by: leirao Signed-off-by: Zhang Chen Reviewed-by

[PATCH 01/10] net/filter-rewriter: destroy g_hash_table in colo_rewriter_cleanup

2020-10-14 Thread Zhang Chen
From: Pan Nengyuan s->connection_track_table forgot to destroy in colo_rewriter_cleanup. Fix it. Reported-by: Euler Robot Signed-off-by: Pan Nengyuan Signed-off-by: Zhang Chen Reviewed-by: Zhang Chen Reviewed-by: Li Qiang --- net/filter-rewriter.c | 2 ++ 1 file changed, 2 insertions(+) d

[PATCH 00/10] COLO project queued patches 20-Oct

2020-10-14 Thread Zhang Chen
From: Zhang Chen Hi Jason, this series include latest COLO related patches. please check and merge it. Thanks Zhang Chen Li Zhijian (2): colo-compare: fix missing compare_seq initialization colo-compare: check mark in mutual exclusion Pan Nengyuan (1): net/filter-rewriter: destroy g_hash

[PATCH 05/10] colo-compare: fix missing compare_seq initialization

2020-10-14 Thread Zhang Chen
From: Li Zhijian Signed-off-by: Li Zhijian Signed-off-by: Zhang Chen Reviewed-by: Zhang Chen --- net/colo.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/net/colo.c b/net/colo.c index a6c66d829a..ef00609848 100644 --- a/net/colo.c +++ b/net/colo.c @@ -133,14 +133,11

[PATCH 04/10] Fix the qemu crash when guest shutdown in COLO mode

2020-10-14 Thread Zhang Chen
From: "Rao, Lei" In COLO mode, if the startup parameters of QEMU include "no-shutdown", QEMU will crash when the guest shutdown. The root cause is when the guest shutdown, the state of VM will switch COLO to SHUTDOWN. When do checkpoint again, the state will be changed to COLO. But the state swit

[PATCH 02/10] Optimize seq_sorter function for colo-compare

2020-10-14 Thread Zhang Chen
From: "Rao, Lei" The seq of tcp has been filled in fill_pkt_tcp_info, it can be used directly here. Signed-off-by: leirao Signed-off-by: Zhang Chen Reviewed-by: Li Zhijian Reviewed-by: Zhang Chen --- net/colo-compare.c | 6 +- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a

[PATCH 07/10] net/colo-compare.c: Fix compare_timeout format issue

2020-10-14 Thread Zhang Chen
From: Zhang Chen This parameter need compare with the return of qemu_clock_get_ms(), it is uinit64_t. So we need fix this issue here. Reported-by: Derek Su Signed-off-by: Zhang Chen Reviewed-by: Li Zhijian --- net/colo-compare.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions

[PATCH 09/10] net/colo-compare.c: Add secondary old packet detection

2020-10-14 Thread Zhang Chen
From: Zhang Chen Detect queued secondary packet to sync VM state in time. Signed-off-by: Zhang Chen Reviewed-by: Li Zhijian --- net/colo-compare.c | 25 - 1 file changed, 16 insertions(+), 9 deletions(-) diff --git a/net/colo-compare.c b/net/colo-compare.c index 61c95

Re: [PATCH v1 1/2] fuzz: add virtio-blk fuzz target

2020-10-14 Thread Dima Stepanov
On Tue, Oct 13, 2020 at 11:30:52AM -0400, Alexander Bulekov wrote: > On 201007 1647, Dima Stepanov wrote: > > The virtio-blk fuzz target sets up and fuzzes the available virtio-blk > > queues. The implementation is based on two files: > > - tests/qtest/fuzz/virtio_scsi_fuzz.c > > - tests/qtest/

[PATCH 06/10] colo-compare: check mark in mutual exclusion

2020-10-14 Thread Zhang Chen
From: Li Zhijian Signed-off-by: Li Zhijian Signed-off-by: Zhang Chen Reviewed-by: Zhang Chen --- net/colo-compare.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/net/colo-compare.c b/net/colo-compare.c index 86980cef5e..24c366eec0 100644 --- a/net/colo-compare.c ++

[RFC v1 2/2] accel/tcg: split tcg_start_vcpu_thread

2020-10-14 Thread Claudio Fontana
after the initial split into 3 tcg variants, we proceed to also split tcg_start_vcpu_thread. We actually split it in 2 this time, since the icount variant just uses the round robin function. Signed-off-by: Claudio Fontana --- accel/tcg/tcg-all.c | 5 accel/tcg/tcg-cpus-icount.c |

[PATCH 08/10] net/colo-compare.c: Change the timer clock type

2020-10-14 Thread Zhang Chen
From: Zhang Chen The virtual clock only runs during the emulation. It stops when the virtual machine is stopped. The host clock should be used for device models that emulate accurate real time sources. It will continue to run when the virtual machine is suspended. COLO need to know the host time

[RFC v1 0/2] tcg-cpus: split into 3 tcg variants

2020-10-14 Thread Claudio Fontana
The purpose of this series is to split the tcg-cpus into 3 variants: tcg_cpus_mttcg(multithreaded tcg vcpus) tcg_cpus_rr (single threaded round robin vcpus) tcg_cpus_icount (same as RR, but using icount) Alex, I read the comment in tcg_start_vcpu_thread saying: /* * Initiali

[RFC v1 1/2] accel/tcg: split CpusAccel into three TCG variants

2020-10-14 Thread Claudio Fontana
split up the CpusAccel tcg_cpus into three TCG variants: tcg_cpus_rr (single threaded, round robin cpus) tcg_cpus_icount (same as rr, but with instruction counting enabled) tcg_cpus_mttcg (multi-threaded cpus) Signed-off-by: Claudio Fontana --- accel/tcg/meson.build | 9 +- accel/tcg/tc

Re: [PATCH 2/2] qga: add ssh-{add,remove}-authorized-keys

2020-10-14 Thread Marc-André Lureau
Hi On Wed, Oct 14, 2020 at 1:14 AM Philippe Mathieu-Daudé wrote: > > Hi Marc-André, > > On 10/13/20 10:25 PM, marcandre.lur...@redhat.com wrote: > > From: Marc-André Lureau > > > > Add new commands to add and remove SSH public keys from > > ~/.ssh/authorized_keys. > > > > I took a different appr

Re: [PATCH v1 1/2] fuzz: add virtio-blk fuzz target

2020-10-14 Thread Dima Stepanov
On Wed, Oct 14, 2020 at 10:29:41AM +0300, Dima Stepanov wrote: > On Tue, Oct 13, 2020 at 11:30:52AM -0400, Alexander Bulekov wrote: > > On 201007 1647, Dima Stepanov wrote: > > > The virtio-blk fuzz target sets up and fuzzes the available virtio-blk > > > queues. The implementation is based on two

Re: [RFC v1 1/2] accel/tcg: split CpusAccel into three TCG variants

2020-10-14 Thread Philippe Mathieu-Daudé
On 10/14/20 9:36 AM, Claudio Fontana wrote: split up the CpusAccel tcg_cpus into three TCG variants: tcg_cpus_rr (single threaded, round robin cpus) tcg_cpus_icount (same as rr, but with instruction counting enabled) tcg_cpus_mttcg (multi-threaded cpus) Signed-off-by: Claudio Fontana --- acc

Re: [RFC v1 0/2] tcg-cpus: split into 3 tcg variants

2020-10-14 Thread Philippe Mathieu-Daudé
On 10/14/20 9:36 AM, Claudio Fontana wrote: The purpose of this series is to split the tcg-cpus into 3 variants: tcg_cpus_mttcg(multithreaded tcg vcpus) tcg_cpus_rr (single threaded round robin vcpus) tcg_cpus_icount (same as RR, but using icount) Good idea!

[Bug 1899082] Re: ReplayKernel.test_x86_64_pc fails intermittently

2020-10-14 Thread Pavel Dovgalyuk
I traced this bug to hw/char/serial.c/serial_ioport_read Bug disappears when I add qemu_log("serial_ioport_read %x %x\n", (int)addr, ret); into the end of this function. I suppose that there is avocado (or socket) io synchronization problem, because running the same test without avocado works nor

[PULL 6/9] vnc-stubs: Allow -vnc none

2020-10-14 Thread Gerd Hoffmann
From: Jason Andryuk Currently `-vnc none` is fatal when built with `--disable-vnc`. Make vnc_parse accept "none", so QEMU still run without using vnc. Signed-off-by: Jason Andryuk Message-id: 20201009014032.3507-1-jandr...@gmail.com Signed-off-by: Gerd Hoffmann --- ui/vnc-stubs.c | 3 +++ 1

[PULL 8/9] input-linux: Reset il->fd handler before closing it

2020-10-14 Thread Gerd Hoffmann
From: Colin Xu If object-del input-linux object on-the-fly, instance finalize will close evdev fd without resetting it. However the main thread is still trying to lock_acquire/lock_release during ppoll, which leads to a very high CPU utilization. Signed-off-by: Colin Xu Reviewed-by: Li Qiang M

[PULL 5/9] configure: Fixes ncursesw detection under msys2/mingw by convert them to meson

2020-10-14 Thread Gerd Hoffmann
From: Yonggang Luo The mingw pkg-config are showing following absolute path and contains : as the separator, -D_XOPEN_SOURCE=600 -D_POSIX_C_SOURCE=199506L -IC:/CI-Tools/msys64/mingw64/include/ncursesw:-I/usr/include/ncursesw: -DNCURSES_WIDECHAR -D_XOPEN_SOURCE=600 -D_POSIX_C_SOURCE=199506L -IC

[PULL 3/9] curses: Fixes curses compiling errors.

2020-10-14 Thread Gerd Hoffmann
From: Yonggang Luo This is the compiling error: ../ui/curses.c: In function 'curses_refresh': ../ui/curses.c:256:5: error: 'next_maybe_keycode' may be used uninitialized in this function [-Werror=maybe-uninitialized] 256 | curses2foo(_curses2keycode, _curseskey2keycode, chr, maybe_keycode)

[PULL 1/9] qemu-edid: drop cast

2020-10-14 Thread Gerd Hoffmann
Not needed and makes some compilers error out with: qemu-edid.c:15:1: error: initializer element is not constant Signed-off-by: Gerd Hoffmann Reviewed-by: Daniel P. Berrangé Message-id: 20201013091615.14166-1-kra...@redhat.com --- qemu-edid.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(

[PATCH] buildsys: Help git-diff adding .gitattributes config file

2020-10-14 Thread Philippe Mathieu-Daudé
Since commits 0979ed017f0 ("meson: rename .inc.h files to .h.inc") and 139c1837db7 ("meson: rename included C source files to .c.inc") 'git-diff --function-context' stopped displaying C function context correctly. We can help git-diff by providing attributes to the .[ch].inc path names. See: https:

[PULL 9/9] ui: Fix default window_id value

2020-10-14 Thread Gerd Hoffmann
From: Samuel Thibault ./chardev/baum.c expects the default window_id value to be -1, and not 0 which could be confused with a proper window id (when numbered from 0 by the ui backend). This fixes getting Braille output with the curses and gtk frontends. Fixes: f29b3431f62 ("console: move window

[PULL 0/9] Ui 20201014 patches

2020-10-14 Thread Gerd Hoffmann
The following changes since commit 96292515c07e3a99f5a29540ed2f257b1ff75111: Merge remote-tracking branch 'remotes/vivier2/tags/trivial-branch-for-5.2-pull-request' into staging (2020-10-13 14:06:22 +0100) are available in the Git repository at: git://git.kraxel.org/qemu tags/u

[PULL 2/9] curses: Fixes compiler error that complain don't have langinfo.h on msys2/mingw

2020-10-14 Thread Gerd Hoffmann
From: Yonggang Luo msys2/mingw lacks the POSIX-required langinfo.h. gcc test.c -DNCURSES_WIDECHAR -I/mingw64/include/ncursesw -pipe -lncursesw -lgnurx -ltre -lintl -liconv test.c:4:10: fatal error: langinfo.h: No such file or directory 4 | #include | ^~~~ compilation

[PULL 4/9] win32: Simplify gmtime_r detection not depends on if _POSIX_C_SOURCE are defined on msys2/mingw

2020-10-14 Thread Gerd Hoffmann
From: Yonggang Luo We remove the CONFIG_LOCALTIME_R detection option in configure, and move the check existence of gmtime_r from configure into C header and source directly by using macro `_POSIX_THREAD_SAFE_FUNCTIONS`. Before this patch, the configure script are always assume the compiler does

[PULL 7/9] SDL: enable OpenGL context creation

2020-10-14 Thread Gerd Hoffmann
From: Jan Henrik Weinstock We need to specify SDL_WINDOW_OPENGL if we want to create an OpenGL context on it, i.e. when using '-device virtio-gpu-pci,virgl=on' Signed-off-by: Jan Henrik Weinstock Message-id: b2ba98b3-2975-0d4d-1c56-f659923c7...@rwth-aachen.de Signed-off-by: Gerd Hoffmann ---

Re: Why guest physical addresses are not the same as the corresponding host virtual addresses in QEMU/KVM? Thanks!

2020-10-14 Thread Paolo Bonzini
On 13/10/20 22:36, harry harry wrote: > Hi Paolo and Sean, > > Thanks much for your prompt replies and clear explanations. > > On Tue, Oct 13, 2020 at 2:43 AM Paolo Bonzini wrote: >> >> No, the logic to find the HPA with a given HVA is the same as the >> hardware logic to translate HVA -> HPA.

Re: Why guest physical addresses are not the same as the corresponding host virtual addresses in QEMU/KVM? Thanks!

2020-10-14 Thread Paolo Bonzini
On 14/10/20 00:40, harry harry wrote: > Q1: Is there any file like ``/proc/pid/pagemap'' to record the > mappings between GPAs and HVAs in the host OS? No, there isn't. > Q2: Seems that there might be extra overhead (e.g., synchronization > between EPT tables and host regular page tables; maintai

Re: Why guest physical addresses are not the same as the corresponding host virtual addresses in QEMU/KVM? Thanks!

2020-10-14 Thread Maxim Levitsky
On Tue, 2020-10-13 at 16:36 -0400, harry harry wrote: > Hi Paolo and Sean, > > Thanks much for your prompt replies and clear explanations. > > On Tue, Oct 13, 2020 at 2:43 AM Paolo Bonzini wrote: > > No, the logic to find the HPA with a given HVA is the same as the > > hardware logic to translat

[PATCH v2] hw/block/nvme: add dulbe support

2020-10-14 Thread Klaus Jensen
From: Klaus Jensen This adds support for reporting the Deallocated or Unwritten Logical Block error (DULBE). Rely on the block status reported by the block layer. Here, we consider blocks with the BDRV_BLOCK_ZERO status to deallocated. This is because a pdiscard or write zeroes with unmap won't

Re: [PATCH] hw/block/nvme: add block utilization tracking

2020-10-14 Thread Klaus Jensen
On Oct 13 14:06, Keith Busch wrote: > On Tue, Oct 13, 2020 at 09:08:46PM +0200, Klaus Jensen wrote: > > From: Klaus Jensen > > > > This adds support for reporting the Deallocated or Unwritten Logical > > Block error (DULBE). This requires tracking the allocated/deallocated > > status of all logic

Re: [PATCH v1 1/2] fuzz: add virtio-blk fuzz target

2020-10-14 Thread Darren Kenny
Hi Dima, On Wednesday, 2020-10-14 at 10:39:01 +03, Dima Stepanov wrote: > On Wed, Oct 14, 2020 at 10:29:41AM +0300, Dima Stepanov wrote: >> On Tue, Oct 13, 2020 at 11:30:52AM -0400, Alexander Bulekov wrote: >> > On 201007 1647, Dima Stepanov wrote: ... >> > >> > I sent a patch to disable QEMU's

Re: [PATCH] fuzz: Disable QEMU's signal handlers

2020-10-14 Thread Darren Kenny
On Tuesday, 2020-10-13 at 17:52:46 +01, Daniel P. Berrangé wrote: > On Tue, Oct 13, 2020 at 05:50:37PM +0100, Darren Kenny wrote: >> Hi Alex, >> >> This mentions the use of atexit() to perform some cleanup, but I'm not >> seeing that being added here, should it be? > > The reference to atexit is s

Re: [PATCH v5 2/2] hw/arm/sbsa-ref: add SBSA watchdog device

2020-10-14 Thread Graeme Gregory
On Tue, Oct 13, 2020 at 11:16:31AM -0400, Shashi Mallela wrote: > Included the newly implemented SBSA generic watchdog device model into > SBSA platform > > Signed-off-by: Shashi Mallela > --- > hw/arm/sbsa-ref.c | 50 +++ > 1 file changed, 50 insertio

Re: [PATCH v4 2/3] qga: add implementation of guest-get-disks for Linux

2020-10-14 Thread Tomáš Golembiovský
On Tue, Oct 13, 2020 at 11:26:45AM +0400, Marc-André Lureau wrote: > Hi > > On Mon, Oct 12, 2020 at 12:36 PM Tomáš Golembiovský > wrote: > > > The command lists all disks (real and virtual) as well as disk > > partitions. For each disk the list of dependent disks is also listed and > > /dev path

Re: [PATCH v2] migration/block-dirty-bitmap: fix uninitialized variable warning

2020-10-14 Thread Max Reitz
On 14.10.20 03:03, Chenqun (kuhn) wrote: > > >> -Original Message- >> From: Max Reitz [mailto:mre...@redhat.com] >> Sent: Tuesday, October 13, 2020 10:47 PM >> To: Chenqun (kuhn) ; qemu-devel@nongnu.org; >> qemu-triv...@nongnu.org >> Cc: vsement...@virtuozzo.com; stefa...@redhat.com; f...

RE: [PATCH V2] target/riscv: raise exception to HS-mode at get_physical_address

2020-10-14 Thread Jiangyifei
> -Original Message- > From: Richard Henderson [mailto:richard.hender...@linaro.org] > Sent: Friday, October 9, 2020 10:34 PM > To: Jiangyifei ; qemu-devel@nongnu.org; > qemu-ri...@nongnu.org > Cc: Zhanghailiang ; > sag...@eecs.berkeley.edu; kbast...@mail.uni-paderborn.de; Zhangxiaofeng >

Re: [RFC v1 0/2] tcg-cpus: split into 3 tcg variants

2020-10-14 Thread Alex Bennée
Claudio Fontana writes: > The purpose of this series is to split the tcg-cpus into > 3 variants: > > tcg_cpus_mttcg(multithreaded tcg vcpus) > tcg_cpus_rr (single threaded round robin vcpus) > tcg_cpus_icount (same as RR, but using icount) I've no objection to the cosmetic clean-up

[PATCH V3] target/riscv: raise exception to HS-mode at get_physical_address

2020-10-14 Thread Yifei Jiang
VS-stage translation at get_physical_address needs to translate pte address by G-stage translation. But the G-stage translation error can not be distinguished from VS-stage translation error in riscv_cpu_tlb_fill. On migration, destination needs to rebuild pte, and this G-stage translation error mu

Re: [RFC PATCH 3/3] target/mips: Make the number of TLB entries a CPU property

2020-10-14 Thread Jiaxun Yang
在 2020/10/13 21:25, Philippe Mathieu-Daudé 写道: Allow changing the number of TLB entries for testing/tunning purpose. Example to force a 34Kf cpu with 64 TLB: $ qemu-system-mipsel -cpu 34Kf,tlb-entries=64 ... This is helpful for developers of the Yocto Project [*]: Yocto Project uses

Re: [RFC v1 0/2] tcg-cpus: split into 3 tcg variants

2020-10-14 Thread Claudio Fontana
On 10/14/20 12:14 PM, Alex Bennée wrote: > > Claudio Fontana writes: > >> The purpose of this series is to split the tcg-cpus into >> 3 variants: >> >> tcg_cpus_mttcg(multithreaded tcg vcpus) >> tcg_cpus_rr (single threaded round robin vcpus) >> tcg_cpus_icount (same as RR, but using

RE: [PATCH V2 1/5] target/riscv: Add basic vmstate description of CPU

2020-10-14 Thread Jiangyifei
> -Original Message- > From: Richard Henderson [mailto:richard.hender...@linaro.org] > Sent: Saturday, October 10, 2020 9:23 PM > To: Jiangyifei ; qemu-devel@nongnu.org; > qemu-ri...@nongnu.org > Cc: pal...@dabbelt.com; alistair.fran...@wdc.com; > sag...@eecs.berkeley.edu; kbast...@mail.un

[PATCH] usb/hcd-ehci: Fix error handling on missing device for iTD

2020-10-14 Thread Anthony PERARD via
The EHCI Host Controller emulation attempt to locate the device associated with a periodic isochronous transfer description (iTD) and when this fail the host controller is reset. But according the EHCI spec 1.0 section 5.15.2.4 Host System Error, the host controller is supposed to reset itself onl

Re: [PATCH 0/2] qemu-ga: add ssh-{add,remove}-authorized-keys

2020-10-14 Thread Michal Privoznik
On 10/13/20 10:25 PM, marcandre.lur...@redhat.com wrote: From: Marc-André Lureau Hi, Add two new commands to help modify ~/.ssh/authorized_keys. Apart from Philippe's comments, this path is configurable in sshd.config. But I doubt we should care as ssh-copy-id doesn't care. Although it'

Re: [PATCH v11 02/13] copy-on-read: add filter append/drop functions

2020-10-14 Thread Max Reitz
On 12.10.20 19:43, Andrey Shinkevich wrote: > Provide API for the COR-filter insertion/removal. > Also, drop the filter child permissions for an inactive state when the > filter node is being removed. > > Signed-off-by: Andrey Shinkevich > Reviewed-by: Vladimir Sementsov-Ogievskiy > --- > block

Re: [PATCH 0/2] qemu-ga: add ssh-{add,remove}-authorized-keys

2020-10-14 Thread Daniel P . Berrangé
On Wed, Oct 14, 2020 at 12:25:00AM +0400, marcandre.lur...@redhat.com wrote: > From: Marc-André Lureau > > Hi, > > Add two new commands to help modify ~/.ssh/authorized_keys. > > Although it's possible already to modify the authorized_keys files via > file-{read,write} or exec, the commands are

Re: [RFC PATCH 3/3] target/mips: Make the number of TLB entries a CPU property

2020-10-14 Thread Philippe Mathieu-Daudé
On 10/14/20 12:20 PM, Jiaxun Yang wrote: 在 2020/10/13 21:25, Philippe Mathieu-Daudé 写道: Allow changing the number of TLB entries for testing/tunning purpose. Example to force a 34Kf cpu with 64 TLB:    $ qemu-system-mipsel -cpu 34Kf,tlb-entries=64 ... This is helpful for developers of the Yoc

Re: [PATCH v11 04/13] copy-on-read: pass overlay base node name to COR driver

2020-10-14 Thread Max Reitz
On 12.10.20 19:43, Andrey Shinkevich wrote: > We are going to use the COR-filter for a block-stream job. > To limit COR operations by the base node in the backing chain during > stream job, pass the name of overlay base node to the copy-on-read > driver as base node itself may change due to possibl

Re: [PATCH v4 1/7] nbd: Utilize QAPI_CLONE for type conversion

2020-10-14 Thread Vladimir Sementsov-Ogievskiy
10.10.2020 00:55, Eric Blake wrote: Rather than open-coding the translation from the deprecated NbdServerAddOptions type to the preferred BlockExportOptionsNbd, it's better to utilize QAPI_CLONE_MEMBERS. This solves a couple of issues: first, if we do any more refactoring of the base type (which

Re: [PATCH 2/2] qga: add ssh-{add,remove}-authorized-keys

2020-10-14 Thread Philippe Mathieu-Daudé
On 10/14/20 9:37 AM, Marc-André Lureau wrote: On Wed, Oct 14, 2020 at 1:14 AM Philippe Mathieu-Daudé wrote: On 10/13/20 10:25 PM, marcandre.lur...@redhat.com wrote: diff --git a/qga/qapi-schema.json b/qga/qapi-schema.json index cec98c7e06..50e2854b45 100644 --- a/qga/qapi-schema.json +++ b/qga

RE: [PATCH v2] migration/block-dirty-bitmap: fix uninitialized variable warning

2020-10-14 Thread Chenqun (kuhn)
> -Original Message- > From: Qemu-devel > [mailto:qemu-devel-bounces+kuhn.chenqun=huawei@nongnu.org] On > Behalf Of Max Reitz > Sent: Wednesday, October 14, 2020 5:36 PM > To: Chenqun (kuhn) ; qemu-devel@nongnu.org; > qemu-triv...@nongnu.org > Cc: f...@euphon.net; ganqixin ; > vsement..

Re: [RFC v1 0/2] tcg-cpus: split into 3 tcg variants

2020-10-14 Thread Philippe Mathieu-Daudé
On 10/14/20 12:14 PM, Alex Bennée wrote: Claudio Fontana writes: The purpose of this series is to split the tcg-cpus into 3 variants: tcg_cpus_mttcg(multithreaded tcg vcpus) tcg_cpus_rr (single threaded round robin vcpus) tcg_cpus_icount (same as RR, but using icount) I've no o

[PATCH v3 2/9] hw/block/nvme: add uuid namespace parameter

2020-10-14 Thread Klaus Jensen
From: Klaus Jensen Add the 'uuid' nvme-ns device parameter such that users who requires a persistent namespace UUID can explicitly specify it. If not specified, the property will autogenerate an UUID for each QEMU invocation. Signed-off-by: Klaus Jensen --- hw/block/nvme-ns.h | 1 + hw/block

[PATCH v3 1/9] hw/block/nvme: add commands supported and effects log page

2020-10-14 Thread Klaus Jensen
From: Gollu Appalanaidu This is to support for the Commands Supported and Effects log page. See NVM Express Spec 1.3d, sec. 5.14.1.5 ("Commands Supported and Effects") Signed-off-by: Gollu Appalanaidu Signed-off-by: Klaus Jensen --- include/block/nvme.h | 25 +-- hw/block/nvme.c

[PATCH v3 4/9] hw/block/nvme: add basic read/write for zoned namespaces

2020-10-14 Thread Klaus Jensen
From: Klaus Jensen This adds basic read and write for zoned namespaces. A zoned namespace is created by setting the iocs namespace parameter to 0x2 and specifying the zns.zcap parameter (zone capacity) in number of logical blocks per zone. If a zone size (zns.zsze) is not specified, the namespac

[PATCH v3 9/9] hw/block/nvme: allow open to close zone transitions by controller

2020-10-14 Thread Klaus Jensen
From: Klaus Jensen Allow the controller to release open resources by transitioning implicitly and explicitly opened zones to closed. This is done using a naive "least recently opened" strategy. Signed-off-by: Klaus Jensen --- hw/block/nvme-ns.h| 5 hw/block/nvme-ns.c| 5 hw

[PATCH v3 3/9] hw/block/nvme: support namespace types

2020-10-14 Thread Klaus Jensen
From: Klaus Jensen Implement support for TP 4056 ("Namespace Types"). This adds the 'iocs' (I/O Command Set) device parameter to the nvme-ns device. Signed-off-by: Klaus Jensen --- docs/specs/nvme.txt | 3 + hw/block/nvme-ns.h| 11 ++- hw/block/nvme.h | 3 + include/block/nvme

[PATCH v3 7/9] hw/block/nvme: add the zone append command

2020-10-14 Thread Klaus Jensen
From: Klaus Jensen Add the Zone Append command. Signed-off-by: Klaus Jensen --- hw/block/nvme.h | 6 ++ include/block/nvme.h | 7 +++ hw/block/nvme.c | 46 +++ hw/block/trace-events | 1 + 4 files changed, 60 insertions(+) diff -

[PATCH v3 0/9] hw/block/nvme: zoned namespace command set

2020-10-14 Thread Klaus Jensen
From: Klaus Jensen Updated version of my proposal. Based-on: <20201014084324.333774-1-...@irrelevant.dk> Changes for v3 ~~ * Rebased on nvme-next with "[PATCH v2] hw/block/nvme: add dulbe support" applied. * "hw/block/nvme: add support for dulbe and block utilization track

[PATCH v3 6/9] hw/block/nvme: add the zone management send command

2020-10-14 Thread Klaus Jensen
From: Klaus Jensen Add the Zone Management Send command. Signed-off-by: Klaus Jensen --- hw/block/nvme.h | 2 + include/block/nvme.h | 28 +++ hw/block/nvme.c | 384 +- hw/block/trace-events | 11 ++ 4 files changed, 420 insertions(+), 5

Re: [PATCH v6 02/11] hw/block/nvme: Generate namespace UUIDs

2020-10-14 Thread Klaus Jensen
On Oct 14 06:42, Dmitry Fomichev wrote: > In NVMe 1.4, a namespace must report an ID descriptor of UUID type > if it doesn't support EUI64 or NGUID. Add a new namespace property, > "uuid", that provides the user the option to either specify the UUID > explicitly or have a UUID generated automatical

[PATCH v3 5/9] hw/block/nvme: add the zone management receive command

2020-10-14 Thread Klaus Jensen
From: Klaus Jensen Add the Zone Management Receive command. Signed-off-by: Klaus Jensen --- hw/block/nvme-ns.h| 8 +++ hw/block/nvme.h | 1 + include/block/nvme.h | 46 + hw/block/nvme-ns.c| 12 +++- hw/block/nvme.c | 146 +

[PATCH v3] migration/block-dirty-bitmap: fix uninitialized variable warning

2020-10-14 Thread Chen Qun
A default value is provided for the variable 'bitmap_name' to avoid compiler warning. The compiler show warning: migration/block-dirty-bitmap.c:1090:13: warning: ‘bitmap_name’ may be used uninitialized in this function [-Wmaybe-uninitialized] g_strlcpy(s->bitmap_name, bitmap_name, sizeof(s

[PATCH v3 8/9] hw/block/nvme: track and enforce zone resources

2020-10-14 Thread Klaus Jensen
From: Klaus Jensen Track number of open/active resources. Signed-off-by: Klaus Jensen --- docs/specs/nvme.txt | 6 hw/block/nvme-ns.h | 7 + include/block/nvme.h | 2 ++ hw/block/nvme-ns.c | 25 +++-- hw/block/nvme.c | 66 ++

[PATCH 2/9] util/vfio-helpers: Trace PCI I/O config accesses

2020-10-14 Thread Philippe Mathieu-Daudé
We sometime get kernel panic with some devices on Aarch64 hosts. Alex Williamson suggests it might be broken PCIe root complex. Add trace event to record the latest I/O access before crashing. In case, assert our accesses are aligned. Signed-off-by: Philippe Mathieu-Daudé --- Cc: Alex Williamson

Re: [PATCH v4 2/7] nbd: Add new qemu:allocation-depth metadata context

2020-10-14 Thread Vladimir Sementsov-Ogievskiy
10.10.2020 00:55, Eric Blake wrote: 'qemu-img map' provides a way to determine which extents of an image come from the top layer vs. inherited from a backing chain. This is useful information worth exposing over NBD. There is a proposal to add a QMP command block-dirty-bitmap-populate which can

[PATCH 1/9] util/vfio-helpers: Improve reporting unsupported IOMMU type

2020-10-14 Thread Philippe Mathieu-Daudé
Change the confuse "VFIO IOMMU check failed" error message by the explicit "VFIO IOMMU Type1 is not supported" once. Example on POWER: $ qemu-system-ppc64 -drive if=none,id=nvme0,file=nvme://0001:01:00.0/1,format=raw qemu-system-ppc64: -drive if=none,id=nvme0,file=nvme://0001:01:00.0/1,format

[PATCH 3/9] util/vfio-helpers: Trace PCI BAR region info

2020-10-14 Thread Philippe Mathieu-Daudé
For debug purpose, trace BAR regions info. Signed-off-by: Philippe Mathieu-Daudé --- util/vfio-helpers.c | 8 util/trace-events | 1 + 2 files changed, 9 insertions(+) diff --git a/util/vfio-helpers.c b/util/vfio-helpers.c index 1d4efafcaa4..cd6287c3a98 100644 --- a/util/vfio-helpers

[PATCH 0/9] util/vfio-helpers: Improve debugging experience

2020-10-14 Thread Philippe Mathieu-Daudé
A bunch of boring patches that have been proven helpful while debugging. Philippe Mathieu-Daudé (9): util/vfio-helpers: Improve reporting unsupported IOMMU type util/vfio-helpers: Trace PCI I/O config accesses util/vfio-helpers: Trace PCI BAR region info util/vfio-helpers: Trace where BARs

[PATCH 6/9] util/vfio-helpers: Convert vfio_dump_mapping to trace events

2020-10-14 Thread Philippe Mathieu-Daudé
The QEMU_VFIO_DEBUG definition is only modifiable at build-time. Trace events can be enabled at run-time. As we prefer the latter, convert qemu_vfio_dump_mappings() to use trace events instead of fprintf(). Signed-off-by: Philippe Mathieu-Daudé --- util/vfio-helpers.c | 19 --- u

Re: [PATCH v2 1/4] MAINTAINERS: Put myself forward for MIPS target

2020-10-14 Thread Thomas Huth
On 13/10/2020 12.16, Philippe Mathieu-Daudé wrote: > To avoid the MIPS target being orphan, volunteer to keep an eye > on it and put together pull requests. > > Signed-off-by: Philippe Mathieu-Daudé > --- > MAINTAINERS | 6 -- > 1 file changed, 4 insertions(+), 2 deletions(-) > > diff --git

[PATCH 5/9] util/vfio-helpers: Improve DMA trace events

2020-10-14 Thread Philippe Mathieu-Daudé
For debugging purpose, trace where DMA regions are mapped. Signed-off-by: Philippe Mathieu-Daudé --- util/vfio-helpers.c | 3 ++- util/trace-events | 5 +++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/util/vfio-helpers.c b/util/vfio-helpers.c index 278c54902e7..c24a510df82

[PATCH 8/9] util/vfio-helpers: Let qemu_vfio_do_mapping() propagate Error

2020-10-14 Thread Philippe Mathieu-Daudé
Pass qemu_vfio_do_mapping() an Error* argument so it can propagate any error to callers. Replace error_report() which only report to the monitor by the more generic error_setg_errno(). Signed-off-by: Philippe Mathieu-Daudé --- util/vfio-helpers.c | 8 1 file changed, 4 insertions(+), 4

[PATCH 7/9] util/vfio-helpers: Let qemu_vfio_dma_map() propagate Error

2020-10-14 Thread Philippe Mathieu-Daudé
Currently qemu_vfio_dma_map() displays errors on stderr. When using management interface, this information is simply lost. Pass qemu_vfio_dma_map() an Error* argument so it can propagate the error to callers. Signed-off-by: Philippe Mathieu-Daudé --- include/qemu/vfio-helpers.h | 2 +- block/nv

[PATCH 4/9] util/vfio-helpers: Trace where BARs are mapped

2020-10-14 Thread Philippe Mathieu-Daudé
For debugging purpose, trace where a BAR is mapped. Signed-off-by: Philippe Mathieu-Daudé --- util/vfio-helpers.c | 2 ++ util/trace-events | 1 + 2 files changed, 3 insertions(+) diff --git a/util/vfio-helpers.c b/util/vfio-helpers.c index cd6287c3a98..278c54902e7 100644 --- a/util/vfio-help

[PATCH 9/9] util/vfio-helpers: Let qemu_vfio_verify_mappings() use error_report()

2020-10-14 Thread Philippe Mathieu-Daudé
Instead of displaying the error on stderr, use error_report() which also report to the monitor. Signed-off-by: Philippe Mathieu-Daudé --- util/vfio-helpers.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/util/vfio-helpers.c b/util/vfio-helpers.c index 2c4598d7faa..488dd

Re: [PATCH v11 05/13] copy-on-read: limit COR operations to base in COR driver

2020-10-14 Thread Max Reitz
On 12.10.20 19:43, Andrey Shinkevich wrote: > Limit COR operations by the base node in the backing chain when the > overlay base node name is given. It will be useful for a block stream > job when the COR-filter is applied. The overlay base node is passed as > the base itself may change due to conc

Re: [PATCH v11 05/13] copy-on-read: limit COR operations to base in COR driver

2020-10-14 Thread Max Reitz
On 12.10.20 19:43, Andrey Shinkevich wrote: > Limit COR operations by the base node in the backing chain when the > overlay base node name is given. It will be useful for a block stream > job when the COR-filter is applied. The overlay base node is passed as > the base itself may change due to conc

Re: [PATCH v11 04/13] copy-on-read: pass overlay base node name to COR driver

2020-10-14 Thread Max Reitz
On 14.10.20 13:09, Max Reitz wrote: > On 12.10.20 19:43, Andrey Shinkevich wrote: >> We are going to use the COR-filter for a block-stream job. >> To limit COR operations by the base node in the backing chain during >> stream job, pass the name of overlay base node to the copy-on-read >> driver as

Re: [PATCH] hw/usb/hcd-dwc2: fix divide-by-zero in dwc2_handle_packet()

2020-10-14 Thread Gerd Hoffmann
Hi, > I sent you a patch to fix up several assert()s, including that one, about a > month ago. Did you miss it? > https://lore.kernel.org/qemu-devel/20200920021449.830-1-pauld...@gmail.com Seems I missed that, or deleted by accident. Added to qemu queue now. thanks, Gerd

Re: [PATCH v6 05/11] hw/block/nvme: Support Zoned Namespace Command Set

2020-10-14 Thread Niklas Cassel
On Wed, Oct 14, 2020 at 06:42:06AM +0900, Dmitry Fomichev wrote: > The emulation code has been changed to advertise NVM Command Set when > "zoned" device property is not set (default) and Zoned Namespace > Command Set otherwise. > > Define values and structures that are needed to support Zoned > N

Re: [PATCH] usb/hcd-ehci: Fix error handling on missing device for iTD

2020-10-14 Thread Gerd Hoffmann
On Wed, Oct 14, 2020 at 11:41:06AM +0100, Anthony PERARD wrote: > The EHCI Host Controller emulation attempt to locate the device > associated with a periodic isochronous transfer description (iTD) and > when this fail the host controller is reset. > > But according the EHCI spec 1.0 section 5.15.

[PATCH 1/2] i386/cpu: Add the Intel PT capabilities checking before extend the CPUID level

2020-10-14 Thread Luwei Kang
The current implementation will extend the CPUID level to 0x14 if Intel PT is enabled in the guest(in x86_cpu_expand_features()) and the Intel PT will be disabled if it can't pass the capabilities checking later(in x86_cpu_filter_features()). In this case, the level of CPUID will be still 0x14 and

[PATCH 2/2] i386/cpu: Make the Intel PT LIP feature configurable

2020-10-14 Thread Luwei Kang
The current implementation will disable the guest Intel PT feature if the Intel PT LIP feature is supported on the host, but the LIP feature is comming soon(e.g. SnowRidge and later). This patch will make the guest LIP feature configurable and Intel PT feature can be enabled in guest when the gues

Re: [PATCH v4 3/3] replay: do not build if TCG is not available

2020-10-14 Thread Pavel Dovgalyuk
On 14.10.2020 09:51, Claudio Fontana wrote: привет Pavel! On 10/14/20 7:42 AM, Pavel Dovgalyuk wrote: On 13.10.2020 22:21, Claudio Fontana wrote: this fixes non-TCG builds broken recently by replay reverse debugging. stub the needed functions in stub/, including errors for hmp and qmp. This i

[PATCH v5 2/7] ui/spice-app: don't use qemu_chr_open_spice_port directly

2020-10-14 Thread Gerd Hoffmann
Save the parent object's open function pointer in the (new) VCChardevClass struct instead before overwriting it, so we can look it up when needed. Signed-off-by: Gerd Hoffmann Reviewed-by: Philippe Mathieu-Daudé --- ui/spice-app.c | 17 + 1 file changed, 13 insertions(+), 4 dele

[PATCH v5 3/7] chardev/spice: make qemu_chr_open_spice_port static

2020-10-14 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann Reviewed-by: Philippe Mathieu-Daudé --- include/chardev/spice.h | 3 --- chardev/spice.c | 8 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/include/chardev/spice.h b/include/chardev/spice.h index 99f26aedde54..1115502cdfbd 100644 ---

[PATCH v5 1/7] qemu-edid: drop cast

2020-10-14 Thread Gerd Hoffmann
Not needed and makes some compilers error out with: qemu-edid.c:15:1: error: initializer element is not constant Signed-off-by: Gerd Hoffmann Reviewed-by: Daniel P. Berrangé Message-id: 20201013091615.14166-1-kra...@redhat.com --- qemu-edid.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(

[PATCH v5 7/7] chardev/spice: build spice chardevs as module

2020-10-14 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- util/module.c | 2 ++ chardev/meson.build | 7 ++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/util/module.c b/util/module.c index a44ec38d9362..4a5735dfdc76 100644 --- a/util/module.c +++ b/util/module.c @@ -264,6 +264,8 @@ static stru

[PATCH v5 0/7] build spice chardevs as module

2020-10-14 Thread Gerd Hoffmann
v3: - fix spice-app - init objects before spice - meson cleanup v4: - rebase to latest master, adapt to qom changes. - add patches to fix modular builds. - pick up review tags. v5: - rebase to latest master, fixup conflicts. Gerd Hoffmann (7): qemu-edid: drop cast ui/spice-app: don't us

[PATCH v5 4/7] chardev/spice: simplify chardev setup

2020-10-14 Thread Gerd Hoffmann
Initialize spice before chardevs. That allows to register the spice chardevs directly in the init function and removes the need to maintain a linked list of chardevs just for registration. Signed-off-by: Gerd Hoffmann --- include/chardev/spice.h | 1 - include/ui/qemu-spice.h | 1 - chardev/s

  1   2   3   4   >