mirror of
https://github.com/torvalds/linux.git
synced 2024-12-11 13:41:55 +00:00
sh_eth: uninline TSU register accessors
We have uninlined the sh_eth_{read|write}() functions introduced in the
commit 4a55530f38
("net: sh_eth: modify the definitions of register").
Now remove *inline* from sh_eth_tsu_{read|write}() as well and move
these functions from the header to the driver itself. This saves 684
more bytes of object code (ARM gcc 4.8.5)...
Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
ff2926d851
commit
55ea874306
@ -439,6 +439,17 @@ static void sh_eth_modify(struct net_device *ndev, int enum_index, u32 clear,
|
||||
enum_index);
|
||||
}
|
||||
|
||||
static void sh_eth_tsu_write(struct sh_eth_private *mdp, u32 data,
|
||||
int enum_index)
|
||||
{
|
||||
iowrite32(data, mdp->tsu_addr + mdp->reg_offset[enum_index]);
|
||||
}
|
||||
|
||||
static u32 sh_eth_tsu_read(struct sh_eth_private *mdp, int enum_index)
|
||||
{
|
||||
return ioread32(mdp->tsu_addr + mdp->reg_offset[enum_index]);
|
||||
}
|
||||
|
||||
static bool sh_eth_is_gether(struct sh_eth_private *mdp)
|
||||
{
|
||||
return mdp->reg_offset == sh_eth_offset_gigabit;
|
||||
|
@ -567,15 +567,4 @@ static inline void *sh_eth_tsu_get_offset(struct sh_eth_private *mdp,
|
||||
return mdp->tsu_addr + mdp->reg_offset[enum_index];
|
||||
}
|
||||
|
||||
static inline void sh_eth_tsu_write(struct sh_eth_private *mdp, u32 data,
|
||||
int enum_index)
|
||||
{
|
||||
iowrite32(data, mdp->tsu_addr + mdp->reg_offset[enum_index]);
|
||||
}
|
||||
|
||||
static inline u32 sh_eth_tsu_read(struct sh_eth_private *mdp, int enum_index)
|
||||
{
|
||||
return ioread32(mdp->tsu_addr + mdp->reg_offset[enum_index]);
|
||||
}
|
||||
|
||||
#endif /* #ifndef __SH_ETH_H__ */
|
||||
|
Loading…
Reference in New Issue
Block a user