launchpad-icdi: Cleaned up and fixed some C89-isms

This commit is contained in:
dragonmux 2022-06-15 22:09:18 -04:00 committed by Piotr Esden-Tempski
parent 0139a349ab
commit baf84c9eb4
2 changed files with 6 additions and 13 deletions

View File

@ -47,11 +47,10 @@ uint32_t platform_time_ms(void)
return time_ms;
}
void
platform_init(void)
void platform_init(void)
{
int i;
for(i=0; i<1000000; i++);
for (int i = 0; i < 1000000; ++i)
continue;
rcc_sysclk_config(OSCSRC_MOSC, XTAL_16M, PLL_DIV_80MHZ);
@ -85,8 +84,7 @@ platform_init(void)
cdcacm_init();
usb_enable_interrupts(USB_INT_RESET | USB_INT_DISCON |
USB_INT_RESUME | USB_INT_SUSPEND,
0xff, 0xff);
USB_INT_RESUME | USB_INT_SUSPEND, 0xff, 0xff);
}
void platform_nrst_set_val(bool assert)
@ -132,9 +130,7 @@ char *serial_no_read(char *s)
return s;
}
void platform_request_boot(void)
{
}
void platform_request_boot(void) { }
void platform_max_frequency_set(uint32_t freq)
{

View File

@ -111,9 +111,6 @@ inline static uint8_t gpio_get(uint32_t port, uint8_t pin) {
#define disconnect_usb() do { usbd_disconnect(usbdev,1); nvic_disable_irq(USB_IRQ);} while(0)
static inline int platform_hwversion(void)
{
return 0;
}
static inline int platform_hwversion(void) { return 0; }
#endif