Re: [PATCH v9 7/8] KVM: Handle page fault for private memory

2022-10-28 Thread Chao Peng
On Wed, Oct 26, 2022 at 02:54:25PM -0700, Isaku Yamahata wrote: > On Tue, Oct 25, 2022 at 11:13:43PM +0800, > Chao Peng wrote: > > > A memslot with KVM_MEM_PRIVATE being set can include both fd-based > > private memory and hva-based shared memory. Architecture code (like TDX > > code) can tell wh

Re: [PATCH v9 2/8] KVM: Extend the memslot to support fd-based private memory

2022-10-28 Thread Xiaoyao Li
On 10/25/2022 11:13 PM, Chao Peng wrote: In memory encryption usage, guest memory may be encrypted with special key and can be accessed only by the guest itself. We call such memory private memory. It's valueless and sometimes can cause problem to allow userspace to access guest private memory. T

Re: [PULL 00/23] 9p queue 2022-10-24

2022-10-28 Thread Thomas Huth
On 27/10/2022 22.42, Christian Schoenebeck wrote: On Thursday, October 27, 2022 7:37:07 PM CEST Stefan Hajnoczi wrote: On Thu, 27 Oct 2022 at 12:38, Christian Schoenebeck wrote: On Thursday, October 27, 2022 5:53:47 PM CEST Thomas Huth wrote: On 24/10/2022 12.54, Christian Schoenebeck wrote:

Re: [PATCH] vl: change PID file path resolve error to warning

2022-10-28 Thread Fiona Ebner
Am 27.10.22 um 14:17 schrieb Daniel P. Berrangé: > On Thu, Oct 27, 2022 at 12:14:43PM +0200, Fiona Ebner wrote: >> +warn_report("not removing PID file on exit: cannot resolve PID >> file" >> +" path: %s: %s", pid_file, strerror(errno)); >> +return; >

[PATCH v2 2/3] io_uring: use LuringState from the running thread

2022-10-28 Thread Emanuele Giuseppe Esposito
Remove usage of aio_context_acquire by always submitting asynchronous AIO to the current thread's LuringState. In order to prevent mistakes from the caller side, avoid passing LuringState in luring_io_{plug/unplug} and luring_co_submit. Signed-off-by: Emanuele Giuseppe Esposito --- block/file-p

[PATCH v2 0/3] AioContext removal: LinuxAioState and ThreadPool

2022-10-28 Thread Emanuele Giuseppe Esposito
Just remove some AioContext lock in LinuxAioState and ThreadPool. Not related to anything specific, so I decided to send it as a separate patch. These patches are taken from Paolo's old draft series. --- v2: * assertion in thread_pool * remove useless BlockDriverState * param in patch 1 and 2 * i

[PATCH v2 1/3] linux-aio: use LinuxAioState from the running thread

2022-10-28 Thread Emanuele Giuseppe Esposito
From: Paolo Bonzini Remove usage of aio_context_acquire by always submitting asynchronous AIO to the current thread's LinuxAioState. In order to prevent mistakes from the caller side, avoid passing LinuxAioState in laio_io_{plug/unplug} and laio_co_submit. Signed-off-by: Paolo Bonzini Signed-o

[PATCH v2 3/3] thread-pool: use ThreadPool from the running thread

2022-10-28 Thread Emanuele Giuseppe Esposito
Use qemu_get_current_aio_context() where possible, since we always submit work to the current thread anyways. We want to also be sure that the thread submitting the work is the same as the one processing the pool, to avoid adding synchronization to the pool list. Signed-off-by: Paolo Bonzini Sig

[PATCH] tcg/tci: fix logic error when registering helpers via FFI

2022-10-28 Thread Icenowy Zheng
When registering helpers via FFI for TCI, the inner loop that iterates parameters of the helper reuses (and thus pollutes) the same variable used by the outer loop that iterates all helpers, thus made some helpers unregistered. Fix this logic error by using a dedicated temporary variable for the i

Re: [PATCH v9 1/8] mm: Introduce memfd_restricted system call to create restricted user memory

