Re: [PATCH v2 2/2] vhost-scsi: Add support for a worker thread per virtqueue

2023-11-29 Thread Stefano Garzarella
On Sun, Nov 26, 2023 at 06:28:34PM -0600, Mike Christie wrote: This adds support for vhost-scsi to be able to create a worker thread per virtqueue. Right now for vhost-net we get a worker thread per tx/rx virtqueue pair which scales nicely as we add more virtqueues and CPUs, but for scsi we get t

Re: [PATCH v3 2/2] vhost-scsi: Add support for a worker thread per virtqueue

2023-12-05 Thread Stefano Garzarella
ate a worker per IO virtqueue. Signed-off-by: Mike Christie Reviewed-by: Stefan Hajnoczi --- hw/scsi/vhost-scsi.c| 62 + include/hw/virtio/virtio-scsi.h | 1 + 2 files changed, 63 insertions(+) Thank for adding the warning! LGTM! Reviewed-by: St

Re: [PATCH] vhost-user: Fix protocol feature bit conflict

2023-10-16 Thread Stefano Garzarella
ixinig this! Reviewed-by: Stefano Garzarella diff --git a/docs/interop/vhost-user.rst b/docs/interop/vhost-user.rst index 415bb47a19..768fb5c28c 100644 --- a/docs/interop/vhost-user.rst +++ b/docs/interop/vhost-user.rst @@ -275,6 +275,16 @@ Inflight description :queue size: a 16-bit size of vir

Re: [PATCH 2/2] vhost-scsi: Add support for a worker thread per virtqueue

2023-11-15 Thread Stefano Garzarella
On Mon, Nov 13, 2023 at 06:36:44PM -0600, Mike Christie wrote: This adds support for vhost-scsi to be able to create a worker thread per virtqueue. Right now for vhost-net we get a worker thread per tx/rx virtqueue pair which scales nicely as we add more virtqueues and CPUs, but for scsi we get t

Re: [PATCH 1/7] vhost-user: strip superfluous whitespace

2023-08-30 Thread Stefano Garzarella
On Sun, Aug 27, 2023 at 08:29:31PM +0200, Laszlo Ersek wrote: Cc: "Michael S. Tsirkin" (supporter:vhost) Cc: Eugenio Perez Martin Cc: German Maglione Cc: Liu Jiang Cc: Sergio Lopez Pascual Cc: Stefano Garzarella Signed-off-by: Laszlo Ersek --- hw/virtio/vhost-user.c | 2 +- 1 fi

Re: [PATCH 2/7] vhost-user: tighten "reply_supported" scope in "set_vring_addr"

2023-08-30 Thread Stefano Garzarella
ot; to the minimum. This is purely refactoring -- no observable change. Cc: "Michael S. Tsirkin" (supporter:vhost) Cc: Eugenio Perez Martin Cc: German Maglione Cc: Liu Jiang Cc: Sergio Lopez Pascual Cc: Stefano Garzarella Signed-off-by: Laszlo Ersek --- hw/virtio/vhost-user.c | 11 +

Re: [PATCH 3/7] vhost-user: factor out "vhost_user_write_msg"

2023-08-30 Thread Stefano Garzarella
y refactoring -- no observable change. Cc: "Michael S. Tsirkin" (supporter:vhost) Cc: Eugenio Perez Martin Cc: German Maglione Cc: Liu Jiang Cc: Sergio Lopez Pascual Cc: Stefano Garzarella Signed-off-by: Laszlo Ersek --- hw/virtio/vhost-user.c | 66 +--- 1 file

Re: [PATCH 5/7] vhost-user: hoist "write_msg", "get_features", "get_u64"

2023-08-30 Thread Stefano Garzarella
uot;vhost_set_vring". This is purely code movement -- no observable change. Cc: "Michael S. Tsirkin" (supporter:vhost) Cc: Eugenio Perez Martin Cc: German Maglione Cc: Liu Jiang Cc: Sergio Lopez Pascual Cc: Stefano Garzarella Signed-off-by: Laszlo Ersek --- hw/virtio/vhost-user

Re: [PATCH 4/7] vhost-user: flatten "enforce_reply" into "vhost_user_write_msg"

2023-08-30 Thread Stefano Garzarella
genio Perez Martin Cc: German Maglione Cc: Liu Jiang Cc: Sergio Lopez Pascual Cc: Stefano Garzarella Signed-off-by: Laszlo Ersek --- hw/virtio/vhost-user.c | 32 1 file changed, 13 insertions(+), 19 deletions(-) Reviewed-by: Stefano Garzarella

Re: [PATCH 6/7] vhost-user: allow "vhost_set_vring" to wait for a reply

2023-08-30 Thread Stefano Garzarella
ng" are hard-coded within "vhost_user_write_msg". Cc: "Michael S. Tsirkin" (supporter:vhost) Cc: Eugenio Perez Martin Cc: German Maglione Cc: Liu Jiang Cc: Sergio Lopez Pascual Cc: Stefano Garzarella Signed-off-by: Laszlo Ersek --- hw/virtio/vhost-user.c | 11 ++- 1 file changed, 6 insertions(+), 5 deletions(-) Reviewed-by: Stefano Garzarella

Re: [PATCH 7/7] vhost-user: call VHOST_USER_SET_VRING_ENABLE synchronously

2023-08-30 Thread Stefano Garzarella
ACK vhost-user feature has been negotiated, or - performing a separate VHOST_USER_GET_FEATURES *exchange*, which requires a backend response regardless of VHOST_USER_PROTOCOL_F_REPLY_ACK. Thanks for the excellent analysis (and fix of course!). Cc: "Michael S. Tsirkin" (supporter:vhost) Cc: Eugenio Perez Mart

Re: [PATCH 0/7] vhost-user: call VHOST_USER_SET_VRING_ENABLE synchronously

2023-08-30 Thread Stefano Garzarella
On Sun, Aug 27, 2023 at 08:29:30PM +0200, Laszlo Ersek wrote: The last patch in the series states and fixes the problem; prior patches only refactor the code. Thanks for the fix and great cleanup! I fully reviewed the series and LGTM. An additional step that we can take (not in this series) c

