diff mbox

[U-Boot,4/5] Don't compile in large memory test function by default.

Message ID 20110704174526.GE3016@harvey-pc.matrox.com
State Changes Requested
Headers show

Commit Message

Christopher Harvey July 4, 2011, 5:45 p.m. UTC
Signed-off-by: Christopher Harvey <charvey@matrox.com>
---
 common/cmd_mem.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

Comments

Albert ARIBAUD July 7, 2011, 4:13 p.m. UTC | #1
Hi Christopher,

Le 04/07/2011 19:45, Christopher Harvey a écrit :
> Signed-off-by: Christopher Harvey<charvey@matrox.com>
> ---
>   common/cmd_mem.c |    5 +++++
>   1 files changed, 5 insertions(+), 0 deletions(-)
>
> diff --git a/common/cmd_mem.c b/common/cmd_mem.c
> index a5576aa..833af66 100644
> --- a/common/cmd_mem.c
> +++ b/common/cmd_mem.c
> @@ -610,6 +610,8 @@ int do_mem_loopw (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
>   }
>   #endif /* CONFIG_LOOPW */
>
> +#ifdef CONFIG_CMD_MTEST
> +
>   /*
>    * Perform a memory test. A more complete alternative test can be
>    * configured using CONFIG_SYS_ALT_MEMTEST. The complete test loops until
> @@ -965,6 +967,7 @@ int do_mem_mtest (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
>   	return 0;	/* not reached */
>   }
>
> +#endif /* CONFIG_CMD_MTEST */

Line spacing around ifdef/endif seems inconsistent with others in the 
file (see "#endif /* CONFIG_LOOPW */").

>   /* Modify memory.
>    *
> @@ -1245,11 +1248,13 @@ U_BOOT_CMD(
>   );
>   #endif /* CONFIG_LOOPW */
>
> +#ifdef CONFIG_CMD_MTEST
>   U_BOOT_CMD(
>   	mtest,	5,	1,	do_mem_mtest,
>   	"simple RAM read/write test",
>   	"[start [end [pattern [iterations]]]]"
>   );
> +#endif /* CONFIG_CMD_MTEST */
>
>   #ifdef CONFIG_MX_CYCLIC
>   U_BOOT_CMD(


Amicalement,
diff mbox

Patch

diff --git a/common/cmd_mem.c b/common/cmd_mem.c
index a5576aa..833af66 100644
--- a/common/cmd_mem.c
+++ b/common/cmd_mem.c
@@ -610,6 +610,8 @@  int do_mem_loopw (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
 }
 #endif /* CONFIG_LOOPW */
 
+#ifdef CONFIG_CMD_MTEST
+
 /*
  * Perform a memory test. A more complete alternative test can be
  * configured using CONFIG_SYS_ALT_MEMTEST. The complete test loops until
@@ -965,6 +967,7 @@  int do_mem_mtest (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
 	return 0;	/* not reached */
 }
 
+#endif /* CONFIG_CMD_MTEST */
 
 /* Modify memory.
  *
@@ -1245,11 +1248,13 @@  U_BOOT_CMD(
 );
 #endif /* CONFIG_LOOPW */
 
+#ifdef CONFIG_CMD_MTEST
 U_BOOT_CMD(
 	mtest,	5,	1,	do_mem_mtest,
 	"simple RAM read/write test",
 	"[start [end [pattern [iterations]]]]"
 );
+#endif /* CONFIG_CMD_MTEST */
 
 #ifdef CONFIG_MX_CYCLIC
 U_BOOT_CMD(