drivers: usb_dc_mcux_ehci: remove unnecessary cast

Remove unnecessary cast, fix style.

Signed-off-by: Johann Fischer <j.fischer@phytec.de>
This commit is contained in:
Johann Fischer 2019-12-02 17:08:56 +01:00 committed by Carles Cufí
commit a6207db0f7

View file

@ -53,7 +53,7 @@ static usb_device_struct_t dev_data;
#if ((defined(USB_DEVICE_CONFIG_EHCI)) && (USB_DEVICE_CONFIG_EHCI > 0U))
/* EHCI device driver interface */
static const usb_device_controller_interface_struct_t s_UsbDeviceEhciInterface = {
static const usb_device_controller_interface_struct_t ehci_iface = {
USB_DeviceEhciInit, USB_DeviceEhciDeinit, USB_DeviceEhciSend,
USB_DeviceEhciRecv, USB_DeviceEhciCancel, USB_DeviceEhciControl
};
@ -77,7 +77,7 @@ int usb_dc_attach(void)
LOG_WRN("already attached");
return 0;
}
dev_data.interface = (const usb_device_controller_interface_struct_t *)(&s_UsbDeviceEhciInterface);
dev_data.interface = &ehci_iface;
if (kStatus_USB_Success != dev_data.interface->deviceInit(CONTROLLER_ID, &dev_data, &dev_data.controllerHandle)) {
return -EINVAL;
}