[sandbox] add propper sandbox detection
This patch adds a __SANDBOX__ define to identify compiling for the sandbox. When building for sandbox, don't use sync() workaround. Fixes this error for sandbox on PPC: CC common/memsize.o common/memsize.c:30:38: error: asm/io.h: No such file or directory common/memsize.c: In function 'get_ram_size': common/memsize.c:51: warning: implicit declaration of function 'sync' Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
This commit is contained in:
parent
b7e74539f8
commit
fb56fffbcb
|
@ -22,7 +22,7 @@
|
|||
*/
|
||||
|
||||
#include <config.h>
|
||||
#ifdef __PPC__
|
||||
#if defined (__PPC__) && !defined (__SANDBOX__)
|
||||
/*
|
||||
* At least on G2 PowerPC cores, sequential accesses to non-existent
|
||||
* memory must be synchronized.
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
|
||||
#ifndef __CONFIG_H
|
||||
#define __CONFIG_H
|
||||
|
||||
#define __SANDBOX__
|
||||
|
||||
#endif /* __CONFIG_H */
|
||||
|
|
Loading…
Reference in New Issue