Re: hppa-firmware.img missing build-id

2024-04-23 Thread Richard W.M. Jones
On Tue, Apr 23, 2024 at 10:11:50AM -0400, Cole Robinson wrote: > Hi, > > hppa-firmware.img and hppa-firmware64.img in qemu.git are missing ELF > build-id annotations. rpm builds on Fedora will error if an ELF binary > doesn't have build-id: > > RPM build errors: > Missing build-id in >

Re: [PATCH for-9.1 6/9] block/nbd: Use URI parsing code from glib

2024-04-04 Thread Richard W.M. Jones
On Thu, Mar 28, 2024 at 04:40:10PM +, Richard W.M. Jones wrote: > libnbd absolutely does *not* get this right, eg: > > $ nbdinfo NBD://localhost > nbdinfo: nbd_connect_uri: unknown NBD URI scheme: NBD: Invalid argument > > so that's a bug too. Proposed fix: https:/

Re: [PATCH for-9.1 6/9] block/nbd: Use URI parsing code from glib

2024-03-28 Thread Richard W.M. Jones
On Thu, Mar 28, 2024 at 10:06:01AM -0500, Eric Blake wrote: > Adjusting cc list to add upstream NBD and drop developers unrelated to > this part of the qemu series... > > On Thu, Mar 28, 2024 at 02:13:42PM +0000, Richard W.M. Jones wrote: > > On Thu, Mar 28, 2024 at 03:06:03PM

Re: [PATCH for-9.1 6/9] block/nbd: Use URI parsing code from glib

2024-03-28 Thread Richard W.M. Jones
ress */ > -if (uri->server[0] == '[') { > -host = qstring_from_substr(uri->server, 1, > - strlen(uri->server) - 1); > -} else { > -host = qstring_from_str(uri->server); > -} > - > qdict_

Re: [PATCH for-9.1 8/9] block/ssh: Use URI parsing code from glib

