qemu-s390x
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] hw/s390x: Restrict "loadparm" property to devices that can b


From: Thomas Huth
Subject: Re: [PATCH] hw/s390x: Restrict "loadparm" property to devices that can be used for booting
Date: Thu, 14 Nov 2024 13:39:23 +0100
User-agent: Mozilla Thunderbird

On 13/11/2024 15.49, Jared Rossi wrote:
...
Hi Thomas,

Thanks for putting this fix together.  As we previously discussed, I do agree
that my naive implementation of the “loadparm” property at the top-level
CcwDevice was not satisfactory, and certainly virtio-gpu and virtio-tablet
should not have a “loadparm.”

The reason I had not yet submitted a fix is that I’ve gotten some feedback from
the Libvirt side that suggests the CcwDevice implementation is not sufficient
in general.  Libvirt will require that non-ccw devices (e.g. scsi-hd) also
support per-device loadparm.  I do not yet know how to add that type of support
and given that we are in hard freeze I’m not sure it is possible now.

Obviously this is not ideal, and I truly do apologize for the confusion.

 Hi Jared,

yes, that scsi-hd problem is a little bit tricky, since it's common code that we should not "pollute" too much with s390x specific stuff, especially since we're in hard freeze now.

After staring at the code for quite a while, I think one option might be to just add a string "loadparm" property to the SCSI devices, that's just a simple two-line change to the common code. Patch suggestion can be found here:

 20241114122919.973930-1-thuth@redhat.com/">https://lore.kernel.org/qemu-devel/20241114122919.973930-1-thuth@redhat.com/

The only disadvantage is that this is now checking for valid characters in the string after the property has already been set, so it cannot prevent the setting of bad characters. But it still prints out an error message later, so I hope that is also still acceptable.

Let me know what you think about it!

 Thanks,
  Thomas




reply via email to

[Prev in Thread] Current Thread [Next in Thread]