udhcpc: make DHCP packets to have at least 300 DHCP bytes

Commit b8b72f02 removed all padding from DHCP packets
to fix operation with buggy servers which can't handle
maximum sized packets.  But it introduced a regression
with buggy routers which drop DHCP packets smaller
than 300 bytes (i.e. 342 byte ethernet packets).
Add back some padding to work around.

function                                             old     new   delta
udhcp_send_kernel_packet                             268     292     +24
udhcp_send_raw_packet                                462     473     +11
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 2/0 up/down: 35/0)               Total: 35 bytes

Signed-off-by: Johannes Stezenbach <js@sig21.net>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
sed: accept -E as a synonym for -r

Signed-off-by: David A. Wheeler <dwheeler@dwheeler.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
sed: fix memory leak in 'r FILE' command

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
sed: document -E in help text

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
sed: fix "sed clusternewline" testcase

function                                             old     new   delta
process_files                                       2197    2226     +29
flush_append                                          47      54      +7
get_next_line                                        184     189      +5
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 3/0 up/down: 41/0)               Total: 41 bytes

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Makefile.custom: make "make release" delete .gitignore files too

Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
bootchartd: warn if .config looks wrong

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
init: fix illegal memory access when max message length is reached

Signed-off-by: Yuan-Hsiang Lee <yhlee@ubnt.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
udhcpc: allow zero server-id. Closes 6614.

function                                             old     new   delta
bcast_or_ucast                                         -      47     +47
udhcp_send_kernel_packet                             271     295     +24
udhcpc_main                                         2696    2705      +9
udhcp_send_raw_packet                                456     459      +3
send_release                                          90      76     -14
send_renew                                           105      77     -28
------------------------------------------------------------------------------
(add/remove: 1/0 grow/shrink: 3/2 up/down: 83/-42)             Total: 41 bytes

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
swaponoff: shrink

function                                             old     new   delta
.rodata                                           148469  148468      -1
swap_on_off_main                                     381     379      -2
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 0/2 up/down: 0/-3)               Total: -3 bytes
   text	   data	    bss	    dec	    hex	filename
 803030	   4090	   9504	 816624	  c75f0	busybox_old
 803027	   4090	   9504	 816621	  c75ed	busybox_unstripped
ash: Use setvar2 some more

(add/remove: 0/0 grow/shrink: 10/15 up/down: 13/-27)          Total: -14 bytes

Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
ash: Set SHLVL in ASH_BASH_COMPAT

function                                             old     new   delta
ash_main                                            1456    1505     +49
.rodata                                           148488  148494      +6
------------------------------------------------------------------------------
(add/remove: 0/0 grow/shrink: 2/0 up/down: 55/0)               Total: 55 bytes

Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
fstrim: New applet

fstrim applet is a port from util-linux.

"Trimming" your NAND/eMMC storage will restore the write performance
back to normal after having slow down issues on sequential write and
random write due to usage over time.

Good reading on subject:
http://forum.xda-developers.com/showthread.php?t=1971852

(with long options and CLEAN_UP turned on)
function                                             old     new   delta
.rodata                                           148494  148791    +297
fstrim_main                                            -     283    +283
fstrim_sfx                                             -     128    +128
packed_usage                                       28826   28903     +77
applet_main                                         2760    2768      +8
applet_names                                        2343    2350      +7
applet_nameofs                                       690     692      +2
------------------------------------------------------------------------------
(add/remove: 3/0 grow/shrink: 5/0 up/down: 802/0)             Total: 802 bytes

Signed-off-by: Malek Degachi <malek-degachi@laposte.net>
Cc: Eugene San (eugenesan) <eugenesan@gmail.com>
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
fstrim: -17b

Also, use the name of the block device we found, not necessarily the one
we got from the user:
fstrim -v /
/dev/sdj: 4711 bytes were trimmed

Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
fstrim: Indicate failure on error

+14b

Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
fstrim: Needs to fire at the mp, not bd

It's a filesystem thing from this perspective.
+1b

Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
fix bashisms in testsuite/

These places use ${var/search/replace}, $((n++) and
`type -p' constructs which are not-so-standard.
Replace with equivalent constructs.

Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
fix "warning: ISO C90 forbids mixed declarations and code"

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
udhcp: add PXELINUX config file option (code 209) definition

This change adds a definition for DHCP option 209. RFC 5071 defines code
209 as a configuration file for a PXE bootloader; this change uses
the string "pxeconffile" as its text identifier.

Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
fstrim: use new-style config/kbuild/applet snippets; trim help text

function                                             old     new   delta
packed_usage                                       29546   29520     -26

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>