2022-10-28 Thread Chao Peng
On Wed, Oct 26, 2022 at 10:31:45AM -0700, Isaku Yamahata wrote: > On Tue, Oct 25, 2022 at 11:13:37PM +0800, > Chao Peng wrote: > > > +int restrictedmem_get_page(struct file *file, pgoff_t offset, > > + struct page **pagep, int *order) > > +{ > > + struct restrictedmem_data

Re: [PATCH] vl: change PID file path resolve error to warning

2022-10-28 Thread Thomas Lamprecht
On 28/10/2022 09:11, Fiona Ebner wrote: > Am 27.10.22 um 14:17 schrieb Daniel P. Berrangé: >> On Thu, Oct 27, 2022 at 12:14:43PM +0200, Fiona Ebner wrote: >>> +warn_report("not removing PID file on exit: cannot resolve PID >>> file" >>> +" path: %s: %s", pid_fil

Re: [PATCH v5 00/13] Instantiate VT82xx functions in host device

2022-10-28 Thread Bernhard Beschow
Am 27. Oktober 2022 22:11:21 UTC schrieb "Philippe Mathieu-Daudé" : >Hi Daniel, Bernhard, > >On 27/10/22 11:47, Daniel Henrique Barboza wrote: >> On 10/27/22 05:21, Bernhard Beschow wrote: >>> Am 16. September 2022 14:36:05 UTC schrieb "Philippe Mathieu-Daudé" >>> : On 12/9/22 21:50, Bernhar

Re: [PATCH v6 04/11] tests/qtest: device-plug-test: Reverse the usage of double/single quotes

2022-10-28 Thread Thomas Huth
On 28/10/2022 06.57, Bin Meng wrote: The usage of double/single quotes in test_q35_pci_unplug_json_request() should be reversed to work on both win32 and non-win32 platforms: - The value of -device parameter needs to be surrounded by "" as Windows does not drop '' when passing it to QEMU whic

[PATCH v17 00/10]vhost-vdpa: add support for configure interrupt

2022-10-28 Thread Cindy Lu
These patches introduced the support for configure interrupt These codes are tested on x86_64 and aarch64 platforms. the test scenario is based on vp-vdpa/vdpa_sim /virtio net device, with the irqfd and without irqfd. Tested in virtio-pci bus and virtio-mmio bus Change in v2: Add support for

Re: [PATCH] vl: change PID file path resolve error to warning

2022-10-28 Thread Fiona Ebner
Am 28.10.22 um 09:26 schrieb Thomas Lamprecht: > On 28/10/2022 09:11, Fiona Ebner wrote: >> Am 27.10.22 um 14:17 schrieb Daniel P. Berrangé: >>> On Thu, Oct 27, 2022 at 12:14:43PM +0200, Fiona Ebner wrote: +warn_report("not removing PID file on exit: cannot resolve PID file"

[PATCH v17 01/10] virtio: introduce macro VIRTIO_CONFIG_IRQ_IDX

2022-10-28 Thread Cindy Lu
To support configure interrupt for vhost-vdpa Introduce VIRTIO_CONFIG_IRQ_IDX -1 as configure interrupt's queue index, Then we can reuse the functions guest_notifier_mask and guest_notifier_pending. Add the check of queue index in these drivers, if the driver does not support configure interrupt, t

[PATCH v17 03/10] virtio-pci: decouple the single vector from the interrupt process

2022-10-28 Thread Cindy Lu
To reuse the interrupt process in configure interrupt Need to decouple the single vector from the interrupt process. We add new function kvm_virtio_pci_vector_use_one and _release_one. These functions are used for the single vector, the whole process will finish in the loop with vq number. Signed-

[PATCH v17 02/10] virtio-pci: decouple notifier from interrupt process

2022-10-28 Thread Cindy Lu
To reuse the notifier process. We add the virtio_pci_get_notifier to get the notifier and vector. The INPUT for this function is IDX, The OUTPUT is the notifier and the vector Signed-off-by: Cindy Lu --- hw/virtio/virtio-pci.c | 88 +++--- 1 file changed, 57 i

[PATCH v17 05/10] vhost-vdpa: add support for config interrupt

2022-10-28 Thread Cindy Lu
Add new call back function in vhost-vdpa, The function vhost_set_config_call can set the event fd to kernel. This function will be called in the vhost_dev_start and vhost_dev_stop Signed-off-by: Cindy Lu --- hw/virtio/trace-events | 1 + hw/virtio/vhost-vdpa.c | 8 2 files changed, 9 in

[PATCH v17 04/10] vhost: introduce new VhostOps vhost_set_config_call

2022-10-28 Thread Cindy Lu
This patch introduces new VhostOps vhost_set_config_call. This function allows the qemu to set the config event fd to kernel driver. Signed-off-by: Cindy Lu --- include/hw/virtio/vhost-backend.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/include/hw/virtio/vhost-backend.h b/include/h

[PATCH v17 06/10] virtio: add support for configure interrupt

2022-10-28 Thread Cindy Lu
Add the functions to support the configure interrupt in virtio The function virtio_config_guest_notifier_read will notify the guest if there is an configure interrupt. The function virtio_config_set_guest_notifier_fd_handler is to set the fd hander for the notifier Signed-off-by: Cindy Lu --- hw

[PATCH v17 08/10] virtio-net: add support for configure interrupt

2022-10-28 Thread Cindy Lu
Add functions to support configure interrupt in virtio_net Add the functions to support vhost_net_config_pending and vhost_net_config_mask. Signed-off-by: Cindy Lu --- hw/net/vhost_net.c | 9 + hw/net/virtio-net.c | 4 ++-- include/net/vhost_net.h | 2 ++ 3 files changed, 13 ins

[PATCH v17 09/10] virtio-mmio: add support for configure interrupt

2022-10-28 Thread Cindy Lu
Add configure interrupt support in virtio-mmio bus. add function to set configure guest notifier. Signed-off-by: Cindy Lu --- hw/virtio/virtio-mmio.c | 27 +++ 1 file changed, 27 insertions(+) diff --git a/hw/virtio/virtio-mmio.c b/hw/virtio/virtio-mmio.c index d240efef9

Re: [PATCH v6 08/11] tests/qtest: libqos: Do not build virtio-9p unconditionally

2022-10-28 Thread Thomas Huth
On 28/10/2022 06.57, Bin Meng wrote: At present the virtio-9p related codes are built into libqos unconditionally. Change to build them conditionally by testing the 'virtfs' config option. Signed-off-by: Bin Meng Reviewed-by: Thomas Huth

[PATCH v17 10/10] virtio-pci: add support for configure interrupt

2022-10-28 Thread Cindy Lu
Add process to handle the configure interrupt, The function's logic is the same with vq interrupt.Add extra process to check the configure interrupt Signed-off-by: Cindy Lu --- hw/virtio/virtio-pci.c | 110 - include/hw/virtio/virtio-pci.h | 4 +- 2 file

[PATCH v17 07/10] vhost: add support for configure interrupt

2022-10-28 Thread Cindy Lu
Add functions to support configure interrupt. The configure interrupt process will start in vhost_dev_start and stop in vhost_dev_stop. Also add the functions to support vhost_config_pending and vhost_config_mask. Signed-off-by: Cindy Lu --- hw/virtio/vhost.c | 78 ++

Re: [PATCH v6 05/11] tests/qtest: Use EXIT_FAILURE instead of magic number

2022-10-28 Thread Thomas Huth
On 28/10/2022 06.57, Bin Meng wrote: When migration fails, QEMU exits with a status code EXIT_FAILURE. Change qtests to use the well-defined macro instead of magic number. Signed-off-by: Bin Meng --- Changes in v6: - new patch: "tests/qtest: Use EXIT_FAILURE instead of magic number" tests/

Re: [PATCH v6 06/11] tests/qtest: libqtest: Introduce qtest_wait_qemu()

2022-10-28 Thread Thomas Huth
On 28/10/2022 06.57, Bin Meng wrote: Introduce an API for qtest to wait for the QEMU process to terminate. Suggested-by: Marc-André Lureau Signed-off-by: Bin Meng --- Changes in v6: - new patch: "tests/qtest: libqtest: Introduce qtest_wait_qemu()" tests/qtest/libqtest.h | 9 ++ test

Re: [PATCH v6 00/11] tests/qtest: Enable running qtest on Windows

2022-10-28 Thread Marc-André Lureau
Hi On Fri, Oct 28, 2022 at 8:58 AM Bin Meng wrote: > In preparation to adding virtio-9p support on Windows, this series > enables running qtest on Windows, so that we can run the virtio-9p > tests on Windows to make sure it does not break accidently. > > Changes in v6: > - drop patches that are

Re: [PATCH v2 2/6] target/i386: Use cpu_unwind_state_data for tpr access

2022-10-28 Thread Claudio Fontana
On 10/27/22 22:13, Richard Henderson wrote: > On 10/27/22 22:22, Claudio Fontana wrote: >> On 10/27/22 12:02, Richard Henderson wrote: >>> +/* Per x86_restore_state_to_opc. */ >>> +if (TARGET_TB_PCREL) { >>> +return (env->eip & TARGET_PAGE_MASK) | data[0]; >>> +} else { >>> +

[PATCH] linux-user: always translate cmsg when recvmsg

2022-10-28 Thread Icenowy Zheng
It's possible that a message contains both normal payload and ancillary data in the same message, and even if no ancillary data is available this information should be passed to the target, otherwise the target cmsghdr will be left uninitialized and the target is going to access uninitialized memor

Re: [PATCH 1/1] tcg: add perfmap and jitdump

2022-10-28 Thread Christian Borntraeger
Am 12.10.22 um 07:18 schrieb Ilya Leoshkevich: Add ability to dump /tmp/perf-.map and jit-.dump. The first one allows the perf tool to map samples to each individual translation block. The second one adds the ability to resolve symbol names, line numbers and inspect JITed code. Example of use:

Re: [PATCH v3 05/13] mac_{old|new}world: Simplify cmdline_base calculation

2022-10-28 Thread Mark Cave-Ayland
On 14/10/2022 16:25, BALATON Zoltan wrote: On Fri, 14 Oct 2022, BALATON Zoltan wrote: On Fri, 14 Oct 2022, Mark Cave-Ayland wrote: On 03/10/2022 21:13, BALATON Zoltan wrote: By slight reorganisation we can avoid an else branch and some code duplication which makes it easier to follow the cod

Re: [PATCH v3 00/13] Misc ppc/mac machines clean up

2022-10-28 Thread Mark Cave-Ayland
On 18/10/2022 12:37, BALATON Zoltan wrote: On Tue, 11 Oct 2022, BALATON Zoltan wrote: On Mon, 3 Oct 2022, BALATON Zoltan wrote: This series includes some clean ups to mac_newworld and mac_oldworld to make them a bit simpler and more readable, It also removes the shared mac.h file that turns ou

Re: [PATCH v4 00/19] Misc ppc/mac machines clean up

2022-10-28 Thread Mark Cave-Ayland
On 25/10/2022 17:44, BALATON Zoltan wrote: Since only one week is left until freeze starts I've included some more patches in this version that I've intended to submit after the clean ups but we're running out of time now. The last 3 patches could be squashed together, I've just split these up b

Re: megasas regression in 7.1?

2022-10-28 Thread Thomas Huth
On 28/10/2022 07.47, John Johnson wrote: I pulled 7.1, and the megasas driver stopped being able to do reads from a disk. It looks to be related to this commit: https://github.com/qemu/qemu/commit/fe9d8927e265fd723a6dc87cd6d220f4677dbe1f#diffe3f5f30efc54747e0624dca63e5f55f0012736c1875b

Re: [PATCH] tcg/tci: fix logic error when registering helpers via FFI

2022-10-28 Thread Alex Bennée
Icenowy Zheng writes: > When registering helpers via FFI for TCI, the inner loop that iterates > parameters of the helper reuses (and thus pollutes) the same variable > used by the outer loop that iterates all helpers, thus made some helpers > unregistered. > > Fix this logic error by using a d

Re: [PATCH] tcg/tci: fix logic error when registering helpers via FFI

2022-10-28 Thread Icenowy Zheng
在 2022-10-28星期五的 10:13 +0100,Alex Bennée写道: > > Icenowy Zheng writes: > > > When registering helpers via FFI for TCI, the inner loop that > > iterates > > parameters of the helper reuses (and thus pollutes) the same > > variable > > used by the outer loop that iterates all helpers, thus made som

Re: [PATCH] tcg/tci: fix logic error when registering helpers via FFI

2022-10-28 Thread Philippe Mathieu-Daudé
On 28/10/22 09:21, Icenowy Zheng wrote: When registering helpers via FFI for TCI, the inner loop that iterates parameters of the helper reuses (and thus pollutes) the same variable used by the outer loop that iterates all helpers, thus made some helpers unregistered. Oops, I didn't notice while

Re: [PATCH v2 4/6] target/openrisc: Use cpu_unwind_state_data for mfspr

2022-10-28 Thread Claudio Fontana
On 10/27/22 12:02, Richard Henderson wrote: > Since we do not plan to exit, use cpu_unwind_state_data > and extract exactly the data requested. > > Signed-off-by: Richard Henderson > --- > target/openrisc/sys_helper.c | 11 +-- > 1 file changed, 9 insertions(+), 2 deletions(-) > > diff

Re: [PATCH v6 00/11] tests/qtest: Enable running qtest on Windows

2022-10-28 Thread Bin Meng
On Fri, Oct 28, 2022 at 4:09 PM Marc-André Lureau wrote: > > Hi > > On Fri, Oct 28, 2022 at 8:58 AM Bin Meng wrote: >> >> In preparation to adding virtio-9p support on Windows, this series >> enables running qtest on Windows, so that we can run the virtio-9p >> tests on Windows to make sure it do

Re: [PATCH] memory: Fix wrong end address dump

2022-10-28 Thread Philippe Mathieu-Daudé
On 28/10/22 04:19, Duan, Zhenzhong wrote: -Original Message- From: David Hildenbrand Sent: Friday, July 22, 2022 2:44 PM To: Duan, Zhenzhong ; qemu- de...@nongnu.org Cc: pbonz...@redhat.com; pet...@redhat.com; f4...@amsat.org Subject: Re: [PATCH] memory: Fix wrong end address dump On

Re: [PATCH 3/3] vdpa: Expose VIRTIO_NET_F_STATUS unconditionally

2022-10-28 Thread Eugenio Perez Martin
On Fri, Oct 28, 2022 at 3:59 AM Jason Wang wrote: > > On Thu, Oct 27, 2022 at 6:18 PM Eugenio Perez Martin > wrote: > > > > On Thu, Oct 27, 2022 at 8:54 AM Jason Wang wrote: > > > > > > On Thu, Oct 27, 2022 at 2:47 PM Eugenio Perez Martin > > > wrote: > > > > > > > > On Thu, Oct 27, 2022 at 6:3

Re: [PATCH v10 1/9] s390x/cpu topology: core_id sets s390x CPU topology

2022-10-28 Thread Pierre Morel
On 10/27/22 22:20, Janis Schoetterl-Glausch wrote: On Wed, 2022-10-26 at 10:34 +0200, Pierre Morel wrote: On 10/25/22 21:58, Janis Schoetterl-Glausch wrote: On Wed, 2022-10-12 at 18:20 +0200, Pierre Morel wrote: In the S390x CPU topology the core_id specifies the CPU address and the positi

Re: [PATCH v4 16/19] mac_newworld: Add machine types for different mac99 configs

2022-10-28 Thread Mark Cave-Ayland
On 25/10/2022 17:44, BALATON Zoltan wrote: The mac99 machine emulates different machines depending on machine properties or even if it is run as qemu-system-ppc64 or qemu-system-ppc. This is very confusing for users and many hours were lost trying to explain it or finding out why commands users

Re: [PATCH v6 00/11] tests/qtest: Enable running qtest on Windows

2022-10-28 Thread Marc-André Lureau
Hi On Fri, Oct 28, 2022 at 1:21 PM Bin Meng wrote: > On Fri, Oct 28, 2022 at 4:09 PM Marc-André Lureau > wrote: > > > > Hi > > > > On Fri, Oct 28, 2022 at 8:58 AM Bin Meng wrote: > >> > >> In preparation to adding virtio-9p support on Windows, this series > >> enables running qtest on Windows,

Re: [PATCH v4 19/19] mac_newworld: Document deprecation

2022-10-28 Thread Mark Cave-Ayland
On 25/10/2022 17:44, BALATON Zoltan wrote: Also update PowerMac family docs with some more recent info. Signed-off-by: BALATON Zoltan --- docs/about/deprecated.rst| 7 +++ docs/system/ppc/powermac.rst | 12 2 files changed, 15 insertions(+), 4 deletions(-) diff --git

Re: [PATCH v6 00/11] tests/qtest: Enable running qtest on Windows

2022-10-28 Thread Bin Meng
On Fri, Oct 28, 2022 at 5:41 PM Marc-André Lureau wrote: > > Hi > > On Fri, Oct 28, 2022 at 1:21 PM Bin Meng wrote: >> >> On Fri, Oct 28, 2022 at 4:09 PM Marc-André Lureau >> wrote: >> > >> > Hi >> > >> > On Fri, Oct 28, 2022 at 8:58 AM Bin Meng wrote: >> >> >> >> In preparation to adding virti

Re: [PATCH v5 20/20] mac_{old, new}world: Pass MacOS VGA NDRV in card ROM instead of fw_cfg

2022-10-28 Thread Mark Cave-Ayland
On 25/10/2022 22:31, BALATON Zoltan wrote: OpenBIOS cannot run FCode ROMs yet but it can detect NDRV in VGA card ROM and add it to the device tree for MacOS. Pass the NDRV this way instead of via fw_cfg. This solves the problem with OpenBIOS also adding the NDRV to ati-vga which it does not work

[GIT PULL 3/8] util: Introduce qemu_thread_set_affinity() and qemu_thread_get_affinity()

2022-10-28 Thread David Hildenbrand
Usually, we let upper layers handle CPU pinning, because pthread_setaffinity_np() (-> sched_setaffinity()) is blocked via seccomp when starting QEMU with -sandbox enable=on,resourcecontrol=deny However, we want to configure and observe the CPU affinity of threads from QEMU directly in some cas

[GIT PULL 1/8] hw/mem/nvdimm: fix error message for 'unarmed' flag

2022-10-28 Thread David Hildenbrand
From: Julia Suvorova In the ACPI specification [1], the 'unarmed' bit is set when a device cannot accept a persistent write. This means that when a memdev is read-only, the 'unarmed' flag must be turned on. The logic is correct, just changing the error message. [1] ACPI NFIT NVDIMM Region Mappin

[GIT PULL 6/8] util: Make qemu_prealloc_mem() optionally consume a ThreadContext

2022-10-28 Thread David Hildenbrand
... and implement it under POSIX. When a ThreadContext is provided, create new threads via the context such that these new threads obtain a properly configured CPU affinity. Reviewed-by: Michal Privoznik Message-Id: <20221014134720.168738-6-da...@redhat.com> Signed-off-by: David Hildenbrand ---

[GIT PULL 7/8] hostmem: Allow for specifying a ThreadContext for preallocation

2022-10-28 Thread David Hildenbrand
Let's allow for specifying a thread context via the "prealloc-context" property. When set, preallcoation threads will be crated via the thread context -- inheriting the same CPU affinity as the thread context. Pinning preallcoation threads to CPUs can heavily increase performance in NUMA setups, b

[GIT PULL 0/8] Host Memory Backends and Memory devices patches

2022-10-28 Thread David Hildenbrand
The following changes since commit 0529245488865038344d64fff7ee05864d3d17f6: Merge tag 'pull-target-arm-20221020' of https://git.linaro.org/people/pmaydell/qemu-arm into staging (2022-10-20 14:36:12 -0400) are available in the Git repository at: https://github.com/davidhildenbrand/qemu.git

Re: [PATCH v3 0/8] AArch64/HMAT support and tests

2022-10-28 Thread Yicong Yang via
Hi Hesham, On 2022/10/27 18:00, Hesham Almatary wrote: > This patchset adds support for AArch64/HMAT including a test. > It relies on other two patch sets from: > > Brice Goglin: to support -numa without initiators on q35/x86. > https://lore.kernel.org/all/ed23accb-2c8b-90f4-a7a3-f81cc57bf...@i

[GIT PULL 2/8] util: Cleanup and rename os_mem_prealloc()

2022-10-28 Thread David Hildenbrand
Let's * give the function a "qemu_*" style name * make sure the parameters in the implementation match the prototype * rename smp_cpus to max_threads, which makes the semantics of that parameter clearer ... and add a function documentation. Reviewed-by: Michal Privoznik Message-Id: <2022101413

[GIT PULL 4/8] util: Introduce ThreadContext user-creatable object

2022-10-28 Thread David Hildenbrand
Setting the CPU affinity of QEMU threads is a bit problematic, because QEMU doesn't always have permissions to set the CPU affinity itself, for example, with seccomp after initialized by QEMU: -sandbox enable=on,resourcecontrol=deny General information about CPU affinities can be found in the

[GIT PULL 5/8] util: Add write-only "node-affinity" property for ThreadContext

2022-10-28 Thread David Hildenbrand
Let's make it easier to pin threads created via a ThreadContext to all host CPUs currently belonging to a given set of host NUMA nodes -- which is the common case. "node-affinity" is simply a shortcut for setting "cpu-affinity" manually to the list of host CPUs belonging to the set of host nodes.

[GIT PULL 8/8] vl: Allow ThreadContext objects to be created before the sandbox option

2022-10-28 Thread David Hildenbrand
Currently, there is no way to configure a CPU affinity inside QEMU when the sandbox option disables it for QEMU as a whole, for example, via: -sandbox enable=on,resourcecontrol=deny While ThreadContext objects can be created on the QEMU commandline and the CPU affinity can be configured extern

[PATCH v5 2/3] tests/lcitool: Refresh to latest libvirt-ci module

2022-10-28 Thread Philippe Mathieu-Daudé
From: Alex Bennée We need an updated lcitool for this to deal with the weirdness of a 32bit nsis tool for both 32 and 64 bit builds. As a result there are some minor whitespace and re-order changes in a bunch of the docker files. Signed-off-by: Alex Bennée Acked-by: Richard Henderson Message-I

[PATCH v5 0/3] tests/docker: update fedora-win[32|64]-cross with lcitool

2022-10-28 Thread Philippe Mathieu-Daudé
Hi Alex, in order to review carefully this patch: https://lore.kernel.org/qemu-devel/20221027183637.2772968-2-alex.ben...@linaro.org/ I split it in 3 to convert in trivial patches to review. (I kept your S-o-b tag). Please consider as a replacement for your testing/next PR. Regards, Phil. Alex

[PATCH v5 1/3] tests/lcitool: Rename non-Debian specific helper

2022-10-28 Thread Philippe Mathieu-Daudé
From: Alex Bennée This helper is not Debian specific, rename it to cross_build(). Signed-off-by: Alex Bennée Acked-by: Richard Henderson Message-Id: <20220929114231.583801-10-alex.ben...@linaro.org> Signed-off-by: Philippe Mathieu-Daudé --- tests/lcitool/refresh | 38 +++-

[PATCH v5 3/3] tests/docker: update fedora-win[32|64]-cross with lcitool

2022-10-28 Thread Philippe Mathieu-Daudé
From: Alex Bennée Convert another two dockerfiles to lcitool and update. Signed-off-by: Alex Bennée Acked-by: Richard Henderson Message-Id: <20220929114231.583801-10-alex.ben...@linaro.org> Signed-off-by: Philippe Mathieu-Daudé --- .../dockerfiles/fedora-win32-cross.docker | 139

Re: [PATCH v5 0/3] tests/docker: update fedora-win[32|64]-cross with lcitool

2022-10-28 Thread Philippe Mathieu-Daudé
On 28/10/22 11:56, Philippe Mathieu-Daudé wrote: Hi Alex, in order to review carefully this patch: https://lore.kernel.org/qemu-devel/20221027183637.2772968-2-alex.ben...@linaro.org/ I split it in 3 to convert in trivial patches to review. (I kept your S-o-b tag). Please consider as a replacemen

Re: [PATCH v10 2/9] s390x/cpu topology: reporting the CPU topology to the guest

2022-10-28 Thread Pierre Morel
On 10/27/22 22:42, Janis Schoetterl-Glausch wrote: On Wed, 2022-10-12 at 18:21 +0200, Pierre Morel wrote: The guest can use the STSI instruction to get a buffer filled with the CPU topology description. Let us implement the STSI instruction for the basis CPU topology level, level 2. Signed-

Re: [PATCH v5 2/3] tests/lcitool: Refresh to latest libvirt-ci module

2022-10-28 Thread Philippe Mathieu-Daudé
On 28/10/22 11:56, Philippe Mathieu-Daudé wrote: From: Alex Bennée We need an updated lcitool for this to deal with the weirdness of a 32bit nsis tool for both 32 and 64 bit builds. As a result s/nsis/NSIS/ there are some minor whitespace and re-order changes in a bunch of the docker files.

[PATCH v2 1/3] hw/i386/acpi-build: Remove unused struct

2022-10-28 Thread Bernhard Beschow
Ammends commit b23046abe78f48498a423b802d6d86ba0172d57f 'pc: acpi-build: simplify PCI bus tree generation'. Signed-off-by: Bernhard Beschow Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20221026133110.91828-2-shen...@gmail.com> --- hw/i386/acpi-build.c | 7 --- 1 file changed, 7 deletion

[PATCH v2 2/3] hw/i386/acpi-build: Resolve redundant attribute

2022-10-28 Thread Bernhard Beschow
The is_piix4 attribute is set once in one location and read once in another. Doing both in one location allows for removing the attribute altogether. Signed-off-by: Bernhard Beschow Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20221026133110.91828-3-shen...@gmail.com> --- hw/i386/acpi-build

[PATCH v2 0/3] hw/i386: Cleanup AML generation for north and south bridges

2022-10-28 Thread Bernhard Beschow
This series extends Igor's "x86: clean up ACPI PCI code part 2" series, doing some further cleanup. It also simplifies experimentation with different south bridges (PIIX4 and VT82xx) in the pc machine [1]. Testing done: * `mache check` * Start a live CD using "pc" and "q35" machine types v2: * Re

[PATCH v2 3/3] hw/i386/acpi-build: Resolve north rather than south bridges

2022-10-28 Thread Bernhard Beschow
The code currently assumes Q35 iff ICH9 and i440fx iff PIIX. Now that more AML generation has been moved into the south bridges and since the machines define themselves primarily through their north bridges, let's switch to resolving the north bridges for AML generation instead. This also allows fo

[PATCH v3 12/14] migration: Add support for 'fixed-ram' migration restore

2022-10-28 Thread Nikolay Borisov
Add the necessary code to parse the format changes for 'fixed-ram' capability. One of the more notable changes in behavior is that in the 'fixed-ram' case ram pages are restored in one go rather than constantly looping through the migration stream. Also due to idiosyncrasies of the format I have ad

[PATCH v3 08/14] io: Add preadv support to QIOChannelFile

2022-10-28 Thread Nikolay Borisov
preadv is going to be needed when 'fixed-ram'-enabled stream are to be restored. Add a minimal implementation of preadv for file channels and expose it via the generic io_preadv interface. Signed-off-by: Nikolay Borisov --- io/channel-file.c | 27 +++ 1 file changed, 27 i

Re: [PATCH 1/3] tcg/sparc: Remove support for sparc32plus

2022-10-28 Thread Philippe Mathieu-Daudé
On 17/10/22 08:24, Richard Henderson wrote: Since 9b9c37c36439, we have only supported sparc64 cpus. Debian and Gentoo now only support 64-bit sparc64 userland, so it is time to drop the 32-bit sparc64 userland: sparc32plus. Signed-off-by: Richard Henderson --- tcg/sparc/tcg-target.h | 1

Re: [PATCH 2/3] tcg/sparc64: Rename from tcg/sparc

2022-10-28 Thread Philippe Mathieu-Daudé
On 17/10/22 08:24, Richard Henderson wrote: Emphasize that we only support full 64-bit code generation. Signed-off-by: Richard Henderson --- meson.build | 4 +--- tcg/{sparc => sparc64}/tcg-target-con-set.h | 0 tcg/{sparc => sparc64}/tcg-target-con-str.h | 0

[PATCH v3 03/14] migration: Initial support of fixed-ram feature for analyze-migration.py

2022-10-28 Thread Nikolay Borisov
In order to allow analyze-migration.py script to work with migration streams that have the 'fixed-ram' capability set it's required to have access to the stream's configuration object. This commit enables this by making migration json writer part of MigrationState struct, allowing the configuration

[PATCH v3 04/14] io: Add generic pwritev/preadv interface

2022-10-28 Thread Nikolay Borisov
Introduce basic pwriteve/preadv support in the generic channel layer. SPecific implementation will follow for the file channel as this is required in order to support migration streams with fixed location of each ram page. Signed-off-by: Nikolay Borisov --- include/io/channel.h | 49

[PATCH v3 07/14] migration/qemu-file: add utility methods for working with seekable channels

2022-10-28 Thread Nikolay Borisov
Add qemu_file_is_seekable/qemu_put_buffer_at/qemu_set_offset/qemu_get_offset as those utility methods will be needed when implementing 'fixed-ram' migration capability. Signed-off-by: Nikolay Borisov --- include/migration/qemu-file-types.h | 2 + migration/qemu-file.c | 59 +++

[PATCH v3 01/14] migration: support file: uri for source migration

2022-10-28 Thread Nikolay Borisov
Implement support for a "file:" uri so that a migration can be initiated directly to a file from QEMU. Unlike other migration protocol backends, the 'file' protocol cannot honour non-blocking mode. POSIX file/block storage will always report ready to read/write, regardless of how slow the underlyi

[PATCH v3 13/14] tests: Add migrate_incoming_qmp helper

2022-10-28 Thread Nikolay Borisov
file-based migration requires the target to initiate its migration after the source has finished writing out the data in the file. Currently there's no easy way to initiate 'migrate-incoming', allow this by introducing migrate_incoming_qmp helper, similarly to migrate_qmp. Signed-off-by: Nikolay B

[PATCH v3 09/14] migration: add qemu_get_buffer_at

2022-10-28 Thread Nikolay Borisov
Restoring a 'fixed-ram' enabled migration stream would require reading from specific offsets in the file so add a helper to QEMUFile that uses the newly introduced qio_channel_file_preadv. Signed-off-by: Nikolay Borisov --- migration/qemu-file.c | 23 +++ migration/qemu-file.

[PATCH v3 05/14] io: implement io_pwritev for QIOChannelFile

2022-10-28 Thread Nikolay Borisov
The upcoming 'fixed-ram' feature would require qemu to write data at specific offsets of the file. Add a minimal implementation of pwritev and expose it via the io_pwritev interface. Signed-off-by: Nikolay Borisov --- io/channel-file.c | 25 + 1 file changed, 25 insertion

[PATCH v3 14/14] tests/qtest: migration-test: Add tests for file-based migration

2022-10-28 Thread Nikolay Borisov
Add basic tests for file-based migration as well as for the 'fixed-ram' feature. Signed-off-by: Nikolay Borisov --- tests/qtest/migration-test.c | 46 1 file changed, 46 insertions(+) diff --git a/tests/qtest/migration-test.c b/tests/qtest/migration-test.c i

[PATCH v3 11/14] migration: Refactor precopy ram loading code

2022-10-28 Thread Nikolay Borisov
To facilitate easier implementaiton of the 'fixed-ram' migration restore factor out the code responsible for parsing the ramblocks headers. This also makes ram_load_precopy easier to comprehend. Signed-off-by: Nikolay Borisov --- migration/ram.c | 142 +++-

[PATCH v3 02/14] migration: Add support for 'file:' uri for incoming migration

2022-10-28 Thread Nikolay Borisov
This is a counterpart to the 'file:' uri support for source migration, now a file can also serve as the source of an incoming migration. Unlike other migration protocol backends, the 'file' protocol cannot honour non-blocking mode. POSIX file/block storage will always report ready to read/write, r

[PATCH v3 10/14] migration/ram: Introduce 'fixed-ram' migration stream capability

2022-10-28 Thread Nikolay Borisov
Implement 'fixed-ram' feature. The core of the feature is to ensure that each ram page of the migration stream has a specific offset in the resulting migration stream. The reason why we'd want such behavior are two fold: - When doing a 'fixed-ram' migration the resulting file will have a bound

Re: [PULL 00/23] 9p queue 2022-10-24

2022-10-28 Thread Christian Schoenebeck
On Friday, October 28, 2022 9:07:17 AM CEST Thomas Huth wrote: > On 27/10/2022 22.42, Christian Schoenebeck wrote: > > On Thursday, October 27, 2022 7:37:07 PM CEST Stefan Hajnoczi wrote: > >> On Thu, 27 Oct 2022 at 12:38, Christian Schoenebeck > >> wrote: > >>> > >>> On Thursday, October 27, 2022

[PATCH v3 00/14] File-based migration support and fixed-ram features

2022-10-28 Thread Nikolay Borisov
Here's the 3rd version of file-based migration support [0]. For background check the cover letter of the initial. The main changes are : - Updated commit message as per Daniel Berrange's suggestino for Patches 1-2 - Fixed tab in various pages - Added comments better explaining how json_writer_st

[PATCH v3 06/14] io: add and implement QIO_CHANNEL_FEATURE_SEEKABLE for channel file

2022-10-28 Thread Nikolay Borisov
Add a generic QIOChannel feature SEEKABLE which would be used by the qemu_file* apis. For the time being this will be only implemented for file channels. Signed-off-by: Nikolay Borisov --- include/io/channel.h | 1 + io/channel-file.c| 9 + 2 files changed, 10 insertions(+) diff --g

Re: megasas regression in 7.1?

2022-10-28 Thread John Millikin
Passing `sizeof(cdb)` to `scsi_req_new()` looks like a correct fix to me, but I'm not familiar enough with megasas / MegaRAID to be confident. A possible slight alteration is to have `megasas_encode_lba()` return the length of the CDB it synthesized, which IMO would make the dependency more clear.

Re: [PATCH v2 3/3] hw/i386/acpi-build: Resolve north rather than south bridges

2022-10-28 Thread Ani Sinha
On Fri, Oct 28, 2022 at 4:05 PM Bernhard Beschow wrote: > > The code currently assumes Q35 iff ICH9 and i440fx iff PIIX. Now that more > AML generation has been moved into the south bridges and since the > machines define themselves primarily through their north bridges, let's > switch to resolvin

[PATCH] 9pfs: fix missing sys/mount.h include

2022-10-28 Thread Christian Schoenebeck
Fixes the following build error: fsdev/file-op-9p.h:156:56: error: declaration of 'struct statfs' will not be visible outside of this function [-Werror,-Wvisibility] int (*statfs)(FsContext *s, V9fsPath *path, struct statfs *stbuf); ^

Re: [PATCH v6 00/11] tests/qtest: Enable running qtest on Windows

2022-10-28 Thread Thomas Huth
On 28/10/2022 11.43, Bin Meng wrote: On Fri, Oct 28, 2022 at 5:41 PM Marc-André Lureau wrote: Hi On Fri, Oct 28, 2022 at 1:21 PM Bin Meng wrote: On Fri, Oct 28, 2022 at 4:09 PM Marc-André Lureau wrote: Hi On Fri, Oct 28, 2022 at 8:58 AM Bin Meng wrote: In preparation to adding virti

Re: [PATCH v2 1/3] linux-aio: use LinuxAioState from the running thread

2022-10-28 Thread Paolo Bonzini
On 10/28/22 09:16, Emanuele Giuseppe Esposito wrote: From: Paolo Bonzini Remove usage of aio_context_acquire by always submitting asynchronous AIO to the current thread's LinuxAioState. In order to prevent mistakes from the caller side, avoid passing LinuxAioState in laio_io_{plug/unplug} and

Re: [PATCH v2 3/3] thread-pool: use ThreadPool from the running thread

2022-10-28 Thread Paolo Bonzini
On 10/28/22 09:16, Emanuele Giuseppe Esposito wrote: Use qemu_get_current_aio_context() where possible, since we always submit work to the current thread anyways. We want to also be sure that the thread submitting the work is the same as the one processing the pool, to avoid adding synchronizati

[PATCH v6 00/19] Misc ppc/mac machines clean up

2022-10-28 Thread BALATON Zoltan
Since only one week is left until freeze starts I've included some more patches in this version that I've intended to submit after the clean ups but we're running out of time now. The last 3 patches could be squashed together, I've just split these up because I expect resistence from Mark to any ch

[PATCH v6 12/19] mac_nvram: Use NVRAM_SIZE constant

2022-10-28 Thread BALATON Zoltan
The NVRAM_SIZE constant was defined but not used. Rename it to MACIO_NVRAM_SIZE to match the device model and use it where appropriate. Signed-off-by: BALATON Zoltan Reviewed-by: Mark Cave-Ayland --- hw/misc/macio/macio.c| 2 +- hw/ppc/mac_newworld.c| 4 ++-- include/hw/nvram/ma

[PATCH v6 02/19] mac_oldworld: Drop some more variables

2022-10-28 Thread BALATON Zoltan
Drop some more local variables additionally to commit b8df32555ce5 to match clean ups done to mac_newwold in previous patch. Signed-off-by: BALATON Zoltan Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Mark Cave-Ayland --- hw/ppc/mac_oldworld.c | 43 +

[PATCH v6 14/19] mac_newworld: Turn CORE99_VIA_CONFIG defines into an enum

2022-10-28 Thread BALATON Zoltan
This might allow the compiler to check values. Signed-off-by: BALATON Zoltan --- hw/ppc/mac_newworld.c | 10 ++ 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/hw/ppc/mac_newworld.c b/hw/ppc/mac_newworld.c index 37123daa6b..601ea518f8 100644 --- a/hw/ppc/mac_newworld.c +++

[PATCH v6 10/19] hw/ppc/mac.h: Move PROM and KERNEL defines to board code

2022-10-28 Thread BALATON Zoltan
The PROM_FILENAME and KERNEL_* defines are used by mac_oldworld and mac_newworld but they don't have to be identical so these could be moved to the individual boards. Signed-off-by: BALATON Zoltan Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Mark Cave-Ayland --- hw/ppc/mac.h | 4

[PATCH v6 18/19] mac_newworld: Document deprecation

2022-10-28 Thread BALATON Zoltan
Also update PowerMac family docs with some more recent info. Signed-off-by: BALATON Zoltan --- docs/about/deprecated.rst| 7 +++ docs/system/ppc/powermac.rst | 12 2 files changed, 15 insertions(+), 4 deletions(-) diff --git a/docs/about/deprecated.rst b/docs/about/depreca

  1   2   3   4   >