summaryrefslogtreecommitdiff
path: root/common
diff options
context:
space:
mode:
authorWolfgang Denk <wd@denx.de>2013-03-08 10:51:32 +0000
committerTom Rini <trini@ti.com>2013-03-11 15:26:59 -0400
commita2681707b2478abef34b8c403e7ab52daae9c331 (patch)
tree5f3893c85d1122fb9734eb8406e75b70b89264b8 /common
parentc02bff361794cff181bd3eca0ec1edce636f8dd4 (diff)
downloadu-boot-imx-a2681707b2478abef34b8c403e7ab52daae9c331.zip
u-boot-imx-a2681707b2478abef34b8c403e7ab52daae9c331.tar.gz
u-boot-imx-a2681707b2478abef34b8c403e7ab52daae9c331.tar.bz2
Feature Removal: disable "mtest" command by default
The "mtest" command is of little practical use (if any), and experience has shown that a large number of board configurations define useless or even dangerous start and end addresses. If not even the board maintainers are able to figure out which memory range can be reliably tested, how can we expect such from the end users? As this problem comes up repeatedly, we rather do not enable this command by default, so only people who know what they are doing will be confronted with it. As this changes the user interface, we allow for a grace period before this change takes effect. For now, we make "mtest" configurable through the CONFIG_CMD_MEMTEST variable, which is defined in include/config_cmd_default.h; we also add an entry to doc/feature-removal-schedule.txt which announces the removal of this default setting in two releases from now, i. e. with v2013.07. Signed-off-by: Wolfgang Denk <wd@denx.de> Cc: Tom Rini <trini@ti.com>
Diffstat (limited to 'common')
-rw-r--r--common/cmd_mem.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/common/cmd_mem.c b/common/cmd_mem.c
index 042c994..53572f7 100644
--- a/common/cmd_mem.c
+++ b/common/cmd_mem.c
@@ -910,6 +910,7 @@ static ulong mem_test_quick(vu_long *buf, ulong start_addr, ulong end_addr,
return 0;
}
+#ifdef CONFIG_CMD_MEMTEST
/*
* Perform a memory test. A more complete alternative test can be
* configured using CONFIG_SYS_ALT_MEMTEST. The complete test loops until
@@ -1002,7 +1003,7 @@ static int do_mem_mtest(cmd_tbl_t *cmdtp, int flag, int argc,
return ret; /* not reached */
}
-
+#endif /* CONFIG_CMD_MEMTEST */
/* Modify memory.
*
@@ -1240,11 +1241,13 @@ U_BOOT_CMD(
);
#endif /* CONFIG_LOOPW */
+#ifdef CONFIG_CMD_MEMTEST
U_BOOT_CMD(
mtest, 5, 1, do_mem_mtest,
"simple RAM read/write test",
"[start [end [pattern [iterations]]]]"
);
+#endif /* CONFIG_CMD_MEMTEST */
#ifdef CONFIG_MX_CYCLIC
U_BOOT_CMD(