qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [Qemu-ppc] [PATCH v7 1/3] Add USB option in machine opt


From: Li Zhang
Subject: Re: [Qemu-devel] [Qemu-ppc] [PATCH v7 1/3] Add USB option in machine options
Date: Wed, 15 Aug 2012 13:44:28 +0800

On Wed, Aug 15, 2012 at 10:57 AM, David Gibson <address@hidden> wrote:
> On Wed, Aug 15, 2012 at 10:50:04AM +0800, Li Zhang wrote:
>> On Wed, Aug 15, 2012 at 9:47 AM, David Gibson <address@hidden> wrote:
>> > On Wed, Aug 15, 2012 at 09:24:34AM +0800, Li Zhang wrote:
>> >> On Wed, Aug 15, 2012 at 8:09 AM, Benjamin Herrenschmidt
>> >> <address@hidden> wrote:
>> >> > On Wed, 2012-08-15 at 09:10 +1000, David Gibson wrote:
>> >> >> > I see. I will redo this patch. Send out it later. :)
>> >> >> > Thanks for your comments.
>> >> >>
>> >> >> When you do that, please also change the default to make spapr _not_
>> >> >> have usb.
>> >> >
>> >> > FYI, I originally asked for USB as default ... however it looks like at
>> >> > this stage the price (performance) is too high so either make it default
>> >> > to OFF, or make it default to ON if and only if VGA is also enabled.
>> >> >
>> >> Got it, I change the default as false, and when VGA is enabled, set
>> >> USB option as true.
>> >
>> > Not quite, actually.  The default should depend on VGA, but the
>> > explicit usb= option should always override that.  Having VGA without
>> > USB would be unusual, but it should be possible if you specify it
>> > explicitly.
>> >
>> Right, explicit usb= option will override the value.
>> I think we can set the usb option value when no usb option is specified.
>> For example, we use -machine type=pseries  without usb= option.
>>
>> I am considering as the following:
>>
>> if (vga_enabled) {
>>     set_usb_option(true)
>> }
>
> No, this will override the option given on the command line.
Oh, I didn't realize that.
>
>> if (usb_enabled(false)) {  //If vga is enabled and "-machine
>> type=pseries" is specified, it will get true.
>>     pci_create_simple(ohci)
>> }
>
> It's much easier than this, you just want
>         if (usb_enabled(vga_enabled))
This is better than mine. :)
It seems that this patch needs to work with VGA patch together. :)
I need to modify as that. :)

>
> --
> David Gibson                    | I'll have my music baroque, and my code
> david AT gibson.dropbear.id.au  | minimalist, thank you.  NOT _the_ _other_
>                                 | _way_ _around_!
> http://www.ozlabs.org/~dgibson
>



-- 

Best Regards
-Li



reply via email to

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