Hi,

> From: Gerd Hoffmann [mailto:kra...@redhat.com]
> Sent: Friday, September 05, 2014 5:06 PM
> Subject: Re: [PATCH v7 18/28] host-libusb: remove bootindex property from
> qdev to qom
> 
> > +static void usb_host_instance_init(Object *obj)
> > +{
> > +    USBDevice *udev = USB_DEVICE(obj);
> > +    USBHostDevice *s = USB_HOST_DEVICE(udev);
> > +
> > +    device_add_bootindex_property(obj, &s->bootindex,
> > +                                  "bootindex", NULL,
> > +                                  &udev->qdev, NULL);
> > +    object_property_set_int(obj, -1, "bootindex", NULL);
> 
> I think the object_property_set_int() call can be moved to
> device_add_bootindex_property, so there is no need to duplicate the call
> to init bootindex with -1 in all devices.
> 
Good idea. Thanks! Will fix this.

Best regards,
-Gonglei

Reply via email to