qemu-ppc
[Top][All Lists]
Advanced

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

Re: [Qemu-ppc] [Qemu-devel] [PATCH 05/17] pseries: savevm support for XI


From: Paolo Bonzini
Subject: Re: [Qemu-ppc] [Qemu-devel] [PATCH 05/17] pseries: savevm support for XICS interrupt controller
Date: Mon, 15 Jul 2013 15:17:53 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130514 Thunderbird/17.0.6

Il 15/07/2013 15:13, Alexey Kardashevskiy ha scritto:
>> > 
>> > The vmstate's pre_save and post_load functions can dispatch to a method
>> > in the subclass.  Again, i8259 does exactly what you want:
>> > 
>> > static void pic_dispatch_pre_save(void *opaque)
>> > {
>> >     PICCommonState *s = opaque;
>> >     PICCommonClass *info = PIC_COMMON_GET_CLASS(s);
>> > 
>> >     if (info->pre_save) {
>> >         info->pre_save(s);
>> >     }
>> > }
> And this is not a hack. Hm. I do not get it. There is even INTERFACE_CLASS
> defined but noone is using it. Instead you are proposing to add callbacks
> called from callbacks. And this is all for not having dev==NULL in
> vmstate_register()... Gosh :(

This is not about having dev!=NULL.  It is about not using
vmstate_register at all.

Paolo



reply via email to

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