chip/stm32/usb_dwc_console.c: Format with clang-format
BRANCH=none
TEST=none
@@ -61,7 +61,6 @@ static uint8_t ep_buf_rx[USB_MAX_PACKET_SIZE];
static struct queue const tx_q = QUEUE_NULL(256, uint8_t);
static struct queue const rx_q = QUEUE_NULL(USB_MAX_PACKET_SIZE, uint8_t);
-
struct dwc_usb_ep ep_console_ctl = {
.max_packet = USB_MAX_PACKET_SIZE,
.tx_fifo = USB_EP_CONSOLE,
@@ -76,8 +75,6 @@ struct dwc_usb_ep ep_console_ctl = {
.in_databuffer_max = sizeof(ep_buf_rx),
};
-
-
/* Let the USB HW IN-to-host FIFO transmit some bytes */
static void usb_enable_tx(int len)
{
@@ -162,8 +159,7 @@ static void con_ep_rx(void)
/* Bytes received decrement DOEPTSIZ XFERSIZE */
if (GR_USB_DOEPINT(USB_EP_CONSOLE) & DOEPINT_XFERCOMPL) {
ep->out_pending =
- ep->max_packet -
- (GR_USB_DOEPTSIZ(USB_EP_CONSOLE) &
+ ep->max_packet - (GR_USB_DOEPTSIZ(USB_EP_CONSOLE) &
GC_USB_DOEPTSIZ1_XFERSIZE_MASK);
}
@@ -193,8 +189,8 @@ static void tx_fifo_handler(void)
if (!tx_fifo_is_ready())
return;
- count = QUEUE_REMOVE_UNITS(&tx_q,
- ep->in_databuffer, USB_MAX_PACKET_SIZE);
+ count = QUEUE_REMOVE_UNITS(&tx_q, ep->in_databuffer,
+ USB_MAX_PACKET_SIZE);
if (count)
usb_enable_tx(count);
}
@@ -232,7 +228,6 @@ static void ep_event(enum usb_ep_event evt)
usb_enable_rx(USB_MAX_PACKET_SIZE);
}
-
USB_DECLARE_EP(USB_EP_CONSOLE, con_ep_tx, con_ep_rx, ep_event);
static int usb_wait_console(void)
@@ -274,8 +269,7 @@ static int usb_wait_console(void)
}
static int __tx_char(void *context, int c)
{
- struct queue *state =
- (struct queue *) context;
+ struct queue *state = (struct queue *)context;
if (c == '\n' && __tx_char(state, '\r'))
return 1;
