aboutsummaryrefslogtreecommitdiff
path: root/hw/usb-musb.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/usb-musb.c')
-rw-r--r--hw/usb-musb.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/hw/usb-musb.c b/hw/usb-musb.c
index 9efe7a6344..592d3e67f4 100644
--- a/hw/usb-musb.c
+++ b/hw/usb-musb.c
@@ -261,6 +261,10 @@
static void musb_attach(USBPort *port, USBDevice *dev);
+static USBPortOps musb_port_ops = {
+ .attach = musb_attach,
+};
+
typedef struct {
uint16_t faddr[2];
uint8_t haddr[2];
@@ -343,7 +347,7 @@ struct MUSBState {
}
usb_bus_new(&s->bus, NULL /* FIXME */);
- usb_register_port(&s->bus, &s->port, s, 0, NULL, musb_attach);
+ usb_register_port(&s->bus, &s->port, s, 0, NULL, &musb_port_ops);
return s;
}