Re: [PATCH 7/7] vhost-user: call VHOST_USER_SET_VRING_ENABLE synchronously

2023-08-30 Thread Stefano Garzarella
On Wed, Aug 30, 2023 at 11:26:41AM +0200, Laszlo Ersek wrote: On 8/30/23 10:39, Stefano Garzarella wrote: On Sun, Aug 27, 2023 at 08:29:37PM +0200, Laszlo Ersek wrote: (1) The virtio-1.0 specification <http://docs.oasis-open.org/virtio/virtio/v1.0/virtio-v1.0.html> writes: What

Re: Switching to the GitLab bug tracker

2021-05-05 Thread Stefano Garzarella
On Tue, May 04, 2021 at 12:20:03PM +0200, Philippe Mathieu-Daudé wrote: On 5/4/21 10:43 AM, Stefan Hajnoczi wrote: On Mon, May 03, 2021 at 01:16:51PM +0200, Thomas Huth wrote: As you might have already noticed by some other mails on the qemu-devel mailing list, we are in progress of switching o

Re: Switching to the GitLab bug tracker

2021-05-05 Thread Stefano Garzarella
On Wed, May 05, 2021 at 11:58:45AM +0200, Thomas Huth wrote: On 05/05/2021 11.55, Stefano Garzarella wrote: On Tue, May 04, 2021 at 12:20:03PM +0200, Philippe Mathieu-Daudé wrote: On 5/4/21 10:43 AM, Stefan Hajnoczi wrote: On Mon, May 03, 2021 at 01:16:51PM +0200, Thomas Huth wrote: As you

Re: [PATCH] cutils: fix memory leak in get_relocated_path()

2021-05-10 Thread Stefano Garzarella
Ping :-) Should I resend for 6.1? Thanks Stefano On Mon, Apr 12, 2021 at 07:02:55PM +0200, Stefano Garzarella wrote: get_relocated_path() allocates a GString object and returns the character data (C string) to the caller without freeing the memory allocated for that object as reported by

Re: [PATCH 0/3] hw/virtio: Constify VirtIOFeature

2021-05-12 Thread Stefano Garzarella
feature_sizes[] virtio-net: Constify VirtIOFeature feature_sizes[] include/hw/virtio/virtio.h | 2 +- hw/block/virtio-blk.c | 2 +- hw/net/virtio-net.c| 2 +- hw/virtio/virtio.c | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) Reviewed-by: Stefano Garzarella

[Qemu-devel] [PATCH] net: flush NetQueue before to send new packets

2016-07-19 Thread Stefano Garzarella
qemu_net_queue_send() and qemu_net_queue_send_iov() can flush enqueued packets before delivering a new packet, in this way the original packet ordering is preserved. Signed-off-by: Stefano Garzarella --- net/queue.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/net

[Qemu-devel] [PATCH] net: flush NetQueue before to send new packets

2016-07-19 Thread Stefano Garzarella
qemu_net_queue_send() and qemu_net_queue_send_iov() can flush enqueued packets before delivering a new packet, in this way the original packet ordering is preserved. Signed-off-by: Stefano Garzarella --- net/queue.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/net

Re: [Qemu-devel] QEMU/NEMU boot time with several x86 firmwares

2018-12-03 Thread Stefano Garzarella
On Mon, Dec 3, 2018 at 4:44 PM Rob Bradford wrote: > > Hi Stefano, thanks for capturing all these numbers, > > On Mon, 2018-12-03 at 15:27 +0100, Stefano Garzarella wrote: > > Hi Rob, > > I continued to investigate the boot time, and as you suggested I > > l

Re: [Qemu-devel] QEMU/NEMU boot time with several x86 firmwares

2018-12-05 Thread Stefano Garzarella
On Tue, Dec 4, 2018 at 11:45 PM Maran Wilson wrote: > > On 12/3/2018 8:35 AM, Stefano Garzarella wrote: > > On Mon, Dec 3, 2018 at 4:44 PM Rob Bradford > > wrote: > >> Hi Stefano, thanks for capturing all these numbers, > >> > >> On Mon, 2018-1

Re: [Qemu-devel] QEMU/NEMU boot time with several x86 firmwares

2018-12-05 Thread Stefano Garzarella
Hi Philippe, On Wed, Dec 5, 2018 at 1:26 PM Philippe Mathieu-Daudé wrote: > > Hi Stefano, > > On 3/12/18 17:35, Stefano Garzarella wrote: > > On Mon, Dec 3, 2018 at 4:44 PM Rob Bradford > > wrote: > >> > >> Hi Stefano, thanks for capturing all these n

Re: [Qemu-devel] QEMU/NEMU boot time with several x86 firmwares

2018-12-10 Thread Stefano Garzarella
Hi Maran, On Wed, Dec 5, 2018 at 7:04 PM Maran Wilson wrote: > > On 12/5/2018 5:20 AM, Stefan Hajnoczi wrote: > > On Tue, Dec 04, 2018 at 02:44:33PM -0800, Maran Wilson wrote: > >> On 12/3/2018 8:35 AM, Stefano Garzarella wrote: > >>> On Mon, Dec 3, 2018 at 4

Re: [Qemu-devel] [RFC 3/3] pvh: Boot uncompressed kernel using direct boot ABI