2024-03-28 Thread Richard W.M. Jones
("Failed to parse SSH URI parameters '%s'.", > +uri_query); > + break; > +} > +/* > + * Pick out the query parameters that we understand, and ignore > + * (or rather warn about) the rest. > +

[PATCH v2] block/blkio: Make s->mem_region_alignment be 64 bits

2024-01-30 Thread Richard W.M. Jones
aka ‘long long unsigned int *’} but argument is of type ‘size_t *’ {aka ‘unsigned int *’} 49 | int blkio_get_uint64(struct blkio *b, const char *name, uint64_t *value); | ~~^ Signed-off-by: Richard W.M. Jones --- bl

Re: [PATCH [repost]] block/blkio: Don't assume size_t is 64 bit

2024-01-30 Thread Richard W.M. Jones
On Tue, Jan 30, 2024 at 01:04:46PM +0100, Kevin Wolf wrote: > Am 30.01.2024 um 11:30 hat Richard W.M. Jones geschrieben: > > On Tue, Jan 30, 2024 at 09:51:59AM +0100, Kevin Wolf wrote: > > > Am 29.01.2024 um 19:53 hat Richard W.M. Jones geschrieben: > > > > With GCC

Re: [PATCH [repost]] block/blkio: Don't assume size_t is 64 bit

2024-01-30 Thread Richard W.M. Jones
On Tue, Jan 30, 2024 at 09:51:59AM +0100, Kevin Wolf wrote: > Am 29.01.2024 um 19:53 hat Richard W.M. Jones geschrieben: > > With GCC 14 the code failed to compile on i686 (and was wrong for any > > version of GCC): > > > > ../block/blkio.c: In function ‘blkio_file_open

[PATCH [repost]] block/blkio: Don't assume size_t is 64 bit

2024-01-29 Thread Richard W.M. Jones
aka ‘long long unsigned int *’} but argument is of type ‘size_t *’ {aka ‘unsigned int *’} 49 | int blkio_get_uint64(struct blkio *b, const char *name, uint64_t *value); | ~~^ Signed-off-by: Richard W.M. Jones --- bl

[PATCH [repost]] block/blkio: Don't assume size_t is 64 bit

2024-01-29 Thread Richard W.M. Jones
Repost of the same patch as a minute ago because I messed up a couple of email addresses in the CC. Rich.

Re: [PATCH] xen: fix condition for enabling the Xen accelerator

2023-12-09 Thread Richard W.M. Jones
CONFIG_XEN'] similar > to what is already there for KVM, and fix xen_native.h. Here's a Fedora scratch build with Xen 4.18.0 which includes this patch: https://koji.fedoraproject.org/koji/taskinfo?taskID=110105806 Rich. > Cc: Stefano Stabellini > Cc: Richard W.M. Jones > Cc: Daniel

Re: [PATCH] fix qemu build with xen-4.18.0

2023-12-08 Thread Richard W.M. Jones
On Fri, Dec 08, 2023 at 08:47:07AM +, Richard W.M. Jones wrote: > (Adding Xen maintainers) > > On Thu, Dec 07, 2023 at 11:12:48PM +, Michael Young wrote: > > Builds of qemu-8.2.0rc2 with xen-4.18.0 are currently failing > > with errors like > > ../h

Re: [PATCH] fix qemu build with xen-4.18.0

2023-12-08 Thread Richard W.M. Jones
On Fri, Dec 08, 2023 at 08:47:07AM +, Richard W.M. Jones wrote: > (Adding Xen maintainers) > > On Thu, Dec 07, 2023 at 11:12:48PM +, Michael Young wrote: > > Builds of qemu-8.2.0rc2 with xen-4.18.0 are currently failing > > with errors like > > ../h

Re: [PATCH] fix qemu build with xen-4.18.0

2023-12-08 Thread Richard W.M. Jones
; > Signed-off-by: Michael Young Reviewed-by: Richard W.M. Jones > --- > include/hw/xen/xen_native.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/include/hw/xen/xen_native.h b/include/hw/xen/xen_native.h > index 6f09c48823..04b1ef4d34 100644 >

Re: [PATCH 4/7] hw/scsi/virtio-scsi: Use VIRTIO_SCSI_COMMON() macro

2023-10-31 Thread Richard W.M. Jones
On Tue, Oct 31, 2023 at 05:42:37PM +0100, Kevin Wolf wrote: > Am 31.10.2023 um 14:48 hat Richard W.M. Jones geschrieben: > > On Tue, Oct 31, 2023 at 02:17:56PM +0100, Kevin Wolf wrote: > > > Am 17.10.2023 um 16:01 hat Philippe Mathieu-Daudé geschrieben: > > > > Acc

Re: [PATCH 4/7] hw/scsi/virtio-scsi: Use VIRTIO_SCSI_COMMON() macro

2023-10-31 Thread Richard W.M. Jones
On Tue, Oct 31, 2023 at 02:17:56PM +0100, Kevin Wolf wrote: > Am 17.10.2023 um 16:01 hat Philippe Mathieu-Daudé geschrieben: > > Access QOM parent with the proper QOM VIRTIO_SCSI_COMMON() macro. > > > > Signed-off-by: Philippe Mathieu-Daudé > > --- > > hw/scsi/virtio-scsi.c | 2 +- > > 1 file

Re: tcg_flush_jmp_cache replacing qatomic_set loop with memset

2023-10-16 Thread Richard W.M. Jones
On Mon, Oct 16, 2023 at 04:43:36PM +0100, Richard W.M. Jones wrote: > Hey Paolo, > > Quick question. I'm sure the transformation below is *not* correct, > because it doesn't preserve the invariant of the lockless structure. > Is there a way to do this while maintaining correctnes

tcg_flush_jmp_cache replacing qatomic_set loop with memset

2023-10-16 Thread Richard W.M. Jones
Hey Paolo, Quick question. I'm sure the transformation below is *not* correct, because it doesn't preserve the invariant of the lockless structure. Is there a way to do this while maintaining correctness? For example putting barrier() after memset? (Note I'm also zeroing .pc which may be a

Re: [PATCH 2/6] target/riscv: Use env_archcpu() in [check_]nanbox()

2023-10-09 Thread Richard W.M. Jones
m-cast-debug. > > Inspired-by: Richard W.M. Jones > Signed-off-by: Philippe Mathieu-Daudé > --- > target/riscv/internals.h | 8 > 1 file changed, 4 insertions(+), 4 deletions(-) > > diff --git a/target/riscv/internals.h b/target/riscv/internals.h > index b5f82

Re: [PATCH v2] target/riscv: Use a direct cast for better performance

2023-10-09 Thread Richard W.M. Jones
On Mon, Oct 09, 2023 at 08:36:28PM +0800, LIU Zhiwei wrote: > > On 2023/10/9 5:50, Richard W.M. Jones wrote: > >RISCV_CPU(cs) uses a checked cast. When QOM cast debugging is enabled > >this adds about 5% total overhead when emulating RV64 on x86-64 host. > > > >Usin

[PATCH v3] target/riscv: Use env_archcpu for better performance

2023-10-09 Thread Richard W.M. Jones
the qemu source tree with 'make clean; time make -j16'. Before making this change the compile step took 449 & 447 seconds over two consecutive runs. After making this change: 428 & 421 seconds. The saving is over 5%. Thanks: Paolo Bonzini Thanks: Philippe Mathieu-Daudé Signed-off-by: Richard W.

[PATCH v3] target/riscv: Use env_archcpu for better performance

2023-10-09 Thread Richard W.M. Jones
In v3: - Use env_archcpu - Rerun the benchmark to get new "after" figures Rich.

[PATCH v2] target/riscv: Use a direct cast for better performance

2023-10-08 Thread Richard W.M. Jones
the qemu source tree with 'make clean; time make -j16'. Before making this change the compile step took 449 & 447 seconds over two consecutive runs. After making this change, 428 & 422 seconds. The saving is about 5%. Thanks: Paolo Bonzini Signed-off-by: Richard W.M. Jones Reviewed-by: Daniel

[PATCH v2] target/riscv: Use a direct cast for better performance

2023-10-08 Thread Richard W.M. Jones
v1 was here: https://lists.nongnu.org/archive/html/qemu-devel/2023-10/msg02021.html v2 is functionally exactly the same, except I changed s/qemu cast/QOM cast/ in the comment, and added the Reviewed-by tag received for the first version. Rich.

Re: [PATCH] target/riscv: Use a direct cast for better performance

2023-10-07 Thread Richard W.M. Jones
If you're interested in how I found this problem, it was done using 'perf report -a -g' & flamegraphs. This is the flamegraph of qemu (on the host) when the guest is running the parallel compile: http://oirase.annexia.org/tmp/qemu-riscv.svg If you click into 'CPU_0/TCG' at the bottom left

[PATCH] target/riscv: Use a direct cast for better performance

2023-10-07 Thread Richard W.M. Jones
the qemu source tree with 'make clean; time make -j16'. Before making this change the compile step took 449 & 447 seconds over two consecutive runs. After making this change, 428 & 422 seconds. The saving is about 5%. Thanks: Paolo Bonzini Signed-off-by: Richard W.M. Jones --- targ

Re: [PATCH] qemu-img: Update documentation for compressed images

2023-09-01 Thread Richard W.M. Jones
On Fri, Sep 01, 2023 at 12:24:30PM +0200, Kevin Wolf wrote: > Document the 'compression_type' option for qcow2, and mention that > streamOptimized vmdk supports compression, too. > > Reported-by: Richard W.M. Jones > Signed-off-by: Kevin Wolf Looks good, so: Reviewed-by: Ric

Re: qemu-img cache modes with Linux cgroup v1

2023-07-31 Thread Richard W.M. Jones
On Mon, Jul 31, 2023 at 11:40:36AM -0400, Stefan Hajnoczi wrote: > 3. Using buffered I/O because O_DIRECT is not universally supported? > > If you can't use O_DIRECT, then qemu-img could be extended to manage its > dirty page cache set carefully. This consists of picking a budget and > writing

Re: [PATCH v2 2/2] accel/tcg: Always lock pages before translation

2023-07-07 Thread Richard W.M. Jones
I'm not sure if you meant v3 there, or if this is v2 rebased on top of the main branch, but I tested it again and it passed 5,000 boots. Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog:

Re: [PATCH v2 2/2] accel/tcg: Always lock pages before translation

2023-07-07 Thread Richard W.M. Jones
ed-by: Richard W.M. Jones > Signed-off-by: Richard Henderson > Tested-by: Richard W.M. Jones I tested another 5,000 iterations successfully, so this one looks good as well. I don't have an easy way to test qemu-user, so I only tested qemu-system-x86_64. Rich. > --- > a

Re: [PATCH 2/2] accel/tcg: Always lock pages before translation

2023-07-06 Thread Richard W.M. Jones
ed-by: Richard W.M. Jones > Signed-off-by: Richard Henderson Tested-by: Richard W.M. Jones I tested it across two machines, total of 10,000 iterations successfully. Great fix, thanks. Rich. > accel/tcg/internal.h | 30 - > accel/tcg/cpu-exec.c | 4 + > a

Re: [PATCH 1/2] accel/tcg: Split out cpu_exec_longjmp_cleanup

2023-07-06 Thread Richard W.M. Jones
On Thu, Jul 06, 2023 at 06:05:36PM +0100, Richard Henderson wrote: > Share the setjmp cleanup between cpu_exec_step_atomic > and cpu_exec_setjmp. > > Signed-off-by: Richard Henderson Reviewed-by: Richard W.M. Jones (I'm still testing the other one, but already up to 600 itera

[PATCH] tb-maint: Document #ifdef..else..endif correctly

2023-07-06 Thread Richard W.M. Jones
It was hard to tell from the comments whether the code applied to user mode (CONFIG_USER_ONLY) or system mode. Fix the comments on the #else and #endif directives to be clearer. Signed-off-by: Richard W.M. Jones --- accel/tcg/tb-maint.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions

Collecting information from a hung qemu process

2023-06-08 Thread Richard W.M. Jones
I filed this bug about recent Linux hanging very rarely when booting on recent qemu: https://gitlab.com/qemu-project/qemu/-/issues/1696 As I'm able to reproduce this bug at will (albeit I have to wait for 100s or 1000s of iterations of the test), I am able to observe the qemu process after it

Re: [PATCH nbd 1/4] nbd: Add multi-conn option

2023-03-10 Thread Richard W.M. Jones
On Fri, Mar 10, 2023 at 04:17:17PM -0600, Eric Blake wrote: > On Thu, Mar 09, 2023 at 11:39:43AM +0000, Richard W.M. Jones wrote: > > + * safe for multi-conn, force it to 1. > > + */ > > +if (!(s->info.flags & NBD_FLAG_CAN_MULTI_CONN)) { &g

Re: [PATCH nbd 0/4] Enable multi-conn NBD [for discussion only]

2023-03-10 Thread Richard W.M. Jones
On Fri, Mar 10, 2023 at 01:04:12PM -0600, Eric Blake wrote: > How many of these timing numbers can be repeated with TLS in the mix? While I have been playing with TLS and kTLS recently, it's not something that is especially important to v2v since all NBD traffic goes over Unix domain sockets only

[PATCH nbd 1/4] nbd: Add multi-conn option

2023-03-09 Thread Richard W.M. Jones
oes not advertise that it is safe for multi-conn then this setting is forced to 1. Signed-off-by: Richard W.M. Jones --- block/nbd.c | 24 1 file changed, 24 insertions(+) diff --git a/block/nbd.c b/block/nbd.c index bf2894ad5c..5ffae0b798 100644 --- a/block/nbd.c +++ b/block/nb

[PATCH nbd 3/4] nbd: Open multiple NBD connections if multi-conn is set

2023-03-09 Thread Richard W.M. Jones
or shortlived NBD operations do not require multiple connections to be made. Signed-off-by: Richard W.M. Jones --- block/nbd.c | 128 1 file changed, 90 insertions(+), 38 deletions(-) diff --git a/block/nbd.c b/block/nbd.c index 84e8a1add0

[PATCH nbd 4/4] nbd: Enable multi-conn using round-robin

2023-03-09 Thread Richard W.M. Jones
on size of requests outstanding) the load on each connection. But this implementation doesn't do any of that. Signed-off-by: Richard W.M. Jones --- block/nbd.c | 67 +++-- 1 file changed, 49 insertions(+), 18 deletions(-) diff --git a/block/nbd.c b

