Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-20 Thread Alexander Graf
On 20.12.24 14:31, Ani Sinha wrote: On Fri, Dec 20, 2024 at 5:03 PM Alexander Graf wrote: On 20.12.24 11:00, Ani Sinha wrote: Either add the I386 dependency or don't use PC_MACHINE, because on non-x86 targets PC_MACHINE(qdev_get_machine()) will crash. Ah this is where we have a disconnect.

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-20 Thread Ani Sinha
On Fri, 20 Dec, 2024, 7:01 pm Ani Sinha, wrote: > On Fri, Dec 20, 2024 at 5:03 PM Alexander Graf wrote: > > > > > > On 20.12.24 11:00, Ani Sinha wrote: > > >>> Either add the I386 dependency or don't use PC_MACHINE, because on > > >>> non-x86 targets PC_MACHINE(qdev_get_machine()) will crash. >

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-20 Thread Ani Sinha
On Fri, Dec 20, 2024 at 5:03 PM Alexander Graf wrote: > > > On 20.12.24 11:00, Ani Sinha wrote: > >>> Either add the I386 dependency or don't use PC_MACHINE, because on > >>> non-x86 targets PC_MACHINE(qdev_get_machine()) will crash. > >> Ah this is where we have a disconnect. I assumed that > >>>

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-20 Thread Alexander Graf
On 20.12.24 11:00, Ani Sinha wrote: Either add the I386 dependency or don't use PC_MACHINE, because on non-x86 targets PC_MACHINE(qdev_get_machine()) will crash. Ah this is where we have a disconnect. I assumed that pcms = PC_MACHINE(m_obj) would return NULL on non-x86. Seems a better way to

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-20 Thread Ani Sinha
> > Either add the I386 dependency or don't use PC_MACHINE, because on > > non-x86 targets PC_MACHINE(qdev_get_machine()) will crash. > > Ah this is where we have a disconnect. I assumed that > > pcms = PC_MACHINE(m_obj) > > would return NULL on non-x86. > > Seems a better way to do this (as is don

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-19 Thread Ani Sinha
On Thu, Dec 19, 2024 at 10:46 PM Philippe Mathieu-Daudé wrote: > > On 19/12/24 18:08, Ani Sinha wrote: > > > > > > On Thu, 19 Dec, 2024, 10:21 pm Philippe Mathieu-Daudé, > > mailto:phi...@linaro.org>> wrote: > > > > On 19/12/24 17:16, Ani Sinha wrote: > > > > > > > > > On Thu, 1

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-19 Thread Philippe Mathieu-Daudé
On 19/12/24 18:08, Ani Sinha wrote: On Thu, 19 Dec, 2024, 10:21 pm Philippe Mathieu-Daudé, mailto:phi...@linaro.org>> wrote: On 19/12/24 17:16, Ani Sinha wrote: > > > On Thu, 19 Dec, 2024, 9:22 pm Philippe Mathieu-Daudé, mailto:phi...@linaro.org> >

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-19 Thread Ani Sinha
On Thu, 19 Dec, 2024, 10:21 pm Philippe Mathieu-Daudé, wrote: > On 19/12/24 17:16, Ani Sinha wrote: > > > > > > On Thu, 19 Dec, 2024, 9:22 pm Philippe Mathieu-Daudé, > > wrote: > > > > On 16/12/24 12:48, Ani Sinha wrote: > > > > > diff --git a/hw/misc/meson.bui

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-19 Thread Philippe Mathieu-Daudé
On 19/12/24 17:16, Ani Sinha wrote: On Thu, 19 Dec, 2024, 9:22 pm Philippe Mathieu-Daudé, > wrote: On 16/12/24 12:48, Ani Sinha wrote: > diff --git a/hw/misc/meson.build b/hw/misc/meson.build > index d02d96e403..4c5bdb0de2 100644 > --- a/hw/misc/m

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-19 Thread Philippe Mathieu-Daudé
On 16/12/24 12:48, Ani Sinha wrote: diff --git a/hw/misc/meson.build b/hw/misc/meson.build index d02d96e403..4c5bdb0de2 100644 --- a/hw/misc/meson.build +++ b/hw/misc/meson.build @@ -148,6 +148,8 @@ specific_ss.add(when: 'CONFIG_MAC_VIA', if_true: files('mac_via.c')) specific_ss.add(when: 'CO

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-19 Thread Marc-André Lureau
Hi On Thu, Dec 19, 2024 at 2:03 PM Philippe Mathieu-Daudé wrote: > >>> +static const TypeInfo vmfwupdate_device_info = { > >>> +.name = TYPE_VMFWUPDATE, > >>> +.parent= TYPE_DEVICE, > >> > >> What is the qdev API used here? Why not use a plain object? > > > > I wrote this

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-19 Thread Ani Sinha
On Thu, Dec 19, 2024 at 6:25 PM Marc-André Lureau wrote: > > Hi > > On Thu, Dec 19, 2024 at 2:03 PM Philippe Mathieu-Daudé > wrote: > > >>> +static const TypeInfo vmfwupdate_device_info = { > > >>> +.name = TYPE_VMFWUPDATE, > > >>> +.parent= TYPE_DEVICE, > > >> > > >> Wha

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-19 Thread Ani Sinha
On Thu, 19 Dec, 2024, 9:22 pm Philippe Mathieu-Daudé, wrote: > On 16/12/24 12:48, Ani Sinha wrote: > > > diff --git a/hw/misc/meson.build b/hw/misc/meson.build > > index d02d96e403..4c5bdb0de2 100644 > > --- a/hw/misc/meson.build > > +++ b/hw/misc/meson.build > > @@ -148,6 +148,8 @@ specific_ss.a

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-19 Thread Ani Sinha
On Thu, 19 Dec, 2024, 9:16 pm Philippe Mathieu-Daudé, wrote: > On 19/12/24 15:07, Ani Sinha wrote: > > On Thu, Dec 19, 2024 at 6:25 PM Marc-André Lureau > > wrote: > >> > >> Hi > >> > >> On Thu, Dec 19, 2024 at 2:03 PM Philippe Mathieu-Daudé > >> wrote: > >> +static const TypeInfo vmfwupdat

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-19 Thread Philippe Mathieu-Daudé
On 19/12/24 15:07, Ani Sinha wrote: On Thu, Dec 19, 2024 at 6:25 PM Marc-André Lureau wrote: Hi On Thu, Dec 19, 2024 at 2:03 PM Philippe Mathieu-Daudé wrote: +static const TypeInfo vmfwupdate_device_info = { +.name = TYPE_VMFWUPDATE, +.parent= TYPE_DEVICE, What is

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-19 Thread Philippe Mathieu-Daudé
On 19/12/24 10:35, Ani Sinha wrote: On 18 Dec 2024, at 11:13 PM, Philippe Mathieu-Daudé wrote: On 16/12/24 12:48, Ani Sinha wrote: VM firmware update is a mechanism where the virtual machines can use their preferred and trusted firmware image in their execution environment without having to dep

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-19 Thread Ani Sinha
> On 17 Dec 2024, at 8:51 PM, Gerd Hoffman wrote: > > Hi, > >> +Fw-cfg Files >> + >> + >> +Guests drive vmfwupdate through special ``fw-cfg`` files that control its >> flow >> +followed by a standard system reset operation. When vmfwupdate is available, >> +it provides the follo

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-19 Thread Ani Sinha
> On 18 Dec 2024, at 11:13 PM, Philippe Mathieu-Daudé wrote: > > On 16/12/24 12:48, Ani Sinha wrote: >> VM firmware update is a mechanism where the virtual machines can use their >> preferred and trusted firmware image in their execution environment without >> having to depend on a untrusted p

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-18 Thread Philippe Mathieu-Daudé
On 16/12/24 12:48, Ani Sinha wrote: VM firmware update is a mechanism where the virtual machines can use their preferred and trusted firmware image in their execution environment without having to depend on a untrusted party to provide the firmware bundle. This is particularly useful for confiden

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-17 Thread Gerd Hoffman
Hi, > +Fw-cfg Files > + > + > +Guests drive vmfwupdate through special ``fw-cfg`` files that control its > flow > +followed by a standard system reset operation. When vmfwupdate is available, > +it provides the following ``fw-cfg`` files: > + > +* ``vmfwupdate/cap`` (``u64``) - Read

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-17 Thread Philippe Mathieu-Daudé
On 17/12/24 12:09, Ani Sinha wrote: On 17 Dec 2024, at 4:11 PM, Philippe Mathieu-Daudé wrote: On 17/12/24 11:06, Ani Sinha wrote: On 16 Dec 2024, at 8:35 PM, Philippe Mathieu-Daudé wrote: Hi Ani, +static void vmfwupdate_device_class_init(ObjectClass *klass, void *data) +{ +DeviceC

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-17 Thread Ani Sinha
> On 17 Dec 2024, at 4:11 PM, Philippe Mathieu-Daudé wrote: > > On 17/12/24 11:06, Ani Sinha wrote: >>> On 16 Dec 2024, at 8:35 PM, Philippe Mathieu-Daudé >>> wrote: >>> >>> Hi Ani, >>> >>> On 16/12/24 12:48, Ani Sinha wrote: VM firmware update is a mechanism where the virtual machine

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-17 Thread Philippe Mathieu-Daudé
On 17/12/24 11:06, Ani Sinha wrote: On 16 Dec 2024, at 8:35 PM, Philippe Mathieu-Daudé wrote: Hi Ani, On 16/12/24 12:48, Ani Sinha wrote: VM firmware update is a mechanism where the virtual machines can use their preferred and trusted firmware image in their execution environment without h

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-17 Thread Ani Sinha
> On 16 Dec 2024, at 8:35 PM, Philippe Mathieu-Daudé wrote: > > Hi Ani, > > On 16/12/24 12:48, Ani Sinha wrote: >> VM firmware update is a mechanism where the virtual machines can use their >> preferred and trusted firmware image in their execution environment without >> having to depend on a

Re: [PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-16 Thread Philippe Mathieu-Daudé
Hi Ani, On 16/12/24 12:48, Ani Sinha wrote: VM firmware update is a mechanism where the virtual machines can use their preferred and trusted firmware image in their execution environment without having to depend on a untrusted party to provide the firmware bundle. This is particularly useful for

[PATCH v2] hw/misc/vmfwupdate: Introduce hypervisor fw-cfg interface support

2024-12-16 Thread Ani Sinha
VM firmware update is a mechanism where the virtual machines can use their preferred and trusted firmware image in their execution environment without having to depend on a untrusted party to provide the firmware bundle. This is particularly useful for confidential virtual machines that are deploye