Skip to content

Commit 0dfad2d

Browse files
rizlikdanielinux
authored andcommitted
hal: pic32cz: uart_deinit out from clock_restore block, nop asm volatile
1 parent 955b07c commit 0dfad2d

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

hal/pic32cz.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ static void pic32_delay_cnt(uint32_t ticks)
7777
{
7878
uint32_t i = 0;
7979
for (i = 0; i < ticks; i++) {
80-
__asm__("nop");
80+
__asm__ __volatile__("nop");
8181
}
8282
}
8383

@@ -159,11 +159,11 @@ void hal_init(void)
159159

160160
void hal_prepare_boot(void)
161161
{
162-
#ifdef WOLFBOOT_RESTORE_CLOCK
163162
#ifdef DEBUG_UART
164163
uart_deinit();
165164
#endif
166165

166+
#ifdef WOLFBOOT_RESTORE_CLOCK
167167
pic32_clock_reset();
168168

169169
if (!pic32_vreg_pll_was_enabled) {

0 commit comments

Comments
 (0)