Skip to content

Commit

Permalink
usb-bus: remove "init" from USBDeviceClass struct
Browse files Browse the repository at this point in the history
All usb-bus devices are realized by realize(),
remove init callback function from USBDeviceClass struct.

Signed-off-by: Gonglei <arei.gonglei@huawei.com>
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
  • Loading branch information
gongleiarei authored and kraxel committed Sep 23, 2014
1 parent df9bb66 commit bd2ba27
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 4 deletions.
2 changes: 0 additions & 2 deletions hw/usb/bus.c
Expand Up @@ -113,8 +113,6 @@ static void usb_device_realize(USBDevice *dev, Error **errp)

if (klass->realize) {
klass->realize(dev, errp);
} else if (klass->init) {
klass->init(dev);
}
}

Expand Down
2 changes: 0 additions & 2 deletions include/hw/usb.h
Expand Up @@ -273,8 +273,6 @@ typedef void (*USBDeviceUnrealize)(USBDevice *dev, Error **errp);
typedef struct USBDeviceClass {
DeviceClass parent_class;

int (*init)(USBDevice *dev);

USBDeviceRealize realize;
USBDeviceUnrealize unrealize;

Expand Down

0 comments on commit bd2ba27

Please sign in to comment.