From: Chris Zankel Date: Sun, 5 Aug 2007 18:24:13 +0000 (-0700) Subject: [XTENSA] Add typecast macro for constants X-Git-Tag: v2.6.23-rc7~43^2~7 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=24a9ab7fa143498802b35c66de10cc3cfdac2c51;p=linux-2.6 [XTENSA] Add typecast macro for constants Add macros (__XTENSA_UL and __XTENSA_UL_CONST) for typecasting constants. Signed-off-by: Chris Zankel --- diff --git a/include/asm-xtensa/processor.h b/include/asm-xtensa/processor.h index 4feb9f7f35..35145bcd96 100644 --- a/include/asm-xtensa/processor.h +++ b/include/asm-xtensa/processor.h @@ -33,7 +33,7 @@ * the 1 GB requirement applies to the stack as well. */ -#define TASK_SIZE 0x40000000 +#define TASK_SIZE __XTENSA_UL_CONST(0x40000000) /* * General exception cause assigned to debug exceptions. Debug exceptions go diff --git a/include/asm-xtensa/types.h b/include/asm-xtensa/types.h index 9d99a8e9e3..f1e84526f9 100644 --- a/include/asm-xtensa/types.h +++ b/include/asm-xtensa/types.h @@ -11,6 +11,15 @@ #ifndef _XTENSA_TYPES_H #define _XTENSA_TYPES_H + +#ifdef __ASSEMBLY__ +# define __XTENSA_UL(x) (x) +# define __XTENSA_UL_CONST(x) x +#else +# define __XTENSA_UL(x) ((unsigned long)(x)) +# define __XTENSA_UL_CONST(x) x##UL +#endif + #ifndef __ASSEMBLY__ typedef unsigned short umode_t;