[PATCH nbd 2/4] nbd: Split out block device state from underlying NBD connections

2023-03-09 Thread Richard W.M. Jones
the zeroth slot in the conns[] array. Thus this does not implement multi-conn yet. Signed-off-by: Richard W.M. Jones --- block/coroutines.h | 5 +- block/nbd.c| 674 - 2 files changed, 358 insertions(+), 321 deletions(-) diff --git a/block

[PATCH nbd 0/4] Enable multi-conn NBD [for discussion only]

2023-03-09 Thread Richard W.M. Jones
[ Patch series also available here, along with this cover letter and the script used to generate test results: https://gitlab.com/rwmjones/qemu/-/commits/2023-nbd-multi-conn-v1 ] This patch series adds multi-conn support to the NBD block driver in qemu. It is only meant for discussion and

[PATCH v2] tcg: Include "qemu/timer.h" for profile_getclock

2023-03-03 Thread Richard W.M. Jones
-declaration] 4905 | qatomic_set(>opt_time, prof->opt_time - profile_getclock()); | ^~~~ Thanks: Philippe Mathieu-Daudé Signed-off-by: Richard W.M. Jones --- accel/tcg/tcg-accel-ops.c | 1 + accel/tcg/translate-all

[PATCH] tcg: Include "qemu/timer.h" for profile_getclock

