/* Initialize the USB device controller hardware of the STM32.  */
static usbd_device * st_usbfs_v1_usbd_init(void)
/* Initialize the USB device controller hardware of the STM32.  */
static usbd_device * st_usbfs_v1_usbd_init(void)
{
	rcc_periph_clock_enable(RCC_USB);
	SET_REG(USB_CNTR_REG, 0);
	SET_REG(USB_BTABLE_REG, 0);
	SET_REG(USB_ISTR_REG, 0);
	SET_REG(USB_CNTR_REG, USB_CNTR_RESETM | USB_CNTR_CTRM |
		USB_CNTR_SUSPM | USB_CNTR_WKUPM);
	return &st_usbfs_dev;
}