diff options
| author | Simon Glass <sjg@chromium.org> | 2013-02-24 17:33:29 +0000 | 
|---|---|---|
| committer | Simon Glass <sjg@chromium.org> | 2013-02-28 19:09:24 -0800 | 
| commit | 8e169cc943fcf93dd803adc70433b2c587db8796 (patch) | |
| tree | f3328235d0fc652fc8df41468749d78451c4a8f0 /common/cmd_mem.c | |
| parent | ecdbf419f9c979cb6417df261c324c5beb63300d (diff) | |
| download | olio-uboot-2014.01-8e169cc943fcf93dd803adc70433b2c587db8796.tar.xz olio-uboot-2014.01-8e169cc943fcf93dd803adc70433b2c587db8796.zip | |
Move CONFIG_SYS_MEMTEST_SCRATCH #ifdef to top of file
This config effectively has a default value of 0, so add this setting
at the top of the code to remove an #ifdef in the C function.
Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'common/cmd_mem.c')
| -rw-r--r-- | common/cmd_mem.c | 8 | 
1 files changed, 4 insertions, 4 deletions
| diff --git a/common/cmd_mem.c b/common/cmd_mem.c index 95b49b210..50838a761 100644 --- a/common/cmd_mem.c +++ b/common/cmd_mem.c @@ -39,6 +39,10 @@  DECLARE_GLOBAL_DATA_PTR; +#ifndef CONFIG_SYS_MEMTEST_SCRATCH +#define CONFIG_SYS_MEMTEST_SCRATCH 0 +#endif +  static int mod_mem(cmd_tbl_t *, int, int, int, char * const []);  /* Display values from last command. @@ -641,11 +645,7 @@ static ulong mem_test_alt(ulong start_addr, ulong end_addr)  	vu_long temp;  	vu_long anti_pattern;  	vu_long num_words; -#if defined(CONFIG_SYS_MEMTEST_SCRATCH)  	vu_long *dummy = (vu_long *)CONFIG_SYS_MEMTEST_SCRATCH; -#else -	vu_long *dummy = NULL;	/* yes, this is address 0x0, not NULL */ -#endif  	static const ulong bitpattern[] = {  		0x00000001,	/* single bit */  		0x00000003,	/* two adjacent bits */ |