From becc1d8b931e1ebdbde68f54ea909015bdd7ded2 Mon Sep 17 00:00:00 2001 From: Phillip Stevens Date: Sat, 11 Apr 2020 19:16:31 +1000 Subject: [PATCH] ATmegaxxx - match legacy whitespace --- portable/GCC/ATmegaxxxx/port.c | 14 +++++--------- portable/GCC/ATmegaxxxx/portmacro.h | 2 -- 2 files changed, 5 insertions(+), 11 deletions(-) diff --git a/portable/GCC/ATmegaxxxx/port.c b/portable/GCC/ATmegaxxxx/port.c index 1186791eb..c79e7a6fe 100644 --- a/portable/GCC/ATmegaxxxx/port.c +++ b/portable/GCC/ATmegaxxxx/port.c @@ -67,12 +67,6 @@ any details of its type. */ typedef void TCB_t; extern volatile TCB_t * volatile pxCurrentTCB; -/*-----------------------------------------------------------*/ -/* - * Perform hardware setup to enable ticks from timer compare match A. - */ -static void prvSetupTimerInterrupt( void ); - /*-----------------------------------------------------------*/ /** @@ -518,6 +512,11 @@ void wdt_interrupt_reset_enable (const uint8_t value) #endif /*-----------------------------------------------------------*/ +/* + * Perform hardware setup to enable ticks from relevant Timer. + */ +static void prvSetupTimerInterrupt( void ); +/*-----------------------------------------------------------*/ /* * See header file for description. @@ -541,7 +540,6 @@ uint16_t usAddress; /* The start of the task code will be popped off the stack last, so place it on first. */ - usAddress = ( uint16_t ) pxCode; *pxTopOfStack = ( StackType_t ) ( usAddress & ( uint16_t ) 0x00ff ); pxTopOfStack--; @@ -722,12 +720,10 @@ void vPortYieldFromTick( void ) __attribute__ ( ( hot, flatten, naked ) ); void vPortYieldFromTick( void ) { portSAVE_CONTEXT(); - if( xTaskIncrementTick() != pdFALSE ) { vTaskSwitchContext(); } - portRESTORE_CONTEXT(); __asm__ __volatile__ ( "ret" ); diff --git a/portable/GCC/ATmegaxxxx/portmacro.h b/portable/GCC/ATmegaxxxx/portmacro.h index 253f1379a..a9ac7b633 100644 --- a/portable/GCC/ATmegaxxxx/portmacro.h +++ b/portable/GCC/ATmegaxxxx/portmacro.h @@ -63,7 +63,6 @@ typedef uint8_t UBaseType_t; /*-----------------------------------------------------------*/ /* Critical section management. */ - #define portENTER_CRITICAL() __asm__ __volatile__ ( \ "in __tmp_reg__, __SREG__" "\n\t" \ "cli" "\n\t" \ @@ -81,7 +80,6 @@ typedef uint8_t UBaseType_t; #define portDISABLE_INTERRUPTS() __asm__ __volatile__ ( "cli" ::: "memory") #define portENABLE_INTERRUPTS() __asm__ __volatile__ ( "sei" ::: "memory") - /*-----------------------------------------------------------*/ /* Architecture specifics. */