1 From 7b778ae4eb9cd6e1518e4e47902a104b13ae8929 Mon Sep 17 00:00:00 2001
2 From: =?UTF-8?q?Rafa=C5=82=20Mi=C5=82ecki?= <rafal@milecki.pl>
3 Date: Thu, 11 Feb 2021 13:12:36 +0100
4 Subject: [PATCH] net: broadcom: bcm4908_enet: drop "inline" from C functions
6 Content-Type: text/plain; charset=UTF-8
7 Content-Transfer-Encoding: 8bit
9 It seems preferred to let compiler optimize code if applicable.
10 While at it drop unused enet_umac_maskset().
12 Suggested-by: Andrew Lunn <andrew@lunn.ch>
13 Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
14 Reviewed-by: Andrew Lunn <andrew@lunn.ch>
15 Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
16 Signed-off-by: David S. Miller <davem@davemloft.net>
18 drivers/net/ethernet/broadcom/bcm4908_enet.c | 19 +++++++------------
19 1 file changed, 7 insertions(+), 12 deletions(-)
21 --- a/drivers/net/ethernet/broadcom/bcm4908_enet.c
22 +++ b/drivers/net/ethernet/broadcom/bcm4908_enet.c
23 @@ -75,17 +75,17 @@ struct bcm4908_enet {
27 -static inline u32 enet_read(struct bcm4908_enet *enet, u16 offset)
28 +static u32 enet_read(struct bcm4908_enet *enet, u16 offset)
30 return readl(enet->base + offset);
33 -static inline void enet_write(struct bcm4908_enet *enet, u16 offset, u32 value)
34 +static void enet_write(struct bcm4908_enet *enet, u16 offset, u32 value)
36 writel(value, enet->base + offset);
39 -static inline void enet_maskset(struct bcm4908_enet *enet, u16 offset, u32 mask, u32 set)
40 +static void enet_maskset(struct bcm4908_enet *enet, u16 offset, u32 mask, u32 set)
44 @@ -96,27 +96,22 @@ static inline void enet_maskset(struct b
45 enet_write(enet, offset, val);
48 -static inline void enet_set(struct bcm4908_enet *enet, u16 offset, u32 set)
49 +static void enet_set(struct bcm4908_enet *enet, u16 offset, u32 set)
51 enet_maskset(enet, offset, set, set);
54 -static inline u32 enet_umac_read(struct bcm4908_enet *enet, u16 offset)
55 +static u32 enet_umac_read(struct bcm4908_enet *enet, u16 offset)
57 return enet_read(enet, ENET_UNIMAC + offset);
60 -static inline void enet_umac_write(struct bcm4908_enet *enet, u16 offset, u32 value)
61 +static void enet_umac_write(struct bcm4908_enet *enet, u16 offset, u32 value)
63 enet_write(enet, ENET_UNIMAC + offset, value);
66 -static inline void enet_umac_maskset(struct bcm4908_enet *enet, u16 offset, u32 mask, u32 set)
68 - enet_maskset(enet, ENET_UNIMAC + offset, mask, set);
71 -static inline void enet_umac_set(struct bcm4908_enet *enet, u16 offset, u32 set)
72 +static void enet_umac_set(struct bcm4908_enet *enet, u16 offset, u32 set)
74 enet_set(enet, ENET_UNIMAC + offset, set);