arch: Initialize usbhost_connection_s directly
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
This commit is contained in:
parent
148c544759
commit
8a8e115623
@ -576,7 +576,11 @@ static struct imxrt_ehci_s g_ehci =
|
||||
|
||||
/* This is the connection/enumeration interface */
|
||||
|
||||
static struct usbhost_connection_s g_ehciconn;
|
||||
static struct usbhost_connection_s g_ehciconn =
|
||||
{
|
||||
.wait = imxrt_wait,
|
||||
.enumerate = imxrt_enumerate,
|
||||
};
|
||||
|
||||
/* Maps USB chapter 9 speed to EHCI speed */
|
||||
|
||||
@ -5332,10 +5336,6 @@ struct usbhost_connection_s *imxrt_ehci_initialize(int controller)
|
||||
|
||||
usbhost_vtrace1(EHCI_VTRACE1_INIITIALIZED, 0);
|
||||
|
||||
/* Initialize and return the connection interface */
|
||||
|
||||
g_ehciconn.wait = imxrt_wait;
|
||||
g_ehciconn.enumerate = imxrt_enumerate;
|
||||
return &g_ehciconn;
|
||||
}
|
||||
|
||||
|
@ -597,7 +597,11 @@ static struct kinetis_ehci_s g_ehci =
|
||||
|
||||
/* This is the connection/enumeration interface */
|
||||
|
||||
static struct usbhost_connection_s g_ehciconn;
|
||||
static struct usbhost_connection_s g_ehciconn =
|
||||
{
|
||||
.wait = kinetis_wait,
|
||||
.enumerate = kinetis_enumerate,
|
||||
};
|
||||
|
||||
/* Maps USB chapter 9 speed to EHCI speed */
|
||||
|
||||
@ -5398,10 +5402,6 @@ struct usbhost_connection_s *kinetis_ehci_initialize(int controller)
|
||||
|
||||
usbhost_vtrace1(EHCI_VTRACE1_INIITIALIZED, 0);
|
||||
|
||||
/* Initialize and return the connection interface */
|
||||
|
||||
g_ehciconn.wait = kinetis_wait;
|
||||
g_ehciconn.enumerate = kinetis_enumerate;
|
||||
return &g_ehciconn;
|
||||
}
|
||||
|
||||
|
@ -574,7 +574,11 @@ static struct lpc31_ehci_s g_ehci =
|
||||
|
||||
/* This is the connection/enumeration interface */
|
||||
|
||||
static struct usbhost_connection_s g_ehciconn;
|
||||
static struct usbhost_connection_s g_ehciconn =
|
||||
{
|
||||
.wait = lpc31_wait,
|
||||
.enumerate = lpc31_enumerate,
|
||||
};
|
||||
|
||||
/* Maps USB chapter 9 speed to EHCI speed */
|
||||
|
||||
@ -5436,10 +5440,6 @@ struct usbhost_connection_s *lpc31_ehci_initialize(int controller)
|
||||
up_enable_irq(LPC31_IRQ_USBOTG); /* enable USB interrupt */
|
||||
usbhost_vtrace1(EHCI_VTRACE1_INIITIALIZED, 0);
|
||||
|
||||
/* Initialize and return the connection interface */
|
||||
|
||||
g_ehciconn.wait = lpc31_wait;
|
||||
g_ehciconn.enumerate = lpc31_enumerate;
|
||||
return &g_ehciconn;
|
||||
}
|
||||
|
||||
|
@ -564,7 +564,11 @@ static struct lpc43_ehci_s g_ehci =
|
||||
|
||||
/* This is the connection/enumeration interface */
|
||||
|
||||
static struct usbhost_connection_s g_ehciconn;
|
||||
static struct usbhost_connection_s g_ehciconn =
|
||||
{
|
||||
.wait = lpc43_wait,
|
||||
.enumerate = lpc43_enumerate,
|
||||
};
|
||||
|
||||
/* Maps USB chapter 9 speed to EHCI speed */
|
||||
|
||||
@ -5236,10 +5240,6 @@ struct usbhost_connection_s *lpc43_ehci_initialize(int controller)
|
||||
up_enable_irq(LPC43M4_IRQ_USB0); /* enable USB interrupt */
|
||||
usbhost_vtrace1(EHCI_VTRACE1_INIITIALIZED, 0);
|
||||
|
||||
/* Initialize and return the connection interface */
|
||||
|
||||
g_ehciconn.wait = lpc43_wait;
|
||||
g_ehciconn.enumerate = lpc43_enumerate;
|
||||
return &g_ehciconn;
|
||||
}
|
||||
|
||||
|
@ -444,7 +444,11 @@ static struct sam_ehci_s g_ehci =
|
||||
|
||||
/* This is the connection/enumeration interface */
|
||||
|
||||
static struct usbhost_connection_s g_ehciconn;
|
||||
static struct usbhost_connection_s g_ehciconn =
|
||||
{
|
||||
.wait = sam_wait,
|
||||
.enumerate = sam_enumerate,
|
||||
};
|
||||
|
||||
/* Maps USB chapter 9 speed to EHCI speed */
|
||||
|
||||
@ -5177,10 +5181,6 @@ struct usbhost_connection_s *sam_ehci_initialize(int controller)
|
||||
up_enable_irq(SAM_IRQ_UHPHS); /* enable USB interrupt */
|
||||
usbhost_vtrace1(EHCI_VTRACE1_INIITIALIZED, 0);
|
||||
|
||||
/* Initialize and return the connection interface */
|
||||
|
||||
g_ehciconn.wait = sam_wait;
|
||||
g_ehciconn.enumerate = sam_enumerate;
|
||||
return &g_ehciconn;
|
||||
}
|
||||
|
||||
|
@ -469,7 +469,11 @@ static struct sam_ohci_s g_ohci =
|
||||
|
||||
/* This is the connection/enumeration interface */
|
||||
|
||||
static struct usbhost_connection_s g_ohciconn;
|
||||
static struct usbhost_connection_s g_ohciconn =
|
||||
{
|
||||
.wait = sam_wait,
|
||||
.enumerate = sam_enumerate,
|
||||
};
|
||||
|
||||
/* This is a free list of EDs and TD buffers */
|
||||
|
||||
@ -4201,10 +4205,6 @@ struct usbhost_connection_s *sam_ohci_initialize(int controller)
|
||||
|
||||
usbhost_vtrace1(OHCI_VTRACE1_INITIALIZED, 0);
|
||||
|
||||
/* Initialize and return the connection interface */
|
||||
|
||||
g_ohciconn.wait = sam_wait;
|
||||
g_ohciconn.enumerate = sam_enumerate;
|
||||
return &g_ohciconn;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user