From 0fd53909b0bfd5fb5b752f4cb87b5633e9b451d5 Mon Sep 17 00:00:00 2001 From: Kelvin Lawson Date: Sun, 21 Feb 2010 16:12:31 +0000 Subject: [PATCH] AVR port: Improve description of thread_shell() location on ATmegas with 2 byte program counters. --- ports/avr/atomport.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/ports/avr/atomport.c b/ports/avr/atomport.c index ecdbf16..86e67fa 100644 --- a/ports/avr/atomport.c +++ b/ports/avr/atomport.c @@ -190,9 +190,10 @@ void archThreadContextInit (ATOM_TCB *tcb_ptr, void *stack_top, void (*entry_poi * Devices with 3 byte program counters (e.g. Atmega25x, Xmega) * must have 3 bytes stacked for the entry point. In GCC * function pointers are still 16-bits, however, so we cannot - * actually pass entry points at > 64KB in memory space. This - * means that the thread_shell() function must be located - * in the bottom 64KB. You may need to modify linker scripts to + * actually pass entry points at > 64K in instruction space + * (128KB in real terms) and just set the top byte to zero here. + * This means that the thread_shell() function must be located + * in the bottom 128KB. You may need to modify linker scripts to * force this. */ #ifdef __AVR_3_BYTE_PC__