2023-03-02 Thread Richard W.M. Jones
-declaration] 4905 | qatomic_set(>opt_time, prof->opt_time - profile_getclock()); | ^~~~ Signed-off-by: Richard W.M. Jones --- tcg/tcg.c | 1 + 1 file changed, 1 insertion(+) diff --git a/tcg/tcg.c b/tcg/tcg.c

Re: [GSoC 2023] Introducing Myself

2023-03-02 Thread Richard W.M. Jones
On Thu, Mar 02, 2023 at 07:17:46PM +0530, Ayush Singh wrote: > Hello Everyone, > > I am Ayush Singh, a 3rd-year university student from the Indian Institute of > Technology (Indian School of Mines), Dhanbad, India. This email is just to > > I participated and successfully completed my GSoC 2022

Re: [PATCH] tests: Ensure TAP version is printed before other messages

2023-03-01 Thread Richard W.M. Jones
On Tue, Feb 28, 2023 at 09:30:56PM +0100, Thomas Huth wrote: > On 27/02/2023 18.40, Richard W.M. Jones wrote: > >These two tests were failing with this error: > > > > stderr: > > TAP parsing error: version number must be on the first line > > [...] > >

Re: [PATCH v2] test-vmstate: fix bad GTree usage, use-after-free

2023-02-27 Thread Richard W.M. Jones
b.com/qemu-project/qemu/-/issues/1518 > Signed-off-by: Marc-André Lureau > Signed-off-by: Eric Auger > Reported-by: Richard W.M. Jones You can add: Tested-by: Richard W.M. Jones Reviewed-by: Richard W.M. Jones > --- > > This is a respin of Marc-André's patch from Au

[PATCH] tests: Ensure TAP version is printed before other messages

2023-02-27 Thread Richard W.M. Jones
. Thanks: Daniel Berrange, for diagnosing the problem Signed-off-by: Richard W.M. Jones --- tests/qtest/fuzz-lsi53c895a-test.c | 4 ++-- tests/qtest/rtl8139-test.c | 5 +++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/tests/qtest/fuzz-lsi53c895a-test.c b/tests/qtest/fuzz

Re: RFC: towards systemd socket activation in q-s-d

2023-01-30 Thread Richard W.M. Jones
On Mon, Jan 30, 2023 at 04:45:08PM +, Daniel P. Berrangé wrote: > which is LISTEN_FDS=2, LISTEN_FDNAMES=control,vnc Colon for separating the elements not comma. Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization

Re: RFC: towards systemd socket activation in q-s-d

2023-01-30 Thread Richard W.M. Jones
On Mon, Jan 30, 2023 at 02:58:01PM +, Daniel P. Berrangé wrote: > Obviously at startup QEMU can trivially inherit the FDs from whatever > spawned it. The only task is to identify the FDs that are passed into, > and systemd defined a mechanism for this using LISTEN_FDNAMES. IOW the > socket

Re: RFC: towards systemd socket activation in q-s-d

2023-01-27 Thread Richard W.M. Jones
On Fri, Jan 27, 2023 at 03:26:15PM -0600, Eric Blake wrote: > In https://bugzilla.redhat.com/show_bug.cgi?id=2055229, the question > was raised on how to make qemu-storage-daemon sufficiently powerful to > be a full-blown replacement to qemu-nbd. One of the features still > lacking is the ability

Re: [PATCH 4/4] hw/isa: enable TCO watchdog reboot pin strap by default