2018-12-11 Thread Stefano Garzarella
->device_memory->mr); > + > +fw_cfg_add_bytes(fw_cfg, FW_CFG_KERNEL_DATA, &ramdisk_mod, > + sizeof(ramdisk_mod)); > + fw_cfg_add_i32(fw_cfg, FW_CFG_SETUP_SIZE, sizeof(header)); > +fw_cfg_add_bytes(fw_cfg, FW_CFG_SETUP_DATA, > + header, sizeof(header)); > + > +return; > +} > +} > /* This looks like a multiboot kernel. If it is, let's stop > treating it like a Linux kernel. */ > if (load_multiboot(fw_cfg, f, kernel_filename, initrd_filename, > -- > 1.8.3.1 > -- Stefano Garzarella Red Hat

Re: [Qemu-devel] [RFC 3/3] pvh: Boot uncompressed kernel using direct boot ABI

2018-12-12 Thread Stefano Garzarella
On Tue, Dec 11, 2018 at 7:35 PM Maran Wilson wrote: > > On 12/11/2018 9:11 AM, Stefano Garzarella wrote: > > Hi Liam, > > in order to support PVH also with SeaBIOS, I'm going to work on a new > > option rom (like linuxboot/multiboot) that can be used in this case. >

Re: [Qemu-devel] QEMU/NEMU boot time with several x86 firmwares

2018-12-13 Thread Stefano Garzarella
ation. Thanks, Stefano On Mon, Dec 3, 2018 at 3:27 PM Stefano Garzarella wrote: > > Hi Rob, > I continued to investigate the boot time, and as you suggested I > looked also at qemu-lite 2.11.2 > (https://github.com/kata-containers/qemu) and NEMU "virt" machine. I > did

[Qemu-devel] SeaBIOS booting time optimization

2018-11-16 Thread Stefano Garzarella
d the same tests also with NEMU (without using -M virt) and I have approximately the same results. As the next step, I'll start from Kevin's configuration to have a minimal SeaBIOS image ables to boot a Linux kernel. Thanks, Stefano -- Stefano Garzarella Red Hat

Re: [Qemu-devel] SeaBIOS booting time optimization

2018-11-19 Thread Stefano Garzarella
Hi Samuel, On Mon, Nov 19, 2018 at 12:31 AM Samuel Ortiz wrote: > Hi Stefano, > > On Fri, Nov 16, 2018 at 05:13:59PM +0100, Stefano Garzarella wrote: > > Hi, > > I'm investigating the SeaBIOS booting time, to understand if we can > reduce > > the boot time in

Re: [Qemu-devel] SeaBIOS booting time optimization

2018-11-19 Thread Stefano Garzarella
gt; > Any pointers or suggestions would be helpful. > > seabios could try to skip initializing hardware without bootindex with > "qemu -boot menu=off,strict=on". > > mmconfig support? I think that would reduce the number of vmexits > needed for pci initialization. > Thank you very much, I'll investigate that points. Cheers, Stefano > cheers, > Gerd > > -- Stefano Garzarella Red Hat

Re: [Qemu-devel] SeaBIOS booting time optimization

2018-11-19 Thread Stefano Garzarella
On Mon, Nov 19, 2018 at 3:15 PM Gerd Hoffmann wrote: > On Mon, Nov 19, 2018 at 01:07:13PM +, Stefan Hajnoczi wrote: > > On Mon, Nov 19, 2018 at 11:42:28AM +0100, Stefano Garzarella wrote: > > > On Mon, Nov 19, 2018 at 9:49 AM Gerd Hoffmann > wrote: > > > > &

Re: [Qemu-devel] SeaBIOS booting time optimization

2018-11-20 Thread Stefano Garzarella
ts which are > required to work properly on physical hardware. But typically virtual > hardware is alot faster. There is -- for example -- no time needed to > establish a sata link. Link detection in ahci is instant on qemu. I'll investigate also other timeouts. Thanks, Stefano > > cheers, > Gerd > -- Stefano Garzarella Red Hat

Re: [Qemu-devel] [SeaBIOS] SeaBIOS booting time optimization

2018-11-20 Thread Stefano Garzarella
On Tue, Nov 20, 2018 at 5:13 PM Steve Douthit wrote: > > On 11/20/18 10:55 AM, Kevin O'Connor wrote: > > On Mon, Nov 19, 2018 at 07:38:39PM +0100, Stefano Garzarella wrote: > >> just an update, I enabled the debug prints and I saw two timeouts fired > >> w

Re: [Qemu-devel] [PATCH] machine: fix a typo

2018-10-10 Thread Stefano Garzarella
Reviewed-by: Stefano Garzarella Il giorno mer 10 ott 2018 alle ore 18:11 Li Qiang ha scritto: > Cc: qemu-triv...@nongnu.org > Signed-off-by: Li Qiang > --- > hw/core/machine.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/hw/core/machine.

Re: [Qemu-devel] SeaBIOS booting time optimization

2018-11-22 Thread Stefano Garzarella
l HW support except SMM & MTRRs, CONFIG_DISABLE_VGA=y) + Stephen's TPM patch qemu_init_end: 42.968648 fw_start: 43.154598 (+0.185950) fw_do_boot: 55.808438 (+12.653840) linux_start_boot: 57.170154 (+1.361716) linux_start_user: 529.189856 (+472.019702) Disable VGA patch: From: S

Re: [Qemu-devel] SeaBIOS booting time optimization

2018-11-22 Thread Stefano Garzarella
On Thu, Nov 22, 2018 at 12:51 PM Gerd Hoffmann wrote: > > On Thu, Nov 22, 2018 at 12:08:55PM +0100, Stefano Garzarella wrote: > > Hi, > > I continued to investigate how to reduce the boot time with SeaBIOS > > and QEMU when it used with linuxboot_dma.bin (-kernel paramet

Re: [Qemu-devel] SeaBIOS booting time optimization

2018-11-23 Thread Stefano Garzarella
On Fri, Nov 23, 2018 at 7:21 AM Gerd Hoffmann wrote: > > On Thu, Nov 22, 2018 at 04:13:38PM +0100, Stefano Garzarella wrote: > > On Thu, Nov 22, 2018 at 12:51 PM Gerd Hoffmann wrote: > > > > > > On Thu, Nov 22, 2018 at 12:08:55PM +0100, Stefano Garzarella wrote: &

Re: [Qemu-devel] SeaBIOS booting time optimization

2018-11-23 Thread Stefano Garzarella
On Fri, Nov 23, 2018 at 4:54 PM Kevin O'Connor wrote: > > On Fri, Nov 23, 2018 at 12:18:13PM +0100, Stefano Garzarella wrote: > > On Fri, Nov 23, 2018 at 7:21 AM Gerd Hoffmann wrote: > > > On Thu, Nov 22, 2018 at 04:13:38PM +0100, Stefano Garzarella wrote: > > &

[Qemu-devel] QEMU/NEMU boot time with several x86 firmwares

2018-11-26 Thread Stefano Garzarella
nable the times that I measured? Do you use a different configuration? Thanks, Stefano -- Stefano Garzarella Red Hat

Re: [Qemu-devel] QEMU/NEMU boot time with several x86 firmwares

2018-11-27 Thread Stefano Garzarella
Hi Rob, On Tue, Nov 27, 2018 at 10:57 AM Rob Bradford wrote: > > Hi Stefano, > > On Mon, 2018-11-26 at 17:40 +0100, Stefano Garzarella wrote: > > Hi Samuel, Rob, > > I'm proceeding to compare several x86 firmwares in order to > > understand > > which s

Re: [Qemu-devel] [PATCH] hostmem: Validate host-nodes before setting bitmap

2018-11-30 Thread Stefano Garzarella
; +self.assertEquals(stdout, b'') > +self.assertEquals(p.returncode, 1) > + > +def test_valid_host_nodes(self): > +p = Popen([self.qemu_bin, '-display', 'none', '-nodefaults', > + '-object', 'memory-backend-ram,id=m0,' > + 'size=4096,host-nodes=%d' % (MAX_NODES - 1)], > + stderr=PIPE, stdout=PIPE) > +stdout,stderr = p.communicate() > + > +self.assertIn(b'host-nodes must be empty', stderr) > +self.assertEquals(p.returncode, 1) > -- > 2.18.0.rc1.1.g3f1ff2140 > > -- Stefano Garzarella Red Hat

Re: [Qemu-devel] [PATCH v2] hostmem: Validate host-nodes before setting bitmap

2018-11-30 Thread Stefano Garzarella
fix. > > While at it, fix memory leak of the list returned by > visit_type_uint16List(). > > Reported-by: Markus Armbruster > Signed-off-by: Eduardo Habkost > --- > Changes v1 -> v2: > * Remove extra `l = l->next` statement > (reported by Stefano Garzarella)

Re: [Qemu-devel] QEMU/NEMU boot time with several x86 firmwares

2018-12-03 Thread Stefano Garzarella
efano On Tue, Nov 27, 2018 at 3:21 PM Stefano Garzarella wrote: > > Hi Rob, > > On Tue, Nov 27, 2018 at 10:57 AM Rob Bradford > wrote: > > > > Hi Stefano, > > > > On Mon, 2018-11-26 at 17:40 +0100, Stefano Garzarella wrote: > > > Hi Samuel, Rob,

Re: [Qemu-devel] [PATCH v3 05/16] virtio: split virtio balloon bits from virtio-pci

2018-12-20 Thread Stefano Garzarella
hw/virtio/virtio-pci.c | 58 - > hw/virtio/virtio-pci.h | 14 - > tests/Makefile.include | 2 +- > 5 files changed, 96 insertions(+), 73 deletions(-) > create mode 100644 hw/virtio/virtio-balloon-pci.c Reviewed-by: Stefano Garzarella

Re: [Qemu-devel] [PATCH v5 3/4] i386: import & use bootparam.h

2019-01-11 Thread Stefano Garzarella
tput/include/standard-headers/asm-$arch" > +# Remove everything except the macros from bootparam.h avoiding the > +# unnecessary import of several video/ist/etc headers > +sed -e '/__ASSEMBLY__/,/__ASSEMBLY__/d' > $tmpdir/include/asm/bootparam.h > $tmpdir/bootparam.h > +cp_portable $tmpdir/bootparam.h > "$output/include/standard-headers/asm-$arch" Maybe you miss my comment. Anyway, IMHO is better to use the double quotes for all paths. Reviewed-by: Stefano Garzarella > fi > done > > -- > 2.7.4 > > -- Stefano Garzarella Red Hat

[Qemu-devel] [PATCH 4/4] hw/i386/pc: use PVH option rom

2019-01-11 Thread Stefano Garzarella
Use pvh.bin option rom when we are booting an uncompressed kernel using the x86/HVM direct boot ABI. Signed-off-by: Stefano Garzarella Based-on: <1545422632-2-5-git-send-email-liam.merw...@oracle.com> --- hw/i386/pc.c | 4 1 file changed, 4 insertions(+) diff --git a/hw/i386/pc.

[Qemu-devel] [PATCH 0/4] pvh: add new PVH option rom

2019-01-11 Thread Stefano Garzarella
. Patch 3 adds the new PVH option rom and patch 4 uses it when we are booting an uncompressed kernel using the x86/HVM direct boot ABI. Stefano Garzarella (4): linuxboot_dma: remove duplicate definitions of FW_CFG linuxboot_dma: move common functions in a new header optionrom: add new PVH

[Qemu-devel] [PATCH 1/4] linuxboot_dma: remove duplicate definitions of FW_CFG

2019-01-11 Thread Stefano Garzarella
FW_CFG_DMA_CTL_* bits and struct fw_cfg_dma_access are defined in the qemu_fw_cfg.h header file already included in linuxboot_dma.c, so we can remove the definition of BIOS_CFG_DMA_CTL_* and struct FWCfgDmaAccess. Signed-off-by: Stefano Garzarella --- pc-bios/optionrom/linuxboot_dma.c | 20

[Qemu-devel] [PATCH 2/4] linuxboot_dma: move common functions in a new header

2019-01-11 Thread Stefano Garzarella
In order to allow other option roms to use these common useful functions and definitions, this patch put them in a new C header file called optrom.h, and also add useful out*() in*() functions for different size. Signed-off-by: Stefano Garzarella --- pc-bios/optionrom/linuxboot_dma.c | 98

[Qemu-devel] [PATCH 3/4] optionrom: add new PVH option rom

2019-01-11 Thread Stefano Garzarella
pvh_load_kernel() written in pvh_main.c. pvh_load_kernel() loads the cmdline and kernel entry_point using fw_cfg, then it looks for RSDP, fills the hvm_start_info required by x86/HVM ABI, and finally jumps to the kernel entry_point. Signed-off-by: Stefano Garzarella --- pc-bios/optionrom/Makefile | 5

Re: [Qemu-devel] [PATCH 2/4] linuxboot_dma: move common functions in a new header

2019-01-11 Thread Stefano Garzarella
On Fri, Jan 11, 2019 at 5:27 PM Stefan Hajnoczi wrote: > > On Fri, Jan 11, 2019 at 02:18:34PM +0100, Stefano Garzarella wrote: > > In order to allow other option roms to use these common > > useful functions and definitions, this patch put them > > in a new C header file c

Re: [Qemu-devel] [PATCH 2/4] linuxboot_dma: move common functions in a new header

2019-01-12 Thread Stefano Garzarella
On Fri, Jan 11, 2019 at 6:55 PM Eric Blake wrote: > > On 1/11/19 11:48 AM, Michael S. Tsirkin wrote: > > >>> > diff --git a/pc-bios/optionrom/optrom.h b/pc-bios/optionrom/optrom.h > new file mode 100644 > index 00..36f43b43fd > --- /dev/null > +++ b/pc-bios/optionr

Re: [Qemu-devel] [PATCH 2/4] linuxboot_dma: move common functions in a new header

2019-01-12 Thread Stefano Garzarella
On Fri, Jan 11, 2019 at 6:48 PM Michael S. Tsirkin wrote: > > > > +#include "../../include/standard-headers/linux/qemu_fw_cfg.h" > > > > > > This depends on , please include it first. > > Better to just pull in qemu/osdep.h This header is used in the option roms that are bare-metal, so IMHO I can

Re: [Qemu-devel] [PATCH 4/4] hw/i386/pc: use PVH option rom

2019-01-14 Thread Stefano Garzarella
On Fri, Jan 11, 2019 at 5:34 PM Stefan Hajnoczi wrote: > > On Fri, Jan 11, 2019 at 02:18:36PM +0100, Stefano Garzarella wrote: > > Use pvh.bin option rom when we are booting an uncompressed > > kernel using the x86/HVM direct boot ABI. > > > > Signed-off-by: St

[Qemu-devel] [PATCH v2 0/4] pvh: add new PVH option rom

2019-01-15 Thread Stefano Garzarella
pvh.bin in xen_load_linux() - modified commit message of patch 2 to explain better the patch Stefano Garzarella (4): linuxboot_dma: remove duplicate definitions of FW_CFG linuxboot_dma: move common functions in a new header optionrom: add new PVH option rom hw/i386/pc: use PVH option rom

[Qemu-devel] [PATCH v2 3/4] optionrom: add new PVH option rom

2019-01-15 Thread Stefano Garzarella
pvh_load_kernel() written in pvh_main.c. pvh_load_kernel() loads the cmdline and kernel entry_point using fw_cfg, then it looks for RSDP, fills the hvm_start_info required by x86/HVM ABI, and finally jumps to the kernel entry_point. Signed-off-by: Stefano Garzarella Reviewed-by: Stefan Hajnoczi --- pc-bios

[Qemu-devel] [PATCH v2 2/4] linuxboot_dma: move common functions in a new header

2019-01-15 Thread Stefano Garzarella
available. Signed-off-by: Stefano Garzarella --- pc-bios/optionrom/linuxboot_dma.c | 100 +-- pc-bios/optionrom/optrom.h| 110 ++ pc-bios/optionrom/optrom_fw_cfg.h | 92 + 3 files changed, 218 insertions(+), 84

[Qemu-devel] [PATCH v2 4/4] hw/i386/pc: use PVH option rom

2019-01-15 Thread Stefano Garzarella
Use pvh.bin option rom when we are booting an uncompressed kernel using the x86/HVM direct boot ABI. Signed-off-by: Stefano Garzarella Based-on: <1545422632-2-5-git-send-email-liam.merw...@oracle.com> --- hw/i386/pc.c | 5 + 1 file changed, 5 insertions(+) diff --git a/hw/i386/

[Qemu-devel] [PATCH v2 1/4] linuxboot_dma: remove duplicate definitions of FW_CFG

2019-01-15 Thread Stefano Garzarella
FW_CFG_DMA_CTL_* bits and struct fw_cfg_dma_access are defined in the qemu_fw_cfg.h header file already included in linuxboot_dma.c, so we can remove the definition of BIOS_CFG_DMA_CTL_* and struct FWCfgDmaAccess. Signed-off-by: Stefano Garzarella Reviewed-by: Stefan Hajnoczi --- pc-bios

Re: [Qemu-devel] [PATCH v2 4/4] hw/i386/pc: use PVH option rom

2019-01-16 Thread Stefano Garzarella
Hi Michael, On Tue, Jan 15, 2019 at 03:05:27PM -0500, Michael S. Tsirkin wrote: > On Tue, Jan 15, 2019 at 01:12:21PM -0600, Eric Blake wrote: > > On 1/15/19 12:57 PM, Michael S. Tsirkin wrote: > > > On Tue, Jan 15, 2019 at 11:00:58AM +0100, Stefano Garzarella wrote: > > &

Re: [Qemu-devel] [PATCH v2 4/4] hw/i386/pc: use PVH option rom

2019-01-16 Thread Stefano Garzarella
Hi Eric, On Tue, Jan 15, 2019 at 01:12:21PM -0600, Eric Blake wrote: > On 1/15/19 12:57 PM, Michael S. Tsirkin wrote: > > On Tue, Jan 15, 2019 at 11:00:58AM +0100, Stefano Garzarella wrote: > >> Use pvh.bin option rom when we are booting an uncompressed > >> kernel us

Re: [Qemu-devel] [PATCH v2 3/4] optionrom: add new PVH option rom

2019-01-16 Thread Stefano Garzarella
Hi Liam, On Wed, Jan 16, 2019 at 10:16:04AM +, Liam Merwick wrote: > Hi Stefano, > > Code LGTM, just a few minor comments below > > On 15/01/2019 10:00, Stefano Garzarella wrote: > > The new pvh.bin option rom can be used with SeaBIOS to boot > > uncompressed kern

Re: [Qemu-devel] [PATCH V9 5/6] hostmem: add more information in error messages

2019-01-16 Thread Stefano Garzarella
ang Yi > Reviewed-by: Eduardo Habkost > --- > backends/hostmem-file.c | 6 -- > backends/hostmem.c | 8 +--- > 2 files changed, 9 insertions(+), 5 deletions(-) > Reviewed-by: Stefano Garzarella

Re: [Qemu-devel] [PATCH qemu 1/2] update-linux-headers.sh: Copy new headers

2019-01-16 Thread Stefano Garzarella
rdashevskiy > --- > scripts/update-linux-headers.sh | 11 ++- > 1 file changed, 10 insertions(+), 1 deletion(-) > Reviewed-by: Stefano Garzarella

[Qemu-devel] [PATCH v3 1/5] linuxboot_dma: remove duplicate definitions of FW_CFG

2019-01-16 Thread Stefano Garzarella
FW_CFG_DMA_CTL_* bits and struct fw_cfg_dma_access are defined in the qemu_fw_cfg.h header file already included in linuxboot_dma.c, so we can remove the definition of BIOS_CFG_DMA_CTL_* and struct FWCfgDmaAccess. Signed-off-by: Stefano Garzarella Reviewed-by: Stefan Hajnoczi Reviewed-by: Liam

[Qemu-devel] [PATCH v3 0/5] pvh: add new PVH option rom

2019-01-16 Thread Stefano Garzarella
d inludes on top of linuxboot_dma.c and add in optrom.h - Patch 4: added check of pvh.bin in xen_load_linux() - modified commit message of patch 2 to explain better the patch Stefano Garzarella (5): linuxboot_dma: remove duplicate definitions of FW_CFG linuxboot_dma: move common functions

[Qemu-devel] [PATCH v3 5/5] optionrom/pvh: load initrd from fw_cfg

2019-01-16 Thread Stefano Garzarella
If we found initrd through fw_cfg, we can load it and use the first module of hvm_start_info to pass initrd address and size to the kernel. Signed-off-by: Stefano Garzarella --- pc-bios/optionrom/pvh_main.c | 21 +++-- pc-bios/pvh.bin | Bin 1536 -> 1536 bytes

[Qemu-devel] [PATCH v3 2/5] linuxboot_dma: move common functions in a new header

2019-01-16 Thread Stefano Garzarella
available. Signed-off-by: Stefano Garzarella Reviewed-by: Stefan Hajnoczi Reviewed-by: Liam Merwick --- pc-bios/optionrom/linuxboot_dma.c | 100 +-- pc-bios/optionrom/optrom.h| 110 ++ pc-bios/optionrom/optrom_fw_cfg.h | 92

[Qemu-devel] [PATCH v3 4/5] hw/i386/pc: use PVH option rom

2019-01-16 Thread Stefano Garzarella
Use pvh.bin option rom when we are booting an uncompressed kernel using the x86/HVM direct boot ABI. Signed-off-by: Stefano Garzarella Reviewed-by: Stefan Hajnoczi Reviewed-by: Liam Merwick --- hw/i386/pc.c | 5 + 1 file changed, 5 insertions(+) diff --git a/hw/i386/pc.c b/hw/i386/pc.c

[Qemu-devel] [PATCH v3 3/5] optionrom: add new PVH option rom

2019-01-16 Thread Stefano Garzarella
pvh_load_kernel() written in pvh_main.c. pvh_load_kernel() loads the cmdline and kernel entry_point using fw_cfg, then it looks for RSDP, fills the hvm_start_info required by x86/HVM ABI, and finally jumps to the kernel entry_point. Signed-off-by: Stefano Garzarella Reviewed-by: Stefan Hajnoczi Reviewed

Re: [Qemu-devel] [PATCH v3 0/5] pvh: add new PVH option rom

2019-01-17 Thread Stefano Garzarella
Hi Paolo, On Wed, Jan 16, 2019 at 10:17:15PM +0100, Paolo Bonzini wrote: > On 16/01/19 19:31, Paolo Bonzini wrote: > > > > I get this: > > > > CC optionrom/pvh_main.o > > /tmp/ccoel69H.s: Assembler messages: > > /tmp/ccoel69H.s:171: Error: attempt to move .org backwards > > > > when appl

[Qemu-devel] [PATCH v4 1/5] linuxboot_dma: remove duplicate definitions of FW_CFG

2019-01-17 Thread Stefano Garzarella
FW_CFG_DMA_CTL_* bits and struct fw_cfg_dma_access are defined in the qemu_fw_cfg.h header file already included in linuxboot_dma.c, so we can remove the definition of BIOS_CFG_DMA_CTL_* and struct FWCfgDmaAccess. Signed-off-by: Stefano Garzarella Reviewed-by: Stefan Hajnoczi Reviewed-by: Liam

[Qemu-devel] [PATCH v4 0/5] pvh: add new PVH option rom

2019-01-17 Thread Stefano Garzarella
bin in xen_load_linux() - modified commit message of patch 2 to explain better the patch Stefano Garzarella (5): linuxboot_dma: remove duplicate definitions of FW_CFG linuxboot_dma: move common functions in a new header optionrom: add new PVH option rom hw/i386/pc: use PVH option rom optionrom/

[Qemu-devel] [PATCH v4 4/5] hw/i386/pc: use PVH option rom

2019-01-17 Thread Stefano Garzarella
Use pvh.bin option rom when we are booting an uncompressed kernel using the x86/HVM direct boot ABI. Signed-off-by: Stefano Garzarella Reviewed-by: Stefan Hajnoczi Reviewed-by: Liam Merwick --- hw/i386/pc.c | 5 + 1 file changed, 5 insertions(+) diff --git a/hw/i386/pc.c b/hw/i386/pc.c

[Qemu-devel] [PATCH v4 2/5] linuxboot_dma: move common functions in a new header

2019-01-17 Thread Stefano Garzarella
available. Signed-off-by: Stefano Garzarella Reviewed-by: Stefan Hajnoczi Reviewed-by: Liam Merwick --- pc-bios/optionrom/linuxboot_dma.c | 102 ++- pc-bios/optionrom/optrom.h| 110 ++ pc-bios/optionrom/optrom_fw_cfg.h | 92

[Qemu-devel] [PATCH v4 3/5] optionrom: add new PVH option rom

2019-01-17 Thread Stefano Garzarella
pvh_load_kernel() written in pvh_main.c. pvh_load_kernel() loads the cmdline and kernel entry_point using fw_cfg, then it looks for RSDP, fills the hvm_start_info required by x86/HVM ABI, and finally jumps to the kernel entry_point. Signed-off-by: Stefano Garzarella Reviewed-by: Stefan Hajnoczi Reviewed

[Qemu-devel] [PATCH v4 5/5] optionrom/pvh: load initrd from fw_cfg

2019-01-17 Thread Stefano Garzarella
If we found initrd through fw_cfg, we can load it and use the first module of hvm_start_info to pass initrd address and size to the kernel. Signed-off-by: Stefano Garzarella --- pc-bios/optionrom/pvh_main.c | 21 +++-- pc-bios/pvh.bin | Bin 1536 -> 1536 bytes

Re: [Qemu-devel] [PATCH v3 0/5] pvh: add new PVH option rom

2019-01-17 Thread Stefano Garzarella
On Thu, Jan 17, 2019 at 11:31:27AM +0100, Paolo Bonzini wrote: > On 17/01/19 08:50, Stefano Garzarella wrote: > >> Also, the $? in the new rule should be $^. I wouldn't use a pattern > >> rule for that, writing it explicitly as "pvh.img: pvh.S pvh_main.c"

Re: [Qemu-devel] [PATCH v2 2/3] contrib/vhost-user-blk: fix the compilation issue

2019-01-17 Thread Stefano Garzarella
Note: I removed my wrong e-mail address in CC. On Wed, Jan 16, 2019 at 01:19:29PM +0800, Changpeng Liu wrote: > Signed-off-by: Changpeng Liu > --- > contrib/vhost-user-blk/vhost-user-blk.c | 6 +- > 1 file changed, 5 insertions(+), 1 deletion(-) > Reviewed-by: Stefano Garzarella

Re: [Qemu-devel] [PATCH v2 1/3] contrib: compile vhost-user-blk tool by default

2019-01-17 Thread Stefano Garzarella
Note: I removed my wrong e-mail address in CC. On Wed, Jan 16, 2019 at 01:19:28PM +0800, Changpeng Liu wrote: > Signed-off-by: Changpeng Liu > --- > configure | 3 +++ > 1 file changed, 3 insertions(+) > Reviewed-by: Stefano Garzarella

Re: [Qemu-devel] [PATCH v3] vhost-user-blk: add discard/write zeroes features support

2019-01-17 Thread Stefano Garzarella
4 + > include/standard-headers/linux/virtio_blk.h | 54 +++ > 3 files changed, 159 insertions(+), 33 deletions(-) > Reviewed-by: Stefano Garzarella

Re: [Qemu-devel] [PATCH] exec.c: Use correct attrs in cpu_memory_rw_debug()

2019-01-17 Thread Stefano Garzarella
ays performed as if non-secure, rather than > using the right security state for the CPU's current state. > > Fixes: https://bugs.launchpad.net/qemu/+bug/1812091 > > Signed-off-by: Peter Maydell > --- > exec.c | 6 ++ > 1 file changed, 2 insertions(+), 4 deletions(-) > Reviewed-by: Stefano Garzarella

Re: [Qemu-devel] [PATCH v4 5/5] optionrom/pvh: load initrd from fw_cfg

2019-01-17 Thread Stefano Garzarella
On Thu, Jan 17, 2019 at 03:37:24PM +0100, Paolo Bonzini wrote: > On 17/01/19 15:33, Liam Merwick wrote: > > #    pc-bios/optionrom/pvh.bin > > #    pc-bios/optionrom/pvh.img > > #    pc-bios/optionrom/pvh.raw Thanks Liam! > > pvh.bin should not be ignored. I committed pc-bios/pvh.bin, but I thi

Re: [Qemu-devel] [PATCH v4 5/5] optionrom/pvh: load initrd from fw_cfg

2019-01-17 Thread Stefano Garzarella
On Thu, Jan 17, 2019 at 02:52:25PM +, Liam Merwick wrote: > > > On 17/01/2019 14:37, Paolo Bonzini wrote: > > On 17/01/19 15:33, Liam Merwick wrote: > > > #    pc-bios/optionrom/pvh.bin > > > #    pc-bios/optionrom/pvh.img > > > #    pc-bios/optionrom/pvh.raw > > > > pvh.bin should not be ig

Re: [Qemu-devel] [PATCH v4 5/5] optionrom/pvh: load initrd from fw_cfg

2019-01-17 Thread Stefano Garzarella
On Thu, Jan 17, 2019 at 04:18:00PM +0100, Paolo Bonzini wrote: > On 17/01/19 16:05, Stefano Garzarella wrote: > >> That's part of what I didn't quite understand. > >> pc-bios/optionrom/linuxboot.bin (and the other binaries in the 'build-all' > >

[Qemu-devel] [PATCH v5 1/5] linuxboot_dma: remove duplicate definitions of FW_CFG

2019-01-18 Thread Stefano Garzarella
FW_CFG_DMA_CTL_* bits and struct fw_cfg_dma_access are defined in the qemu_fw_cfg.h header file already included in linuxboot_dma.c, so we can remove the definition of BIOS_CFG_DMA_CTL_* and struct FWCfgDmaAccess. Signed-off-by: Stefano Garzarella Reviewed-by: Stefan Hajnoczi Reviewed-by: Liam

[Qemu-devel] [PATCH v5 0/5] pvh: add new PVH option rom

2019-01-18 Thread Stefano Garzarella
of linuxboot_dma.c and add in optrom.h - Patch 4: added check of pvh.bin in xen_load_linux() - modified commit message of patch 2 to explain better the patch Stefano Garzarella (5): linuxboot_dma: remove duplicate definitions of FW_CFG linuxboot_dma: move common functions in a new heade

[Qemu-devel] [PATCH v5 2/5] linuxboot_dma: move common functions in a new header

2019-01-18 Thread Stefano Garzarella
available. Signed-off-by: Stefano Garzarella Reviewed-by: Stefan Hajnoczi Reviewed-by: Liam Merwick --- pc-bios/optionrom/linuxboot_dma.c | 102 ++- pc-bios/optionrom/optrom.h| 110 ++ pc-bios/optionrom/optrom_fw_cfg.h | 92

[Qemu-devel] [PATCH v5 5/5] optionrom/pvh: load initrd from fw_cfg

2019-01-18 Thread Stefano Garzarella
If we found initrd through fw_cfg, we can load it and use the first module of hvm_start_info to pass initrd address and size to the kernel. Signed-off-by: Stefano Garzarella Reviewed-by: Stefan Hajnoczi Reviewed-by: Liam Merwick --- pc-bios/optionrom/pvh_main.c | 21 +++-- pc

[Qemu-devel] [PATCH v5 3/5] optionrom: add new PVH option rom

2019-01-18 Thread Stefano Garzarella
pvh_load_kernel() written in pvh_main.c. pvh_load_kernel() loads the cmdline and kernel entry_point using fw_cfg, then it looks for RSDP, fills the hvm_start_info required by x86/HVM ABI, and finally jumps to the kernel entry_point. Signed-off-by: Stefano Garzarella Reviewed-by: Stefan Hajnoczi Reviewed

[Qemu-devel] [PATCH v5 4/5] hw/i386/pc: use PVH option rom

2019-01-18 Thread Stefano Garzarella
Use pvh.bin option rom when we are booting an uncompressed kernel using the x86/HVM direct boot ABI. Signed-off-by: Stefano Garzarella Reviewed-by: Stefan Hajnoczi Reviewed-by: Liam Merwick --- hw/i386/pc.c | 5 + 1 file changed, 5 insertions(+) diff --git a/hw/i386/pc.c b/hw/i386/pc.c

Re: [Qemu-devel] [PATCH v6 4/4] i386: allow to load initrd below 4 GB for recent linux

2019-01-21 Thread Stefano Garzarella
gt; > --- > V6: update comments > V5: udpate comments and changelog > V3: correct grammar and check XLF_CAN_BE_LOADED_ABOVE_4G first (Michael S. > Tsirkin) > > Signed-off-by: Li Zhijian > --- > hw/i386/pc.c | 21 - > 1 file changed, 20 insertions(+), 1 deletion(-) Reviewed-by: Stefano Garzarella

Re: [Qemu-devel] [PATCH 2/3] util/cutils: Move ctype macros to "cutils.h"

2019-01-02 Thread Stefano Garzarella
/json-parser.c | 1 - > target/ppc/monitor.c | 1 + > ui/keymaps.c | 1 + > util/id.c | 2 +- > util/readline.c| 1 - > 12 files changed, 32 insertions(+), 22 deletions(-) Reviewed-by: Stefano Garzarella > > diff --gi

Re: [Qemu-devel] [RFC v2 0/4] QEMU changes to do PVH boot

2019-01-03 Thread Stefano Garzarella
gt; hw/sparc/leon3.c | 3 +- > hw/sparc/sun4m.c | 6 +- > hw/sparc64/sun4u.c | 4 +- > hw/tricore/tricore_testboard.c | 2 +- > hw/xtensa/sim.c| 12 ++-- > hw/xtensa/xtfpga.c | 2 +- > include/elf.h | 10 +++ > include/hw/elf_ops.h | 72 > include/hw/loader.h| 9 ++- > include/hw/xen/start_info.h| 146 > + > 44 files changed, 469 insertions(+), 71 deletions(-) > create mode 100644 include/hw/xen/start_info.h > > -- > 1.8.3.1 > -- Stefano Garzarella Red Hat

Re: [Qemu-devel] [PATCH for-4.0 v4 3/4] i386: import & use bootparam.h

2019-01-04 Thread Stefano Garzarella
dir/include/asm/unistd_x32.h" > "$output/linux-headers/asm-x86/" > cp "$tmpdir/include/asm/unistd_64.h" "$output/linux-headers/asm-x86/" > cp_portable "$tmpdir/include/asm/kvm_para.h" > "$output/include/standard-hea

Re: [Qemu-devel] [PATCH v2 1/3] util/cutils: Move size_to_str() from "qemu-common.h" to "cutils.h"

2019-01-07 Thread Stefano Garzarella
tils.h| 13 + > qapi/string-output-visitor.c | 2 +- > util/cutils.c| 6 -- > 4 files changed, 14 insertions(+), 8 deletions(-) Reviewed-by: Stefano Garzarella > > diff --git a/include/qemu-common.h b/include/qemu-common.h > index ed

Re: [Qemu-devel] [PATCH v2 3/3] util/cutils: Move function documentations to the header

2019-01-07 Thread Stefano Garzarella
ippe Mathieu-Daudé > --- > include/qemu/cutils.h | 224 ++ > util/cutils.c | 185 -- > 2 files changed, 224 insertions(+), 185 deletions(-) Reviewed-by: Stefano Garzarella > > diff --git a/include/q

Re: [Qemu-devel] [PATCH for-4.0 v4 1/4] unify len and addr type for memory/address APIs

2019-01-07 Thread Stefano Garzarella
; include/exec/cpu-all.h| 2 +- > include/exec/cpu-common.h | 8 > include/exec/memory.h | 22 +++--- > 4 files changed, 39 insertions(+), 40 deletions(-) Reviewed-by: Stefano Garzarella

Re: [Qemu-devel] [PATCH for-4.0 v4 2/4] refactor load_image_size

2019-01-07 Thread Stefano Garzarella
Signed-off-by: Li Zhijian > >> Reviewed-by: Richard Henderson > > This is more a theoretical bugfix than a refactoring right? > > Yes, it does. > > how about change the title to : "enhance reading on load_image_size()" or such Maybe something like this: "hw/

Re: [Qemu-devel] [PATCH for-4.0 v4 4/4] i386: allow to load initrd below 4G for recent linux

2019-01-07 Thread Stefano Garzarella
Hi, On Thu, Dec 27, 2018 at 9:32 PM Eduardo Habkost wrote: > > On Fri, Dec 21, 2018 at 11:10:30AM -0500, Michael S. Tsirkin wrote: > > On Thu, Dec 06, 2018 at 10:32:13AM +0800, Li Zhijian wrote: > > > a new field xloadflags was added to recent x86 linux, and BIT 1: > > > XLF_CAN_BE_LOADED_ABOVE_4

Re: [Qemu-devel] [RFC v2 0/4] QEMU changes to do PVH boot

2019-01-09 Thread Stefano Garzarella
Then we can load the initrd in qboot or in the optionrom that I'm writing. What do you think? Thanks, Stefano > I'm checking to see if that has any implications for the kernel side. > > Regards, > Liam > -- Stefano Garzarella Red Hat

<    1   2   3   4   5   6   7   8   9   10   >