All of lore.kernel.org
 help / color / mirror / Atom feed
From: BB <shentey@gmail.com>
To: "Philippe Mathieu-Daudé" <f4bug@amsat.org>,
	"Peter Maydell" <peter.maydell@linaro.org>
Cc: "Hervé Poussineau" <hpoussin@reactos.org>,
	qemu-devel@nongnu.org, "Aurelien Jarno" <aurelien@aurel32.net>,
	"Michael S. Tsirkin" <mst@redhat.com>
Subject: Re: [PATCH 3/3] isa/piix4: Resolve global variables
Date: Thu, 10 Feb 2022 00:16:34 +0100	[thread overview]
Message-ID: <3DD424F7-FC1C-471E-A5E5-1E06783D7254@gmail.com> (raw)
In-Reply-To: <b21fefc6-a7f6-c101-5f1f-99cd3191933b@amsat.org>

Am 30. Januar 2022 23:53:42 MEZ schrieb "Philippe Mathieu-Daudé" <f4bug@amsat.org>:
>On 14/1/22 14:36, Peter Maydell wrote:
>> On Wed, 12 Jan 2022 at 22:02, Bernhard Beschow <shentey@gmail.com> wrote:
>>>
>>> Now that piix4_set_irq's opaque parameter references own PIIX4State,
>>> piix4_dev becomes redundant and pci_irq_levels can be moved into PIIX4State.
>>>
>>> Signed-off-by: Bernhard Beschow <shentey@gmail.com>
>>> ---
>>>   hw/isa/piix4.c                | 22 +++++++++-------------
>>>   include/hw/southbridge/piix.h |  2 --
>>>   2 files changed, 9 insertions(+), 15 deletions(-)
>>>
>>> diff --git a/hw/isa/piix4.c b/hw/isa/piix4.c
>>> index a31e9714cf..964e09cf7f 100644
>>> --- a/hw/isa/piix4.c
>>> +++ b/hw/isa/piix4.c
>>> @@ -39,14 +39,14 @@
>>>   #include "sysemu/runstate.h"
>>>   #include "qom/object.h"
>>>
>>> -PCIDevice *piix4_dev;
>>> -
>>>   struct PIIX4State {
>>>       PCIDevice dev;
>>>       qemu_irq cpu_intr;
>>>       qemu_irq *isa;
>>>       qemu_irq i8259[ISA_NUM_IRQS];
>>>
>>> +    int pci_irq_levels[PIIX_NUM_PIRQS];
>>> +
>> 
>> I wondered how we were migrating this state, and the answer
>> seems to be that we aren't (and weren't before, when it was
>> a global variable, so this is a pre-existing bug).
>
>Indeed the migrated VM starts with PCI IRQ levels zeroed.
>
>> Does the malta platform support migration save/load?
>
>Maybe a "best effort" support, but not versioned machines.
>
>> We should probably add this field to the vmstate struct
>> (which will be a migration compatibility break, which is OK
>> as the malta board isn't versioned.)
>
>Yeah good catch.
>
>Bernhard, do you mind adding it?

Sure, I'll give it a try. Shall I submit a v2 of this patch series then? If so, would it be ok to change the topic of the cover letter or would that be confusing?

Last but not least: How to treat the version_id and the version parameters of the new and existing fields?

Regards,

Bernhard.



  reply	other threads:[~2022-02-09 23:21 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-12 21:36 [PATCH 0/3] malta: Move PCI interrupt handling from gt64xxx to piix4 Bernhard Beschow
2022-01-12 21:36 ` [PATCH 1/3] " Bernhard Beschow
2022-01-30 22:34   ` Philippe Mathieu-Daudé via
2022-01-12 21:36 ` [PATCH 2/3] pci: Always pass own DeviceState to pci_map_irq_fn's Bernhard Beschow
2022-01-14 13:29   ` Peter Maydell
2022-01-30 22:36   ` Philippe Mathieu-Daudé via
2022-01-12 21:36 ` [PATCH 3/3] isa/piix4: Resolve global variables Bernhard Beschow
2022-01-14 13:36   ` Peter Maydell
2022-01-30 22:53     ` Philippe Mathieu-Daudé via
2022-02-09 23:16       ` BB [this message]
2022-02-10  7:18         ` Michael S. Tsirkin
2022-01-30 22:39   ` Philippe Mathieu-Daudé via
2022-01-13  9:24 ` [PATCH 0/3] malta: Move PCI interrupt handling from gt64xxx to piix4 Philippe Mathieu-Daudé
2022-01-13 11:22   ` Bernhard Beschow
2022-01-13 11:53     ` Philippe Mathieu-Daudé

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3DD424F7-FC1C-471E-A5E5-1E06783D7254@gmail.com \
    --to=shentey@gmail.com \
    --cc=aurelien@aurel32.net \
    --cc=f4bug@amsat.org \
    --cc=hpoussin@reactos.org \
    --cc=mst@redhat.com \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.