summaryrefslogtreecommitdiff
path: root/nuttx/include/nuttx/compiler.h
diff options
context:
space:
mode:
authorpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2011-07-01 19:08:04 +0000
committerpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2011-07-01 19:08:04 +0000
commit00b2545e9e3cc760255aa7b4fc953ad5ab97ba62 (patch)
tree90f908d15691555fdf19c21eeae7b55187b73803 /nuttx/include/nuttx/compiler.h
parent6e09d7aab47a47e36f56d9b33bd6e87e96e2af2c (diff)
downloadnuttx-00b2545e9e3cc760255aa7b4fc953ad5ab97ba62.tar.gz
nuttx-00b2545e9e3cc760255aa7b4fc953ad5ab97ba62.tar.bz2
nuttx-00b2545e9e3cc760255aa7b4fc953ad5ab97ba62.zip
Add support for accessing printf, sprintf, puts, etc. strings that do not lie in the MCU data space
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@3738 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx/include/nuttx/compiler.h')
-rw-r--r--nuttx/include/nuttx/compiler.h21
1 files changed, 19 insertions, 2 deletions
diff --git a/nuttx/include/nuttx/compiler.h b/nuttx/include/nuttx/compiler.h
index c44ff329e..c672054dd 100644
--- a/nuttx/include/nuttx/compiler.h
+++ b/nuttx/include/nuttx/compiler.h
@@ -103,7 +103,7 @@
* pointers are 16-bits.
*/
-#if defined(__m32c__) || defined(__AVR__)
+#if defined(__m32c__)
/* Select the small, 16-bit addressing model */
# define CONFIG_SMALL_MEMORY 1
@@ -116,7 +116,24 @@
# undef CONFIG_PTR_IS_NOT_INT
-/* Handle cases where sizeof(int) may or may not be 16-bits */
+#elif defined(__AVR__)
+/* Select the small, 16-bit addressing model */
+
+# define CONFIG_SMALL_MEMORY 1
+
+/* Long and int are not the same size */
+
+# define CONFIG_LONG_IS_NOT_INT 1
+
+/* Pointers and int are the same size */
+
+# undef CONFIG_PTR_IS_NOT_INT
+
+/* Uses a 32-bit FAR pointer only from accessing data outside of the 16-bit
+ * data space.
+ */
+
+# define CONFIG_HAVE_FARPOINTER 1
#elif defined(__mc68hc1x__)
/* Select the small, 16-bit addressing model */