Commit 1257c962 authored by Sean Anderson's avatar Sean Anderson Committed by David S. Miller

net: fman: Mark mac methods static

These methods are no longer accessed outside of the driver file, so mark
them as static.
Signed-off-by: default avatarSean Anderson <sean.anderson@seco.com>
Acked-by: default avatarCamelia Groza <camelia.groza@nxp.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 302376fe
...@@ -814,7 +814,7 @@ static void free_init_resources(struct fman_mac *dtsec) ...@@ -814,7 +814,7 @@ static void free_init_resources(struct fman_mac *dtsec)
dtsec->unicast_addr_hash = NULL; dtsec->unicast_addr_hash = NULL;
} }
int dtsec_cfg_max_frame_len(struct fman_mac *dtsec, u16 new_val) static int dtsec_cfg_max_frame_len(struct fman_mac *dtsec, u16 new_val)
{ {
if (is_init_done(dtsec->dtsec_drv_param)) if (is_init_done(dtsec->dtsec_drv_param))
return -EINVAL; return -EINVAL;
...@@ -824,7 +824,7 @@ int dtsec_cfg_max_frame_len(struct fman_mac *dtsec, u16 new_val) ...@@ -824,7 +824,7 @@ int dtsec_cfg_max_frame_len(struct fman_mac *dtsec, u16 new_val)
return 0; return 0;
} }
int dtsec_cfg_pad_and_crc(struct fman_mac *dtsec, bool new_val) static int dtsec_cfg_pad_and_crc(struct fman_mac *dtsec, bool new_val)
{ {
if (is_init_done(dtsec->dtsec_drv_param)) if (is_init_done(dtsec->dtsec_drv_param))
return -EINVAL; return -EINVAL;
...@@ -872,7 +872,7 @@ static void graceful_stop(struct fman_mac *dtsec) ...@@ -872,7 +872,7 @@ static void graceful_stop(struct fman_mac *dtsec)
} }
} }
int dtsec_enable(struct fman_mac *dtsec) static int dtsec_enable(struct fman_mac *dtsec)
{ {
struct dtsec_regs __iomem *regs = dtsec->regs; struct dtsec_regs __iomem *regs = dtsec->regs;
u32 tmp; u32 tmp;
...@@ -891,7 +891,7 @@ int dtsec_enable(struct fman_mac *dtsec) ...@@ -891,7 +891,7 @@ int dtsec_enable(struct fman_mac *dtsec)
return 0; return 0;
} }
int dtsec_disable(struct fman_mac *dtsec) static int dtsec_disable(struct fman_mac *dtsec)
{ {
struct dtsec_regs __iomem *regs = dtsec->regs; struct dtsec_regs __iomem *regs = dtsec->regs;
u32 tmp; u32 tmp;
...@@ -909,9 +909,10 @@ int dtsec_disable(struct fman_mac *dtsec) ...@@ -909,9 +909,10 @@ int dtsec_disable(struct fman_mac *dtsec)
return 0; return 0;
} }
int dtsec_set_tx_pause_frames(struct fman_mac *dtsec, static int dtsec_set_tx_pause_frames(struct fman_mac *dtsec,
u8 __maybe_unused priority, u8 __maybe_unused priority,
u16 pause_time, u16 __maybe_unused thresh_time) u16 pause_time,
u16 __maybe_unused thresh_time)
{ {
struct dtsec_regs __iomem *regs = dtsec->regs; struct dtsec_regs __iomem *regs = dtsec->regs;
u32 ptv = 0; u32 ptv = 0;
...@@ -946,7 +947,7 @@ int dtsec_set_tx_pause_frames(struct fman_mac *dtsec, ...@@ -946,7 +947,7 @@ int dtsec_set_tx_pause_frames(struct fman_mac *dtsec,
return 0; return 0;
} }
int dtsec_accept_rx_pause_frames(struct fman_mac *dtsec, bool en) static int dtsec_accept_rx_pause_frames(struct fman_mac *dtsec, bool en)
{ {
struct dtsec_regs __iomem *regs = dtsec->regs; struct dtsec_regs __iomem *regs = dtsec->regs;
u32 tmp; u32 tmp;
...@@ -968,7 +969,8 @@ int dtsec_accept_rx_pause_frames(struct fman_mac *dtsec, bool en) ...@@ -968,7 +969,8 @@ int dtsec_accept_rx_pause_frames(struct fman_mac *dtsec, bool en)
return 0; return 0;
} }
int dtsec_modify_mac_address(struct fman_mac *dtsec, const enet_addr_t *enet_addr) static int dtsec_modify_mac_address(struct fman_mac *dtsec,
const enet_addr_t *enet_addr)
{ {
if (!is_init_done(dtsec->dtsec_drv_param)) if (!is_init_done(dtsec->dtsec_drv_param))
return -EINVAL; return -EINVAL;
...@@ -986,7 +988,8 @@ int dtsec_modify_mac_address(struct fman_mac *dtsec, const enet_addr_t *enet_add ...@@ -986,7 +988,8 @@ int dtsec_modify_mac_address(struct fman_mac *dtsec, const enet_addr_t *enet_add
return 0; return 0;
} }
int dtsec_add_hash_mac_address(struct fman_mac *dtsec, enet_addr_t *eth_addr) static int dtsec_add_hash_mac_address(struct fman_mac *dtsec,
enet_addr_t *eth_addr)
{ {
struct dtsec_regs __iomem *regs = dtsec->regs; struct dtsec_regs __iomem *regs = dtsec->regs;
struct eth_hash_entry *hash_entry; struct eth_hash_entry *hash_entry;
...@@ -1052,7 +1055,7 @@ int dtsec_add_hash_mac_address(struct fman_mac *dtsec, enet_addr_t *eth_addr) ...@@ -1052,7 +1055,7 @@ int dtsec_add_hash_mac_address(struct fman_mac *dtsec, enet_addr_t *eth_addr)
return 0; return 0;
} }
int dtsec_set_allmulti(struct fman_mac *dtsec, bool enable) static int dtsec_set_allmulti(struct fman_mac *dtsec, bool enable)
{ {
u32 tmp; u32 tmp;
struct dtsec_regs __iomem *regs = dtsec->regs; struct dtsec_regs __iomem *regs = dtsec->regs;
...@@ -1071,7 +1074,7 @@ int dtsec_set_allmulti(struct fman_mac *dtsec, bool enable) ...@@ -1071,7 +1074,7 @@ int dtsec_set_allmulti(struct fman_mac *dtsec, bool enable)
return 0; return 0;
} }
int dtsec_set_tstamp(struct fman_mac *dtsec, bool enable) static int dtsec_set_tstamp(struct fman_mac *dtsec, bool enable)
{ {
struct dtsec_regs __iomem *regs = dtsec->regs; struct dtsec_regs __iomem *regs = dtsec->regs;
u32 rctrl, tctrl; u32 rctrl, tctrl;
...@@ -1096,7 +1099,8 @@ int dtsec_set_tstamp(struct fman_mac *dtsec, bool enable) ...@@ -1096,7 +1099,8 @@ int dtsec_set_tstamp(struct fman_mac *dtsec, bool enable)
return 0; return 0;
} }
int dtsec_del_hash_mac_address(struct fman_mac *dtsec, enet_addr_t *eth_addr) static int dtsec_del_hash_mac_address(struct fman_mac *dtsec,
enet_addr_t *eth_addr)
{ {
struct dtsec_regs __iomem *regs = dtsec->regs; struct dtsec_regs __iomem *regs = dtsec->regs;
struct list_head *pos; struct list_head *pos;
...@@ -1167,7 +1171,7 @@ int dtsec_del_hash_mac_address(struct fman_mac *dtsec, enet_addr_t *eth_addr) ...@@ -1167,7 +1171,7 @@ int dtsec_del_hash_mac_address(struct fman_mac *dtsec, enet_addr_t *eth_addr)
return 0; return 0;
} }
int dtsec_set_promiscuous(struct fman_mac *dtsec, bool new_val) static int dtsec_set_promiscuous(struct fman_mac *dtsec, bool new_val)
{ {
struct dtsec_regs __iomem *regs = dtsec->regs; struct dtsec_regs __iomem *regs = dtsec->regs;
u32 tmp; u32 tmp;
...@@ -1196,7 +1200,7 @@ int dtsec_set_promiscuous(struct fman_mac *dtsec, bool new_val) ...@@ -1196,7 +1200,7 @@ int dtsec_set_promiscuous(struct fman_mac *dtsec, bool new_val)
return 0; return 0;
} }
int dtsec_adjust_link(struct fman_mac *dtsec, u16 speed) static int dtsec_adjust_link(struct fman_mac *dtsec, u16 speed)
{ {
struct dtsec_regs __iomem *regs = dtsec->regs; struct dtsec_regs __iomem *regs = dtsec->regs;
u32 tmp; u32 tmp;
...@@ -1230,7 +1234,7 @@ int dtsec_adjust_link(struct fman_mac *dtsec, u16 speed) ...@@ -1230,7 +1234,7 @@ int dtsec_adjust_link(struct fman_mac *dtsec, u16 speed)
return 0; return 0;
} }
int dtsec_restart_autoneg(struct fman_mac *dtsec) static int dtsec_restart_autoneg(struct fman_mac *dtsec)
{ {
u16 tmp_reg16; u16 tmp_reg16;
...@@ -1270,7 +1274,7 @@ static void adjust_link_dtsec(struct mac_device *mac_dev) ...@@ -1270,7 +1274,7 @@ static void adjust_link_dtsec(struct mac_device *mac_dev)
err); err);
} }
int dtsec_get_version(struct fman_mac *dtsec, u32 *mac_version) static int dtsec_get_version(struct fman_mac *dtsec, u32 *mac_version)
{ {
struct dtsec_regs __iomem *regs = dtsec->regs; struct dtsec_regs __iomem *regs = dtsec->regs;
...@@ -1282,8 +1286,8 @@ int dtsec_get_version(struct fman_mac *dtsec, u32 *mac_version) ...@@ -1282,8 +1286,8 @@ int dtsec_get_version(struct fman_mac *dtsec, u32 *mac_version)
return 0; return 0;
} }
int dtsec_set_exception(struct fman_mac *dtsec, static int dtsec_set_exception(struct fman_mac *dtsec,
enum fman_mac_exceptions exception, bool enable) enum fman_mac_exceptions exception, bool enable)
{ {
struct dtsec_regs __iomem *regs = dtsec->regs; struct dtsec_regs __iomem *regs = dtsec->regs;
u32 bit_mask = 0; u32 bit_mask = 0;
...@@ -1336,7 +1340,7 @@ int dtsec_set_exception(struct fman_mac *dtsec, ...@@ -1336,7 +1340,7 @@ int dtsec_set_exception(struct fman_mac *dtsec,
return 0; return 0;
} }
int dtsec_init(struct fman_mac *dtsec) static int dtsec_init(struct fman_mac *dtsec)
{ {
struct dtsec_regs __iomem *regs = dtsec->regs; struct dtsec_regs __iomem *regs = dtsec->regs;
struct dtsec_cfg *dtsec_drv_param; struct dtsec_cfg *dtsec_drv_param;
...@@ -1430,7 +1434,7 @@ int dtsec_init(struct fman_mac *dtsec) ...@@ -1430,7 +1434,7 @@ int dtsec_init(struct fman_mac *dtsec)
return 0; return 0;
} }
int dtsec_free(struct fman_mac *dtsec) static int dtsec_free(struct fman_mac *dtsec)
{ {
free_init_resources(dtsec); free_init_resources(dtsec);
...@@ -1441,7 +1445,7 @@ int dtsec_free(struct fman_mac *dtsec) ...@@ -1441,7 +1445,7 @@ int dtsec_free(struct fman_mac *dtsec)
return 0; return 0;
} }
struct fman_mac *dtsec_config(struct fman_mac_params *params) static struct fman_mac *dtsec_config(struct fman_mac_params *params)
{ {
struct fman_mac *dtsec; struct fman_mac *dtsec;
struct dtsec_cfg *dtsec_drv_param; struct dtsec_cfg *dtsec_drv_param;
......
...@@ -686,7 +686,7 @@ static bool is_init_done(struct memac_cfg *memac_drv_params) ...@@ -686,7 +686,7 @@ static bool is_init_done(struct memac_cfg *memac_drv_params)
return false; return false;
} }
int memac_enable(struct fman_mac *memac) static int memac_enable(struct fman_mac *memac)
{ {
struct memac_regs __iomem *regs = memac->regs; struct memac_regs __iomem *regs = memac->regs;
u32 tmp; u32 tmp;
...@@ -701,7 +701,7 @@ int memac_enable(struct fman_mac *memac) ...@@ -701,7 +701,7 @@ int memac_enable(struct fman_mac *memac)
return 0; return 0;
} }
int memac_disable(struct fman_mac *memac) static int memac_disable(struct fman_mac *memac)
{ {
struct memac_regs __iomem *regs = memac->regs; struct memac_regs __iomem *regs = memac->regs;
u32 tmp; u32 tmp;
...@@ -716,7 +716,7 @@ int memac_disable(struct fman_mac *memac) ...@@ -716,7 +716,7 @@ int memac_disable(struct fman_mac *memac)
return 0; return 0;
} }
int memac_set_promiscuous(struct fman_mac *memac, bool new_val) static int memac_set_promiscuous(struct fman_mac *memac, bool new_val)
{ {
struct memac_regs __iomem *regs = memac->regs; struct memac_regs __iomem *regs = memac->regs;
u32 tmp; u32 tmp;
...@@ -735,7 +735,7 @@ int memac_set_promiscuous(struct fman_mac *memac, bool new_val) ...@@ -735,7 +735,7 @@ int memac_set_promiscuous(struct fman_mac *memac, bool new_val)
return 0; return 0;
} }
int memac_adjust_link(struct fman_mac *memac, u16 speed) static int memac_adjust_link(struct fman_mac *memac, u16 speed)
{ {
struct memac_regs __iomem *regs = memac->regs; struct memac_regs __iomem *regs = memac->regs;
u32 tmp; u32 tmp;
...@@ -792,7 +792,7 @@ static void adjust_link_memac(struct mac_device *mac_dev) ...@@ -792,7 +792,7 @@ static void adjust_link_memac(struct mac_device *mac_dev)
err); err);
} }
int memac_cfg_max_frame_len(struct fman_mac *memac, u16 new_val) static int memac_cfg_max_frame_len(struct fman_mac *memac, u16 new_val)
{ {
if (is_init_done(memac->memac_drv_param)) if (is_init_done(memac->memac_drv_param))
return -EINVAL; return -EINVAL;
...@@ -802,7 +802,7 @@ int memac_cfg_max_frame_len(struct fman_mac *memac, u16 new_val) ...@@ -802,7 +802,7 @@ int memac_cfg_max_frame_len(struct fman_mac *memac, u16 new_val)
return 0; return 0;
} }
int memac_cfg_reset_on_init(struct fman_mac *memac, bool enable) static int memac_cfg_reset_on_init(struct fman_mac *memac, bool enable)
{ {
if (is_init_done(memac->memac_drv_param)) if (is_init_done(memac->memac_drv_param))
return -EINVAL; return -EINVAL;
...@@ -812,8 +812,8 @@ int memac_cfg_reset_on_init(struct fman_mac *memac, bool enable) ...@@ -812,8 +812,8 @@ int memac_cfg_reset_on_init(struct fman_mac *memac, bool enable)
return 0; return 0;
} }
int memac_cfg_fixed_link(struct fman_mac *memac, static int memac_cfg_fixed_link(struct fman_mac *memac,
struct fixed_phy_status *fixed_link) struct fixed_phy_status *fixed_link)
{ {
if (is_init_done(memac->memac_drv_param)) if (is_init_done(memac->memac_drv_param))
return -EINVAL; return -EINVAL;
...@@ -823,8 +823,8 @@ int memac_cfg_fixed_link(struct fman_mac *memac, ...@@ -823,8 +823,8 @@ int memac_cfg_fixed_link(struct fman_mac *memac,
return 0; return 0;
} }
int memac_set_tx_pause_frames(struct fman_mac *memac, u8 priority, static int memac_set_tx_pause_frames(struct fman_mac *memac, u8 priority,
u16 pause_time, u16 thresh_time) u16 pause_time, u16 thresh_time)
{ {
struct memac_regs __iomem *regs = memac->regs; struct memac_regs __iomem *regs = memac->regs;
u32 tmp; u32 tmp;
...@@ -861,7 +861,7 @@ int memac_set_tx_pause_frames(struct fman_mac *memac, u8 priority, ...@@ -861,7 +861,7 @@ int memac_set_tx_pause_frames(struct fman_mac *memac, u8 priority,
return 0; return 0;
} }
int memac_accept_rx_pause_frames(struct fman_mac *memac, bool en) static int memac_accept_rx_pause_frames(struct fman_mac *memac, bool en)
{ {
struct memac_regs __iomem *regs = memac->regs; struct memac_regs __iomem *regs = memac->regs;
u32 tmp; u32 tmp;
...@@ -880,7 +880,8 @@ int memac_accept_rx_pause_frames(struct fman_mac *memac, bool en) ...@@ -880,7 +880,8 @@ int memac_accept_rx_pause_frames(struct fman_mac *memac, bool en)
return 0; return 0;
} }
int memac_modify_mac_address(struct fman_mac *memac, const enet_addr_t *enet_addr) static int memac_modify_mac_address(struct fman_mac *memac,
const enet_addr_t *enet_addr)
{ {
if (!is_init_done(memac->memac_drv_param)) if (!is_init_done(memac->memac_drv_param))
return -EINVAL; return -EINVAL;
...@@ -890,7 +891,8 @@ int memac_modify_mac_address(struct fman_mac *memac, const enet_addr_t *enet_add ...@@ -890,7 +891,8 @@ int memac_modify_mac_address(struct fman_mac *memac, const enet_addr_t *enet_add
return 0; return 0;
} }
int memac_add_hash_mac_address(struct fman_mac *memac, enet_addr_t *eth_addr) static int memac_add_hash_mac_address(struct fman_mac *memac,
enet_addr_t *eth_addr)
{ {
struct memac_regs __iomem *regs = memac->regs; struct memac_regs __iomem *regs = memac->regs;
struct eth_hash_entry *hash_entry; struct eth_hash_entry *hash_entry;
...@@ -923,7 +925,7 @@ int memac_add_hash_mac_address(struct fman_mac *memac, enet_addr_t *eth_addr) ...@@ -923,7 +925,7 @@ int memac_add_hash_mac_address(struct fman_mac *memac, enet_addr_t *eth_addr)
return 0; return 0;
} }
int memac_set_allmulti(struct fman_mac *memac, bool enable) static int memac_set_allmulti(struct fman_mac *memac, bool enable)
{ {
u32 entry; u32 entry;
struct memac_regs __iomem *regs = memac->regs; struct memac_regs __iomem *regs = memac->regs;
...@@ -946,12 +948,13 @@ int memac_set_allmulti(struct fman_mac *memac, bool enable) ...@@ -946,12 +948,13 @@ int memac_set_allmulti(struct fman_mac *memac, bool enable)
return 0; return 0;
} }
int memac_set_tstamp(struct fman_mac *memac, bool enable) static int memac_set_tstamp(struct fman_mac *memac, bool enable)
{ {
return 0; /* Always enabled. */ return 0; /* Always enabled. */
} }
int memac_del_hash_mac_address(struct fman_mac *memac, enet_addr_t *eth_addr) static int memac_del_hash_mac_address(struct fman_mac *memac,
enet_addr_t *eth_addr)
{ {
struct memac_regs __iomem *regs = memac->regs; struct memac_regs __iomem *regs = memac->regs;
struct eth_hash_entry *hash_entry = NULL; struct eth_hash_entry *hash_entry = NULL;
...@@ -984,8 +987,8 @@ int memac_del_hash_mac_address(struct fman_mac *memac, enet_addr_t *eth_addr) ...@@ -984,8 +987,8 @@ int memac_del_hash_mac_address(struct fman_mac *memac, enet_addr_t *eth_addr)
return 0; return 0;
} }
int memac_set_exception(struct fman_mac *memac, static int memac_set_exception(struct fman_mac *memac,
enum fman_mac_exceptions exception, bool enable) enum fman_mac_exceptions exception, bool enable)
{ {
u32 bit_mask = 0; u32 bit_mask = 0;
...@@ -1007,7 +1010,7 @@ int memac_set_exception(struct fman_mac *memac, ...@@ -1007,7 +1010,7 @@ int memac_set_exception(struct fman_mac *memac,
return 0; return 0;
} }
int memac_init(struct fman_mac *memac) static int memac_init(struct fman_mac *memac)
{ {
struct memac_cfg *memac_drv_param; struct memac_cfg *memac_drv_param;
u8 i; u8 i;
...@@ -1124,7 +1127,7 @@ int memac_init(struct fman_mac *memac) ...@@ -1124,7 +1127,7 @@ int memac_init(struct fman_mac *memac)
return 0; return 0;
} }
int memac_free(struct fman_mac *memac) static int memac_free(struct fman_mac *memac)
{ {
free_init_resources(memac); free_init_resources(memac);
...@@ -1137,7 +1140,7 @@ int memac_free(struct fman_mac *memac) ...@@ -1137,7 +1140,7 @@ int memac_free(struct fman_mac *memac)
return 0; return 0;
} }
struct fman_mac *memac_config(struct fman_mac_params *params) static struct fman_mac *memac_config(struct fman_mac_params *params)
{ {
struct fman_mac *memac; struct fman_mac *memac;
struct memac_cfg *memac_drv_param; struct memac_cfg *memac_drv_param;
......
...@@ -393,7 +393,7 @@ static bool is_init_done(struct tgec_cfg *cfg) ...@@ -393,7 +393,7 @@ static bool is_init_done(struct tgec_cfg *cfg)
return false; return false;
} }
int tgec_enable(struct fman_mac *tgec) static int tgec_enable(struct fman_mac *tgec)
{ {
struct tgec_regs __iomem *regs = tgec->regs; struct tgec_regs __iomem *regs = tgec->regs;
u32 tmp; u32 tmp;
...@@ -408,7 +408,7 @@ int tgec_enable(struct fman_mac *tgec) ...@@ -408,7 +408,7 @@ int tgec_enable(struct fman_mac *tgec)
return 0; return 0;
} }
int tgec_disable(struct fman_mac *tgec) static int tgec_disable(struct fman_mac *tgec)
{ {
struct tgec_regs __iomem *regs = tgec->regs; struct tgec_regs __iomem *regs = tgec->regs;
u32 tmp; u32 tmp;
...@@ -423,7 +423,7 @@ int tgec_disable(struct fman_mac *tgec) ...@@ -423,7 +423,7 @@ int tgec_disable(struct fman_mac *tgec)
return 0; return 0;
} }
int tgec_set_promiscuous(struct fman_mac *tgec, bool new_val) static int tgec_set_promiscuous(struct fman_mac *tgec, bool new_val)
{ {
struct tgec_regs __iomem *regs = tgec->regs; struct tgec_regs __iomem *regs = tgec->regs;
u32 tmp; u32 tmp;
...@@ -441,7 +441,7 @@ int tgec_set_promiscuous(struct fman_mac *tgec, bool new_val) ...@@ -441,7 +441,7 @@ int tgec_set_promiscuous(struct fman_mac *tgec, bool new_val)
return 0; return 0;
} }
int tgec_cfg_max_frame_len(struct fman_mac *tgec, u16 new_val) static int tgec_cfg_max_frame_len(struct fman_mac *tgec, u16 new_val)
{ {
if (is_init_done(tgec->cfg)) if (is_init_done(tgec->cfg))
return -EINVAL; return -EINVAL;
...@@ -451,8 +451,9 @@ int tgec_cfg_max_frame_len(struct fman_mac *tgec, u16 new_val) ...@@ -451,8 +451,9 @@ int tgec_cfg_max_frame_len(struct fman_mac *tgec, u16 new_val)
return 0; return 0;
} }
int tgec_set_tx_pause_frames(struct fman_mac *tgec, u8 __maybe_unused priority, static int tgec_set_tx_pause_frames(struct fman_mac *tgec,
u16 pause_time, u16 __maybe_unused thresh_time) u8 __maybe_unused priority, u16 pause_time,
u16 __maybe_unused thresh_time)
{ {
struct tgec_regs __iomem *regs = tgec->regs; struct tgec_regs __iomem *regs = tgec->regs;
...@@ -464,7 +465,7 @@ int tgec_set_tx_pause_frames(struct fman_mac *tgec, u8 __maybe_unused priority, ...@@ -464,7 +465,7 @@ int tgec_set_tx_pause_frames(struct fman_mac *tgec, u8 __maybe_unused priority,
return 0; return 0;
} }
int tgec_accept_rx_pause_frames(struct fman_mac *tgec, bool en) static int tgec_accept_rx_pause_frames(struct fman_mac *tgec, bool en)
{ {
struct tgec_regs __iomem *regs = tgec->regs; struct tgec_regs __iomem *regs = tgec->regs;
u32 tmp; u32 tmp;
...@@ -482,7 +483,8 @@ int tgec_accept_rx_pause_frames(struct fman_mac *tgec, bool en) ...@@ -482,7 +483,8 @@ int tgec_accept_rx_pause_frames(struct fman_mac *tgec, bool en)
return 0; return 0;
} }
int tgec_modify_mac_address(struct fman_mac *tgec, const enet_addr_t *p_enet_addr) static int tgec_modify_mac_address(struct fman_mac *tgec,
const enet_addr_t *p_enet_addr)
{ {
if (!is_init_done(tgec->cfg)) if (!is_init_done(tgec->cfg))
return -EINVAL; return -EINVAL;
...@@ -493,7 +495,8 @@ int tgec_modify_mac_address(struct fman_mac *tgec, const enet_addr_t *p_enet_add ...@@ -493,7 +495,8 @@ int tgec_modify_mac_address(struct fman_mac *tgec, const enet_addr_t *p_enet_add
return 0; return 0;
} }
int tgec_add_hash_mac_address(struct fman_mac *tgec, enet_addr_t *eth_addr) static int tgec_add_hash_mac_address(struct fman_mac *tgec,
enet_addr_t *eth_addr)
{ {
struct tgec_regs __iomem *regs = tgec->regs; struct tgec_regs __iomem *regs = tgec->regs;
struct eth_hash_entry *hash_entry; struct eth_hash_entry *hash_entry;
...@@ -530,7 +533,7 @@ int tgec_add_hash_mac_address(struct fman_mac *tgec, enet_addr_t *eth_addr) ...@@ -530,7 +533,7 @@ int tgec_add_hash_mac_address(struct fman_mac *tgec, enet_addr_t *eth_addr)
return 0; return 0;
} }
int tgec_set_allmulti(struct fman_mac *tgec, bool enable) static int tgec_set_allmulti(struct fman_mac *tgec, bool enable)
{ {
u32 entry; u32 entry;
struct tgec_regs __iomem *regs = tgec->regs; struct tgec_regs __iomem *regs = tgec->regs;
...@@ -553,7 +556,7 @@ int tgec_set_allmulti(struct fman_mac *tgec, bool enable) ...@@ -553,7 +556,7 @@ int tgec_set_allmulti(struct fman_mac *tgec, bool enable)
return 0; return 0;
} }
int tgec_set_tstamp(struct fman_mac *tgec, bool enable) static int tgec_set_tstamp(struct fman_mac *tgec, bool enable)
{ {
struct tgec_regs __iomem *regs = tgec->regs; struct tgec_regs __iomem *regs = tgec->regs;
u32 tmp; u32 tmp;
...@@ -573,7 +576,8 @@ int tgec_set_tstamp(struct fman_mac *tgec, bool enable) ...@@ -573,7 +576,8 @@ int tgec_set_tstamp(struct fman_mac *tgec, bool enable)
return 0; return 0;
} }
int tgec_del_hash_mac_address(struct fman_mac *tgec, enet_addr_t *eth_addr) static int tgec_del_hash_mac_address(struct fman_mac *tgec,
enet_addr_t *eth_addr)
{ {
struct tgec_regs __iomem *regs = tgec->regs; struct tgec_regs __iomem *regs = tgec->regs;
struct eth_hash_entry *hash_entry = NULL; struct eth_hash_entry *hash_entry = NULL;
...@@ -614,7 +618,7 @@ static void adjust_link_void(struct mac_device *mac_dev) ...@@ -614,7 +618,7 @@ static void adjust_link_void(struct mac_device *mac_dev)
{ {
} }
int tgec_get_version(struct fman_mac *tgec, u32 *mac_version) static int tgec_get_version(struct fman_mac *tgec, u32 *mac_version)
{ {
struct tgec_regs __iomem *regs = tgec->regs; struct tgec_regs __iomem *regs = tgec->regs;
...@@ -626,8 +630,8 @@ int tgec_get_version(struct fman_mac *tgec, u32 *mac_version) ...@@ -626,8 +630,8 @@ int tgec_get_version(struct fman_mac *tgec, u32 *mac_version)
return 0; return 0;
} }
int tgec_set_exception(struct fman_mac *tgec, static int tgec_set_exception(struct fman_mac *tgec,
enum fman_mac_exceptions exception, bool enable) enum fman_mac_exceptions exception, bool enable)
{ {
struct tgec_regs __iomem *regs = tgec->regs; struct tgec_regs __iomem *regs = tgec->regs;
u32 bit_mask = 0; u32 bit_mask = 0;
...@@ -653,7 +657,7 @@ int tgec_set_exception(struct fman_mac *tgec, ...@@ -653,7 +657,7 @@ int tgec_set_exception(struct fman_mac *tgec,
return 0; return 0;
} }
int tgec_init(struct fman_mac *tgec) static int tgec_init(struct fman_mac *tgec)
{ {
struct tgec_cfg *cfg; struct tgec_cfg *cfg;
enet_addr_t eth_addr; enet_addr_t eth_addr;
...@@ -736,7 +740,7 @@ int tgec_init(struct fman_mac *tgec) ...@@ -736,7 +740,7 @@ int tgec_init(struct fman_mac *tgec)
return 0; return 0;
} }
int tgec_free(struct fman_mac *tgec) static int tgec_free(struct fman_mac *tgec)
{ {
free_init_resources(tgec); free_init_resources(tgec);
...@@ -746,7 +750,7 @@ int tgec_free(struct fman_mac *tgec) ...@@ -746,7 +750,7 @@ int tgec_free(struct fman_mac *tgec)
return 0; return 0;
} }
struct fman_mac *tgec_config(struct fman_mac_params *params) static struct fman_mac *tgec_config(struct fman_mac_params *params)
{ {
struct fman_mac *tgec; struct fman_mac *tgec;
struct tgec_cfg *cfg; struct tgec_cfg *cfg;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment