aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorBernhard Reutner-Fischer <rep.dot.nop@gmail.com>2009-02-18 13:23:46 +0000
committerBernhard Reutner-Fischer <rep.dot.nop@gmail.com>2009-02-18 13:23:46 +0000
commit0d22d1755c2c55ad45b01458bbf2f09aab4308d2 (patch)
treef5316fd29ce4e9848e9e588be46e5e2be333ec5b /include
parent051fdb9e7a248bf24bb845313e324421992abf61 (diff)
downloadbusybox-w32-0d22d1755c2c55ad45b01458bbf2f09aab4308d2.tar.gz
busybox-w32-0d22d1755c2c55ad45b01458bbf2f09aab4308d2.tar.bz2
busybox-w32-0d22d1755c2c55ad45b01458bbf2f09aab4308d2.zip
- add flash_eraseall
This is the result after converting mtd-utils' flash_eraseall to BB. The functionality given by this patch almost the same except that this one does not support long options. I needed this tool a system which does not have a lot of flash for RFS and merging this into BB as the only way out. [bigeasy@]$ ./scripts/bloat-o-meter bb_wo_fl bb_w_fl function old new delta flash_eraseall_main - 1072 +1072 show_progress - 62 +62 packed_usage 25156 25176 +20 applet_names 1958 1973 +15 applet_main 2352 2360 +8 target_endian - 4 +4 applet_nameofs 588 590 +2 applet_install_loc 147 148 +1 ------------------------------------------------------------------------------ (add/remove: 3/0 grow/shrink: 5/0 up/down: 1184/0) Total: 1184 bytes [bigeasy@]$ size miscutils/flash_eraseall.o text data bss dec hex filename 1586 4 0 1590 636 miscutils/flash_eraseall.o Signed-off-by: Benedigt Spranger <b.spranger@linutronix.de> Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Diffstat (limited to 'include')
-rw-r--r--include/applets.h2
-rw-r--r--include/usage.h8
2 files changed, 10 insertions, 0 deletions
diff --git a/include/applets.h b/include/applets.h
index af21a0d4a..15dcbdf5e 100644
--- a/include/applets.h
+++ b/include/applets.h
@@ -155,6 +155,8 @@ USE_FDISK(APPLET(fdisk, _BB_DIR_SBIN, _BB_SUID_NEVER))
155USE_FEATURE_GREP_FGREP_ALIAS(APPLET_ODDNAME(fgrep, grep, _BB_DIR_BIN, _BB_SUID_NEVER, fgrep)) 155USE_FEATURE_GREP_FGREP_ALIAS(APPLET_ODDNAME(fgrep, grep, _BB_DIR_BIN, _BB_SUID_NEVER, fgrep))
156USE_FIND(APPLET_NOEXEC(find, find, _BB_DIR_USR_BIN, _BB_SUID_NEVER, find)) 156USE_FIND(APPLET_NOEXEC(find, find, _BB_DIR_USR_BIN, _BB_SUID_NEVER, find))
157USE_FINDFS(APPLET(findfs, _BB_DIR_SBIN, _BB_SUID_MAYBE)) 157USE_FINDFS(APPLET(findfs, _BB_DIR_SBIN, _BB_SUID_MAYBE))
158//USE_FLASH_ERASEALL(APPLET_ODDNAME(flash_eraseall, flash_eraseall, _BB_DIR_USR_SBIN, _BB_SUID_NEVER, flash_eraseall))
159USE_FLASH_ERASEALL(APPLET(flash_eraseall, _BB_DIR_USR_SBIN, _BB_SUID_NEVER))
158USE_FOLD(APPLET(fold, _BB_DIR_USR_BIN, _BB_SUID_NEVER)) 160USE_FOLD(APPLET(fold, _BB_DIR_USR_BIN, _BB_SUID_NEVER))
159USE_FREE(APPLET(free, _BB_DIR_USR_BIN, _BB_SUID_NEVER)) 161USE_FREE(APPLET(free, _BB_DIR_USR_BIN, _BB_SUID_NEVER))
160USE_FREERAMDISK(APPLET(freeramdisk, _BB_DIR_SBIN, _BB_SUID_NEVER)) 162USE_FREERAMDISK(APPLET(freeramdisk, _BB_DIR_SBIN, _BB_SUID_NEVER))
diff --git a/include/usage.h b/include/usage.h
index 52af47e58..0e606609d 100644
--- a/include/usage.h
+++ b/include/usage.h
@@ -1217,6 +1217,14 @@
1217 "$ find / -name passwd\n" \ 1217 "$ find / -name passwd\n" \
1218 "/etc/passwd\n" 1218 "/etc/passwd\n"
1219 1219
1220#define flash_eraseall_trivial_usage \
1221 "[-jq] MTD_DEVICE"
1222#define flash_eraseall_full_usage "\n\n" \
1223 "Erase an MTD device\n" \
1224 "\nOptions:" \
1225 "\n -j format the device for jffs2" \
1226 "\n -q don't display progress messages"
1227
1220#define fold_trivial_usage \ 1228#define fold_trivial_usage \
1221 "[-bs] [-w WIDTH] [FILE]" 1229 "[-bs] [-w WIDTH] [FILE]"
1222#define fold_full_usage "\n\n" \ 1230#define fold_full_usage "\n\n" \