* [PATCH] net: stmmac: make const array route_possibilities static
@ 2017-07-11 11:18 ` Colin King
0 siblings, 0 replies; 4+ messages in thread
From: Colin King @ 2017-07-11 11:18 UTC (permalink / raw)
To: Giuseppe Cavallaro, Alexandre Torgue, netdev
Cc: kernel-janitors, linux-kernel
From: Colin Ian King <colin.king@canonical.com>
Don't populate array route_possibilities on the stack but make it
static const. Makes the object code a little smaller by 85 bytes:
Before:
text data bss dec hex filename
9901 2448 0 12349 303d dwmac4_core.o
After:
text data bss dec hex filename
9760 2504 0 12264 2fe8 dwmac4_core.o
Signed-off-by: Colin Ian King <colin.king@canonical.com>
---
drivers/net/ethernet/stmicro/stmmac/dwmac4_core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/ethernet/stmicro/stmmac/dwmac4_core.c b/drivers/net/ethernet/stmicro/stmmac/dwmac4_core.c
index f233bf8b4ebb..c4407e8e39a3 100644
--- a/drivers/net/ethernet/stmicro/stmmac/dwmac4_core.c
+++ b/drivers/net/ethernet/stmicro/stmmac/dwmac4_core.c
@@ -117,7 +117,7 @@ static void dwmac4_tx_queue_routing(struct mac_device_info *hw,
void __iomem *ioaddr = hw->pcsr;
u32 value;
- const struct stmmac_rx_routing route_possibilities[] = {
+ static const struct stmmac_rx_routing route_possibilities[] = {
{ GMAC_RXQCTRL_AVCPQ_MASK, GMAC_RXQCTRL_AVCPQ_SHIFT },
{ GMAC_RXQCTRL_PTPQ_MASK, GMAC_RXQCTRL_PTPQ_SHIFT },
{ GMAC_RXQCTRL_DCBCPQ_MASK, GMAC_RXQCTRL_DCBCPQ_SHIFT },
--
2.11.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH] net: stmmac: make const array route_possibilities static
@ 2017-07-11 11:18 ` Colin King
0 siblings, 0 replies; 4+ messages in thread
From: Colin King @ 2017-07-11 11:18 UTC (permalink / raw)
To: Giuseppe Cavallaro, Alexandre Torgue, netdev
Cc: kernel-janitors, linux-kernel
From: Colin Ian King <colin.king@canonical.com>
Don't populate array route_possibilities on the stack but make it
static const. Makes the object code a little smaller by 85 bytes:
Before:
text data bss dec hex filename
9901 2448 0 12349 303d dwmac4_core.o
After:
text data bss dec hex filename
9760 2504 0 12264 2fe8 dwmac4_core.o
Signed-off-by: Colin Ian King <colin.king@canonical.com>
---
drivers/net/ethernet/stmicro/stmmac/dwmac4_core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/ethernet/stmicro/stmmac/dwmac4_core.c b/drivers/net/ethernet/stmicro/stmmac/dwmac4_core.c
index f233bf8b4ebb..c4407e8e39a3 100644
--- a/drivers/net/ethernet/stmicro/stmmac/dwmac4_core.c
+++ b/drivers/net/ethernet/stmicro/stmmac/dwmac4_core.c
@@ -117,7 +117,7 @@ static void dwmac4_tx_queue_routing(struct mac_device_info *hw,
void __iomem *ioaddr = hw->pcsr;
u32 value;
- const struct stmmac_rx_routing route_possibilities[] = {
+ static const struct stmmac_rx_routing route_possibilities[] = {
{ GMAC_RXQCTRL_AVCPQ_MASK, GMAC_RXQCTRL_AVCPQ_SHIFT },
{ GMAC_RXQCTRL_PTPQ_MASK, GMAC_RXQCTRL_PTPQ_SHIFT },
{ GMAC_RXQCTRL_DCBCPQ_MASK, GMAC_RXQCTRL_DCBCPQ_SHIFT },
--
2.11.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] net: stmmac: make const array route_possibilities static
2017-07-11 11:18 ` Colin King
@ 2017-07-13 16:24 ` David Miller
-1 siblings, 0 replies; 4+ messages in thread
From: David Miller @ 2017-07-13 16:24 UTC (permalink / raw)
To: colin.king
Cc: peppe.cavallaro, alexandre.torgue, netdev, kernel-janitors, linux-kernel
From: Colin King <colin.king@canonical.com>
Date: Tue, 11 Jul 2017 12:18:48 +0100
> From: Colin Ian King <colin.king@canonical.com>
>
> Don't populate array route_possibilities on the stack but make it
> static const. Makes the object code a little smaller by 85 bytes:
>
> Before:
> text data bss dec hex filename
> 9901 2448 0 12349 303d dwmac4_core.o
>
> After:
> text data bss dec hex filename
> 9760 2504 0 12264 2fe8 dwmac4_core.o
>
> Signed-off-by: Colin Ian King <colin.king@canonical.com>
Applied.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] net: stmmac: make const array route_possibilities static
@ 2017-07-13 16:24 ` David Miller
0 siblings, 0 replies; 4+ messages in thread
From: David Miller @ 2017-07-13 16:24 UTC (permalink / raw)
To: colin.king
Cc: peppe.cavallaro, alexandre.torgue, netdev, kernel-janitors, linux-kernel
From: Colin King <colin.king@canonical.com>
Date: Tue, 11 Jul 2017 12:18:48 +0100
> From: Colin Ian King <colin.king@canonical.com>
>
> Don't populate array route_possibilities on the stack but make it
> static const. Makes the object code a little smaller by 85 bytes:
>
> Before:
> text data bss dec hex filename
> 9901 2448 0 12349 303d dwmac4_core.o
>
> After:
> text data bss dec hex filename
> 9760 2504 0 12264 2fe8 dwmac4_core.o
>
> Signed-off-by: Colin Ian King <colin.king@canonical.com>
Applied.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2017-07-13 16:27 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-07-11 11:18 [PATCH] net: stmmac: make const array route_possibilities static Colin King
2017-07-11 11:18 ` Colin King
2017-07-13 16:24 ` David Miller
2017-07-13 16:24 ` David Miller
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.