qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH v2 07/10] piix3 piix4: Clean up use of cannot_in


From: Markus Armbruster
Subject: Re: [Qemu-devel] [PATCH v2 07/10] piix3 piix4: Clean up use of cannot_instantiate_with_device_add_yet
Date: Tue, 29 Oct 2013 18:37:12 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2 (gnu/linux)

Eric Blake <address@hidden> writes:

> On 10/29/2013 10:08 AM, address@hidden wrote:
>> From: Markus Armbruster <address@hidden>
>> 
>> A PIIX3/PIIX4 southbridge has multiple functions.  We model each
>> function as a separate qdev.  Two of them need some special wiring set
>> up in pc_init1() or mips_malta_init() to work: the ISA bridge at 01.0,
>> and the SMBus controller at 01.3.
>> 
>> The IDE controller at 01.1 (piix3-ide, piix3-ide-xen, piix4-ide) has
>> always had cannot_instantiate_with_device_add_yet set, but there is no
>> obvious reason why device_add could not work for them.  Drop it.
>
>> +++ b/hw/acpi/piix4.c
>> @@ -508,9 +508,14 @@ static void piix4_pm_class_init(ObjectClass *klass, 
>> void *data)
>>      k->revision = 0x03;
>>      k->class_id = PCI_CLASS_BRIDGE_OTHER;
>>      dc->desc = "PM";
>> -    dc->cannot_instantiate_with_device_add_yet = true; /* FIXME explain why 
>> */
>> +    dc->cannot_instantiate_with_device_add_yet = true;
>>      dc->vmsd = &vmstate_acpi;
>>      dc->props = piix4_pm_properties;
>> +    /*
>> +     * Reason: part of PIIX4 southbridge, needs to be wired up,
>> +     * e.g. by mips_malta_init()
>> +     */
>> +    dc->cannot_instantiate_with_device_add_yet = true;
>
> Is it intentional that you initialize the field twice to the same value?

Nope, editing error.  Will fix, thanks!



reply via email to

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