diff options
author | Denys Vlasenko <vda.linux@googlemail.com> | 2020-11-30 13:03:03 +0100 |
---|---|---|
committer | Denys Vlasenko <vda.linux@googlemail.com> | 2020-11-30 13:03:03 +0100 |
commit | 965b795b87c59ed45cc7f16a62301dbae65b1627 (patch) | |
tree | 958e486f4f23177746ddee11913d3b59ff4e7f8e /networking | |
parent | 2fba2f5bb99145eaa1635fe5a162426158d56a2c (diff) | |
download | busybox-w32-965b795b87c59ed45cc7f16a62301dbae65b1627.tar.gz busybox-w32-965b795b87c59ed45cc7f16a62301dbae65b1627.tar.bz2 busybox-w32-965b795b87c59ed45cc7f16a62301dbae65b1627.zip |
decrease paddign: gcc-9.3.1 slaps 32-byte alignment on arrays willy-nilly
text data bss dec hex filename
1021988 559 5052 1027599 fae0f busybox_old
1021236 559 5052 1026847 fab1f busybox_unstripped
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'networking')
-rw-r--r-- | networking/ifplugd.c | 2 | ||||
-rw-r--r-- | networking/interface.c | 2 | ||||
-rw-r--r-- | networking/ip.c | 2 | ||||
-rw-r--r-- | networking/libiproute/rt_names.c | 2 | ||||
-rw-r--r-- | networking/route.c | 6 | ||||
-rw-r--r-- | networking/tls.c | 2 | ||||
-rw-r--r-- | networking/udhcp/dhcpd.c | 2 |
7 files changed, 9 insertions, 9 deletions
diff --git a/networking/ifplugd.c b/networking/ifplugd.c index 60916eae6..18dcaff96 100644 --- a/networking/ifplugd.c +++ b/networking/ifplugd.c | |||
@@ -304,7 +304,7 @@ static const char api_modes[] ALIGN1 = "empwia"; | |||
304 | static const struct { | 304 | static const struct { |
305 | const char *name; | 305 | const char *name; |
306 | smallint (*func)(void); | 306 | smallint (*func)(void); |
307 | } method_table[] = { | 307 | } method_table[] ALIGN_PTR = { |
308 | { "SIOCETHTOOL" , &detect_link_ethtool }, | 308 | { "SIOCETHTOOL" , &detect_link_ethtool }, |
309 | { "SIOCGMIIPHY" , &detect_link_mii }, | 309 | { "SIOCGMIIPHY" , &detect_link_mii }, |
310 | { "SIOCDEVPRIVATE" , &detect_link_priv }, | 310 | { "SIOCDEVPRIVATE" , &detect_link_priv }, |
diff --git a/networking/interface.c b/networking/interface.c index e5e55d8d4..ea6a2c8a8 100644 --- a/networking/interface.c +++ b/networking/interface.c | |||
@@ -746,7 +746,7 @@ static const struct hwtype *const hwtypes[] = { | |||
746 | }; | 746 | }; |
747 | 747 | ||
748 | #ifdef IFF_PORTSEL | 748 | #ifdef IFF_PORTSEL |
749 | static const char *const if_port_text[] = { | 749 | static const char *const if_port_text[] ALIGN_PTR = { |
750 | /* Keep in step with <linux/netdevice.h> */ | 750 | /* Keep in step with <linux/netdevice.h> */ |
751 | "unknown", | 751 | "unknown", |
752 | "10base2", | 752 | "10base2", |
diff --git a/networking/ip.c b/networking/ip.c index 33bea5f49..85b1ba080 100644 --- a/networking/ip.c +++ b/networking/ip.c | |||
@@ -400,7 +400,7 @@ int ip_main(int argc UNUSED_PARAM, char **argv) | |||
400 | IF_FEATURE_IP_RULE("rule\0") | 400 | IF_FEATURE_IP_RULE("rule\0") |
401 | IF_FEATURE_IP_NEIGH("neigh\0") | 401 | IF_FEATURE_IP_NEIGH("neigh\0") |
402 | ; | 402 | ; |
403 | static const ip_func_ptr_t ip_func_ptrs[] = { | 403 | static const ip_func_ptr_t ip_func_ptrs[] ALIGN_PTR = { |
404 | ip_print_help, | 404 | ip_print_help, |
405 | IF_FEATURE_IP_ADDRESS(do_ipaddr,) | 405 | IF_FEATURE_IP_ADDRESS(do_ipaddr,) |
406 | IF_FEATURE_IP_ROUTE(do_iproute,) | 406 | IF_FEATURE_IP_ROUTE(do_iproute,) |
diff --git a/networking/libiproute/rt_names.c b/networking/libiproute/rt_names.c index 51f2e9bdb..3c2fad912 100644 --- a/networking/libiproute/rt_names.c +++ b/networking/libiproute/rt_names.c | |||
@@ -77,7 +77,7 @@ static rtnl_tab_t *rtnl_rtprot_tab; | |||
77 | 77 | ||
78 | static void rtnl_rtprot_initialize(void) | 78 | static void rtnl_rtprot_initialize(void) |
79 | { | 79 | { |
80 | static const char *const init_tab[] = { | 80 | static const char *const init_tab[] ALIGN_PTR = { |
81 | "none", | 81 | "none", |
82 | "redirect", | 82 | "redirect", |
83 | "kernel", | 83 | "kernel", |
diff --git a/networking/route.c b/networking/route.c index 4d9aad6cc..4901109f1 100644 --- a/networking/route.c +++ b/networking/route.c | |||
@@ -460,9 +460,9 @@ static NOINLINE void INET6_setroute(int action, char **args) | |||
460 | #endif | 460 | #endif |
461 | 461 | ||
462 | static const | 462 | static const |
463 | IF_NOT_FEATURE_IPV6(uint16_t) | 463 | IF_NOT_FEATURE_IPV6(uint16_t flagvals[] ALIGN2 = ) |
464 | IF_FEATURE_IPV6(unsigned) | 464 | IF_FEATURE_IPV6(uint32_t flagvals[] ALIGN4 = ) |
465 | flagvals[] = { /* Must agree with flagchars[]. */ | 465 | { /* Must agree with flagchars[]. */ |
466 | RTF_UP, | 466 | RTF_UP, |
467 | RTF_GATEWAY, | 467 | RTF_GATEWAY, |
468 | RTF_HOST, | 468 | RTF_HOST, |
diff --git a/networking/tls.c b/networking/tls.c index 341225207..e34acd69f 100644 --- a/networking/tls.c +++ b/networking/tls.c | |||
@@ -1953,7 +1953,7 @@ static void send_client_key_exchange(tls_state_t *tls) | |||
1953 | premaster_size = sizeof(rsa_premaster); | 1953 | premaster_size = sizeof(rsa_premaster); |
1954 | } else { | 1954 | } else { |
1955 | /* ECDHE */ | 1955 | /* ECDHE */ |
1956 | static const uint8_t basepoint9[CURVE25519_KEYSIZE] = {9}; | 1956 | static const uint8_t basepoint9[CURVE25519_KEYSIZE] ALIGN1 = {9}; |
1957 | uint8_t privkey[CURVE25519_KEYSIZE]; //[32] | 1957 | uint8_t privkey[CURVE25519_KEYSIZE]; //[32] |
1958 | 1958 | ||
1959 | if (!(tls->flags & GOT_EC_KEY)) | 1959 | if (!(tls->flags & GOT_EC_KEY)) |
diff --git a/networking/udhcp/dhcpd.c b/networking/udhcp/dhcpd.c index acfdaa8c3..de16cf955 100644 --- a/networking/udhcp/dhcpd.c +++ b/networking/udhcp/dhcpd.c | |||
@@ -398,7 +398,7 @@ struct config_keyword { | |||
398 | 398 | ||
399 | #define OFS(field) offsetof(struct server_data_t, field) | 399 | #define OFS(field) offsetof(struct server_data_t, field) |
400 | 400 | ||
401 | static const struct config_keyword keywords[] = { | 401 | static const struct config_keyword keywords[] ALIGN_PTR = { |
402 | /* keyword handler variable address default */ | 402 | /* keyword handler variable address default */ |
403 | {"start" , udhcp_str2nip , OFS(start_ip ), "192.168.0.20"}, | 403 | {"start" , udhcp_str2nip , OFS(start_ip ), "192.168.0.20"}, |
404 | {"end" , udhcp_str2nip , OFS(end_ip ), "192.168.0.254"}, | 404 | {"end" , udhcp_str2nip , OFS(end_ip ), "192.168.0.254"}, |