2022-10-31 Thread Richard W.M. Jones
--- a/tests/qtest/tco-test.c > +++ b/tests/qtest/tco-test.c > @@ -60,7 +60,7 @@ static void test_init(TestData *d) > QTestState *qs; > > qs = qtest_initf("-machine q35 %s %s", > - d->noreboot ? "" : "-global ICH9-LPC.noreboot=fal

Re: [PATCH 2/4] hw/isa: add trace events for ICH9 LPC chip config access

2022-10-31 Thread Richard W.M. Jones
quot;addr 0x%x val 0x%x > len 0x%x" > via_superio_read(uint8_t addr, uint8_t val) "addr 0x%x val 0x%x" > via_superio_write(uint8_t addr, uint32_t val) "addr 0x%x val 0x%x" > + > +# lpc_ich9.c > +ich9_cc_write(uint64_t addr, uint64_t val, unsigned len) "

Re: [PATCH 3/4] hw/watchdog: add trace events for watchdog action handling

2022-10-31 Thread Richard W.M. Jones
stem_reset' in monitor */ > qapi_event_send_watchdog(WATCHDOG_ACTION_RESET); > @@ -89,4 +92,5 @@ void watchdog_perform_action(void) > void qmp_watchdog_set_action(WatchdogAction action, Error **errp) > { > watchdog_action = action; > +trace_watchdog_set_action(wat

Re: [PATCH 1/4] hw/acpi: add trace events for TCO watchdog register access

2022-10-31 Thread Richard W.M. Jones
ddr: 0x%" PRIx64 > # tco.c > tco_timer_reload(int ticks, int msec) "ticks=%d (%d ms)" > tco_timer_expired(int timeouts_no, bool strap, bool no_reboot) > "timeouts_no=%d no_reboot=%d/%d" > +tco_io_write(uint64_t addr, uint32_t val) "addr=0x%" PRIx64 "

Re: ublk-qcow2: ublk-qcow2 is available

2022-10-06 Thread Richard W.M. Jones
On Tue, Oct 04, 2022 at 09:53:32AM -0400, Stefan Hajnoczi wrote: > qemu-nbd doesn't use io_uring to handle the backend IO, Would this be fixed by your (not yet upstream) libblkio driver for qemu? Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my

Re: [PATCH 01/11] crypto: sanity check that LUKS header strings are NUL-terminated

2022-09-06 Thread Richard W.M. Jones
fferent: char cipher_name[33], cipher_mode[33], hash_spec[33]; /* Copy the header fields locally and ensure they are \0 terminated. */ memcpy (cipher_name, h->phdr.cipher_name, 32); cipher_name[32] = 0; memcpy (cipher_mode, h->phdr.cipher_mode, 32); cipher_mode[32] = 0; memcpy (hash_s

Re: [PATCH 04/11] crypto: validate that LUKS payload doesn't overlap with header

2022-09-06 Thread Richard W.M. Jones
On Tue, Sep 06, 2022 at 09:41:40AM +0100, Daniel P. Berrangé wrote: > We already validate that LUKS keyslots don't overlap with the > header, or with each other. This closes the remain hole in remain -> remaining > validation of LUKS file regions. > > Signed-off-by: Daniel P. Berrangé > --- >

Re: [PATCH 00/11] crypto: improve robustness of LUKS metadata validation

2022-09-06 Thread Richard W.M. Jones
143 > crypto/block-luks.c| 228 +++-- > tests/unit/test-crypto-block.c | 302 - > 3 files changed, 542 insertions(+), 131 deletions(-) > create mode 100644 crypto/block-luks-priv.h I think there is one typo in a com

Re: [PATCH 06/11] crypto: check that LUKS PBKDF2 iterations count is non-zero

2022-09-06 Thread Richard W.M. Jones
e're just trying to sanity check the device hasn't been corrupted or improperly prepared. The test above is the latter, I think. Nevertheless as this is an improvement over the current situation: Reviewed-by: Richard W.M. Jones Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.

Re: [PATCH 02/11] crypto: enforce that LUKS stripes is always a fixed value

2022-09-06 Thread Richard W.M. Jones
only important implementation (the kernel) always fixes this at 4000 (cryptsetup.git/lib/keymanage.c), so: Reviewed-by: Richard W.M. Jones Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com virt-builder quickly builds VMs from scratch http://libguestfs.org/virt-builder.1.html

Re: [PATCH] linux-user: use 'max' instead of 'qemu32' / 'qemu64' by defualt

2022-08-26 Thread Richard W.M. Jones
On Fri, Aug 26, 2022 at 12:39:00PM +0100, Daniel P. Berrangé wrote: > The 'qemu64' CPU model implements the least featureful x86_64 CPU that's > possible. Historically this hasn't been an issue since it was rare for > OS distros to build with a higher mandatory CPU baseline. > > With RHEL-9,

Re: [RFC v2 02/10] Drop unused static function return values

2022-08-03 Thread Richard W.M. Jones
On Wed, Aug 03, 2022 at 01:25:34PM +0100, Peter Maydell wrote: > On Wed, 3 Aug 2022 at 12:44, Daniel P. Berrangé wrote: > > Inconsistent return value checking is designed-in behaviour for > > QEMU's current Error handling coding pattern with error_abort/fatal. > > Yes; I habitually mark as

Re: [RFC v2 02/10] Drop unused static function return values

2022-08-03 Thread Richard W.M. Jones
On Wed, Aug 03, 2022 at 12:07:19PM +0100, Alberto Faria wrote: > On Wed, Aug 3, 2022 at 11:46 AM Dr. David Alan Gilbert > wrote: > > > > * Alberto Faria (afa...@redhat.com) wrote: > > > Make non-void static functions whose return values are ignored by > > > all callers return void instead. > > >

Re: [PATCH for 7.1] linux-user: fix compat with glibc >= 2.36 sys/mount.h

2022-08-02 Thread Richard W.M. Jones
On Tue, Aug 02, 2022 at 07:29:29PM +0100, Richard W.M. Jones wrote: > Dan, which Fedora glibc package shows this problem? I have > glibc-2.35.9000-31.fc37.x86_64 and qemu compiled fine. (Also nbdkit > which includes linux/fs.h) It would help if I enabled a *-linux-user target ... Y

Re: [PATCH for 7.1] linux-user: fix compat with glibc >= 2.36 sys/mount.h

2022-08-02 Thread Richard W.M. Jones
On Tue, Aug 02, 2022 at 12:41:34PM -0400, Daniel P. Berrangé wrote: > The latest glibc 2.36 has extended sys/mount.h so that it > defines the FSCONFIG_* enum constants. These are historically > defined in linux/mount.h, and thus if you include both headers > the compiler complains: > > In file

Re: [PATCH v3 3/3] nbd/server: Allow MULTI_CONN for shared writable exports

2022-03-16 Thread Richard W.M. Jones
On Wed, Mar 16, 2022 at 04:15:53PM -0500, Eric Blake wrote: > On Wed, Mar 16, 2022 at 04:07:21PM -0500, Eric Blake wrote: > > On Tue, Mar 15, 2022 at 01:14:41PM +, Richard W.M. Jones wrote: > > > The patches seem OK to me, but I don't really know enough about the > >

Re: [PATCH 07/27] Replace GCC_FMT_ATTR with G_GNUC_PRINTF

2022-03-16 Thread Richard W.M. Jones
l. I even learned about gnu_printf. So: Reviewed-by: Richard W.M. Jones Shouldn't there be a hunk which removes the definition of GCC_FMT_ATTR from include/qemu/compiler.h? Maybe that's in another place in the patch series. Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.

Re: [PATCH v3 3/3] nbd/server: Allow MULTI_CONN for shared writable exports

2022-03-15 Thread Richard W.M. Jones
The patches seem OK to me, but I don't really know enough about the internals of qemu-nbd to give a line-by-line review. I did however build and test qemu-nbd with the patches: $ ./build/qemu-nbd /var/tmp/test.qcow2 $ nbdinfo nbd://localhost ... can_multi_conn: false $

Re: [PATCH v2] nbd/server: Allow MULTI_CONN for shared writable exports

2022-02-16 Thread Richard W.M. Jones
On Tue, Feb 15, 2022 at 05:24:14PM -0600, Eric Blake wrote: > Oh. The QMP command (which is immediately visible through > nbd-server-add/block-storage-add to qemu and qemu-storage-daemon) > gains "multi-conn":"on", but you may be right that qemu-nbd would want > a command line option (either that,

Re: [PATCH v2] Deprecate C virtiofsd

2022-02-10 Thread Richard W.M. Jones
On Thu, Feb 10, 2022 at 05:47:14PM +, Dr. David Alan Gilbert (git) wrote: > From: "Dr. David Alan Gilbert" > > There's a nice new Rust implementation out there; recommend people > do new work on that. > > Signed-off-by: Dr. David Alan Gilbert > --- > docs/about/deprecated.rst | 17

Re: Block alignment of qcow2 compress driver

2022-01-28 Thread Richard W.M. Jones
On Fri, Jan 28, 2022 at 01:30:43PM +0100, Hanna Reitz wrote: > On 28.01.22 13:18, Richard W.M. Jones wrote: > >On Fri, Jan 28, 2022 at 12:57:47PM +0100, Hanna Reitz wrote: > >>On 28.01.22 12:48, Richard W.M. Jones wrote: > >>>On Fri, Jan 28, 2022 at 12:39:11PM +010

Re: Block alignment of qcow2 compress driver

2022-01-28 Thread Richard W.M. Jones
On Fri, Jan 28, 2022 at 01:30:53PM +, Richard W.M. Jones wrote: > I feel like this may be a bug in what qemu-nbd advertises. Currently > it is: Ignore this email, see other reply. Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my progr

Re: Block alignment of qcow2 compress driver

2022-01-28 Thread Richard W.M. Jones
On Fri, Jan 28, 2022 at 02:19:44PM +0100, Kevin Wolf wrote: > Am 28.01.2022 um 13:30 hat Hanna Reitz geschrieben: > > > > I just changed that line of code [2], as shown in [4].  I suppose > > > > the better thing to do would be to have an option for the NBD server > > > > to force-change the

Re: Block alignment of qcow2 compress driver

2022-01-28 Thread Richard W.M. Jones
On Fri, Jan 28, 2022 at 12:57:47PM +0100, Hanna Reitz wrote: > On 28.01.22 12:48, Richard W.M. Jones wrote: > >On Fri, Jan 28, 2022 at 12:39:11PM +0100, Hanna Reitz wrote: > >>So I actually don’t know why it works for you.  OTOH, I don’t > >>understand why the bloc

Re: Block alignment of qcow2 compress driver

2022-01-28 Thread Richard W.M. Jones
I hacked nbdcopy to ignore block alignment (the error actually comes from libnbd refusing to send the unaligned request, not from qemu-nbd), and indeed qemu-nbd accepts the unaligned request without complaint. Eric - maybe having some flag for nbdcopy to ignore unaligned requests when we know

Re: Block alignment of qcow2 compress driver

2022-01-28 Thread Richard W.M. Jones
On Fri, Jan 28, 2022 at 12:39:11PM +0100, Hanna Reitz wrote: > So I actually don’t know why it works for you.  OTOH, I don’t > understand why the block size affects you over NBD, because I would > have expected qemu to internally auto-align requests when they are > not aligned (in

Block alignment of qcow2 compress driver

2022-01-28 Thread Richard W.M. Jones
The commands below set up a sparse RAM disk, with an allocated block at offset 32K and another one at offset 1M-32K. Then it tries to copy this to a compressed qcow2 file using qemu-nbd + the qemu compress filter: $ qemu-img create -f qcow2 output.qcow2 1M $ qemu-nbd -t --image-opts

Re: [PATCH v1 20/34] tests/docker: add libfuse3 development headers

2022-01-05 Thread Richard W.M. Jones
Reitz > Cc: Richard W.M. Jones > Signed-off-by: Stefan Hajnoczi > Acked-by: Richard W.M. Jones > Reviewed-by: Beraldo Leal > Tested-by: Beraldo Leal > Message-Id: <20211207160025.52466-1-stefa...@redhat.com> > [AJB: migrate to lcitool qemu.yml and regenerat

Re: Redesign of QEMU startup & initial configuration

2022-01-04 Thread Richard W.M. Jones
Sorry for very delayed reply ... On Thu, Dec 02, 2021 at 07:57:38AM +0100, Markus Armbruster wrote: > 1. QMP only > >Management applications need to use QMP for monitoring anyway. They >may want to use it for initial configuration, too. Libvirt does. > >They still need to

Re: [PATCH v2] Move the libssh setup from configure to meson.build

2021-12-09 Thread Richard W.M. Jones
On Thu, Dec 09, 2021 at 04:08:24PM +0100, Thomas Huth wrote: > On 09/12/2021 15.55, Richard W.M. Jones wrote: > >On Thu, Dec 09, 2021 at 03:48:01PM +0100, Thomas Huth wrote: > >>It's easier to do this in meson.build now. > >> > >>Signed-off-by: Thomas Huth

Re: [PATCH v2] Move the libssh setup from configure to meson.build

2021-12-09 Thread Richard W.M. Jones
On Thu, Dec 09, 2021 at 03:48:01PM +0100, Thomas Huth wrote: > It's easier to do this in meson.build now. > > Signed-off-by: Thomas Huth > --- > v2: Added the missing "config_host_data.set('CONFIG_LIBSSH', libssh.found())" > > configure | 27 --- >

Re: [PATCH] tests/docker: add libfuse3 development headers

2021-12-07 Thread Richard W.M. Jones
e end. The rest of the changes look good too, so: Acked-by: Richard W.M. Jones Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com Fedora Windows cross-compiler. Compile Windows programs, test,

Re: QEMU 6.2.0 and rhbz#1999878

2021-12-03 Thread Richard W.M. Jones
On Fri, Dec 03, 2021 at 05:35:41PM -0300, Eduardo Lima wrote: > > > On Fri, Dec 3, 2021 at 4:37 PM Richard W.M. Jones wrote: > > On Fri, Dec 03, 2021 at 04:20:23PM -0300, Eduardo Lima wrote: > > Hi Rich, > > > > Can you confirm if the patch

Re: QEMU 6.2.0 and rhbz#1999878

2021-12-03 Thread Richard W.M. Jones
On Fri, Dec 03, 2021 at 04:20:23PM -0300, Eduardo Lima wrote: > Hi Rich, > > Can you confirm if the patch you added for qemu in Fedora has still not been > merged upstream? I could not find it on the git source tree. > > +Patch2: 0001-tcg-arm-Reduce-vector-alignment-requirement-for-NEON.patch >

Re: [PATCH v2 0/6] aio-posix: split poll check from ready handler

2021-12-02 Thread Richard W.M. Jones
Not sure if this is related, but builds are failing with: FAILED: libblockdev.fa.p/block_export_fuse.c.o cc -m64 -mcx16 -Ilibblockdev.fa.p -I. -I.. -Iqapi -Itrace -Iui -Iui/shader -I/usr/include/fuse3 -I/usr/include/p11-kit-1 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include

Re: [PATCH 0/1] vmx: Fix mapping

2021-10-04 Thread Richard W.M. Jones
On Mon, Oct 04, 2021 at 04:50:51PM +0200, Laszlo Ersek wrote: > On 10/04/21 11:59, Richard W.M. Jones wrote: > > It turns out that changing the qemu implementation is painful, > > particularly if we wish to maintain backwards compatibility of the > > command li

Re: [PATCH 0/1] vmx: Fix mapping

2021-10-04 Thread Richard W.M. Jones
/master/docs/vm-generation-id-across-hypervisors.txt On Thu, Sep 30, 2021 at 10:16:20AM +0100, Richard W.M. Jones wrote: > I was going to suggest something like: > > aa-bb-cc.. > or > aabbcc.. After thinking about this some more, the real implementation on Windows guest and hos

Re: [PATCH v3] nbd/server: Add --selinux-label option

2021-09-30 Thread Richard W.M. Jones
On Thu, Sep 30, 2021 at 02:00:11PM -0300, Willian Rampazzo wrote: > On Thu, Sep 30, 2021 at 5:55 AM Vladimir Sementsov-Ogievskiy > wrote: > > > > 9/30/21 11:47, Richard W.M. Jones wrote: > > > Under SELinux, Unix domain sockets have two labels. One is on th

Re: [PATCH 2/2] tests/docker: Fix fedora-i386-cross

2021-09-30 Thread Richard W.M. Jones
we incorrectly > use the wrong probing during meson. > > Cc: Alex Bennée > Cc: Paolo Bonzini > Cc: Daniel P. Berrangé > Cc: Richard W.M. Jones > Signed-off-by: Richard Henderson > --- > tests/docker/dockerfiles/fedora-i386-cross.docker | 5 +++-- > 1 file chang

Re: [PULL 00/20] NBD patches through 2021-09-27

2021-09-30 Thread Richard W.M. Jones
On Thu, Sep 30, 2021 at 10:27:45AM -0400, Richard Henderson wrote: > On 9/30/21 4:45 AM, Richard W.M. Jones wrote: > > PKG_CONFIG_LIBDIR=/usr/lib/pkgconfig ../configure --extra-cflags=-m32 > > --disable-vhost-user > > Not --extra-cflags, use --cpu=i386. That also bui

Re: [PATCH 0/1] vmx: Fix mapping

2021-09-30 Thread Richard W.M. Jones
On Thu, Sep 30, 2021 at 09:47:01AM +0100, Daniel P. Berrangé wrote: > On Thu, Sep 30, 2021 at 08:33:48AM +0100, Richard W.M. Jones wrote: > > I propose we deprecate the guid parameter in: > > > > -device vmgenid,guid=8987940a-0951-2cc5-e815-10634ff550b9,id=vmge

[PATCH v3] nbd/server: Add --selinux-label option

2021-09-30 Thread Richard W.M. Jones
: https://bugzilla.redhat.com/show_bug.cgi?id=1984938 Signed-off-by: Richard W.M. Jones Reviewed-by: Daniel P. Berrangé Signed-off-by: Eric Blake --- configure | 8 +++- meson.build | 10 - meson_options.txt

Re: [PULL 00/20] NBD patches through 2021-09-27

2021-09-30 Thread Richard W.M. Jones
On Wed, Sep 29, 2021 at 01:29:21PM -0500, Eric Blake wrote: > On Wed, Sep 29, 2021 at 05:03:08PM +0200, Paolo Bonzini wrote: > > On 29/09/21 15:58, Richard Henderson wrote: > > > > > > > /usr/bin/ld: /usr/lib64/libselinux.so: error adding symbols: file > > > in > > > > wrong format > >

Re: [PATCH 0/1] vmx: Fix mapping

2021-09-30 Thread Richard W.M. Jones
More data: I found a colleague who has a Hyper-V instance with a Windows guest and he helped me to understand how Hyper-V represents generation IDs. Hyper-V has had support for generation IDs since long before Microsoft proposed the feature for standardization. Originally (I think pre-2013)

Re: [PULL 00/20] NBD patches through 2021-09-27

2021-09-29 Thread Richard W.M. Jones
On Wed, Sep 29, 2021 at 01:29:21PM -0500, Eric Blake wrote: > On Wed, Sep 29, 2021 at 05:03:08PM +0200, Paolo Bonzini wrote: > > On 29/09/21 15:58, Richard Henderson wrote: > > > > > > > /usr/bin/ld: /usr/lib64/libselinux.so: error adding symbols: file > > > in > > > > wrong format > >

Re: [PATCH 0/1] vmx: Fix mapping

2021-09-29 Thread Richard W.M. Jones
On Wed, Sep 29, 2021 at 11:10:35AM +0100, Daniel P. Berrangé wrote: > On Wed, Sep 29, 2021 at 10:57:19AM +0100, Richard W.M. Jones wrote: > > Looking at the qemu code the problem IMHO is: > > > > https://gitlab.com/qemu-project/qemu/-/blob/6b54a31bf7b403672a798b6443b193

Re: [PATCH 0/1] vmx: Fix mapping

2021-09-29 Thread Richard W.M. Jones
On Wed, Sep 29, 2021 at 10:46:38AM +0100, Richard W.M. Jones wrote: > I don't know why we decided to use a GUID for this. The feature > itself (https://go.microsoft.com/fwlink/?LinkId=260709) defines it as > an 128 bit / 8 byte number. The only connection to GUIDs is the size. *cou

Re: [PATCH 0/1] vmx: Fix mapping

2021-09-29 Thread Richard W.M. Jones
On Wed, Sep 29, 2021 at 11:07:30AM +0100, Daniel P. Berrangé wrote: > I'm not sure if we actually need the full driver or not for testing > purposes. The the GenID is just in memory somewhere, and the somewhere > is reported via ACPI table entry. For QEMU its easy as the data is > exposed via

Re: [PATCH 0/1] vmx: Fix mapping

2021-09-29 Thread Richard W.M. Jones
Looking at the qemu code the problem IMHO is: https://gitlab.com/qemu-project/qemu/-/blob/6b54a31bf7b403672a798b6443b1930ae6c74dea/docs/specs/vmgenid.txt#L189 https://gitlab.com/qemu-project/qemu/-/blob/6b54a31bf7b403672a798b6443b1930ae6c74dea/hw/acpi/vmgenid.c#L37 This byte swapping makes no

Re: [PATCH 0/1] vmx: Fix mapping

2021-09-29 Thread Richard W.M. Jones
On Wed, Sep 29, 2021 at 10:33:43AM +0100, Daniel P. Berrangé wrote: > On Wed, Sep 29, 2021 at 10:20:44AM +0100, Richard W.M. Jones wrote: > > On Wed, Sep 29, 2021 at 10:01:55AM +0200, Michal Privoznik wrote: > > > Apparently, parsing vmx.genid is not as easy as

  1   2   3   4   5   6   7   8   9   10   >