aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/pch_gbe
diff options
context:
space:
mode:
authorstephen hemminger <shemminger@vyatta.com>2010-10-15 07:09:14 -0400
committerDavid S. Miller <davem@davemloft.net>2010-10-21 06:09:44 -0400
commit191cc6877408348e90f4adb64726b60a93246b8b (patch)
tree95c50fe89410ffa801162e5c88fcf35cb5fba84a /drivers/net/pch_gbe
parentae316bb57d25d73ae9c1ddc9c59fe56d733849bf (diff)
pch_gbe: make local functions static
Make routines that are only used in one file static. Signed-off-by: Stephen Hemminger <shemminger@vyatta.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/pch_gbe')
-rw-r--r--drivers/net/pch_gbe/pch_gbe.h4
-rw-r--r--drivers/net/pch_gbe/pch_gbe_api.c2
-rw-r--r--drivers/net/pch_gbe/pch_gbe_main.c26
3 files changed, 17 insertions, 15 deletions
diff --git a/drivers/net/pch_gbe/pch_gbe.h b/drivers/net/pch_gbe/pch_gbe.h
index 9a940a940a4a..a0c26a99520f 100644
--- a/drivers/net/pch_gbe/pch_gbe.h
+++ b/drivers/net/pch_gbe/pch_gbe.h
@@ -644,9 +644,7 @@ extern void pch_gbe_free_tx_resources(struct pch_gbe_adapter *adapter,
644extern void pch_gbe_free_rx_resources(struct pch_gbe_adapter *adapter, 644extern void pch_gbe_free_rx_resources(struct pch_gbe_adapter *adapter,
645 struct pch_gbe_rx_ring *rx_ring); 645 struct pch_gbe_rx_ring *rx_ring);
646extern void pch_gbe_update_stats(struct pch_gbe_adapter *adapter); 646extern void pch_gbe_update_stats(struct pch_gbe_adapter *adapter);
647extern int pch_gbe_mdio_read(struct net_device *netdev, int addr, int reg); 647
648extern void pch_gbe_mdio_write(struct net_device *netdev, int addr, int reg,
649 int data);
650/* pch_gbe_param.c */ 648/* pch_gbe_param.c */
651extern void pch_gbe_check_options(struct pch_gbe_adapter *adapter); 649extern void pch_gbe_check_options(struct pch_gbe_adapter *adapter);
652 650
diff --git a/drivers/net/pch_gbe/pch_gbe_api.c b/drivers/net/pch_gbe/pch_gbe_api.c
index db53d2a943e0..e48f084ad226 100644
--- a/drivers/net/pch_gbe/pch_gbe_api.c
+++ b/drivers/net/pch_gbe/pch_gbe_api.c
@@ -97,7 +97,7 @@ static const struct pch_gbe_functions pch_gbe_ops = {
97 * pch_gbe_plat_init_function_pointers - Init func ptrs 97 * pch_gbe_plat_init_function_pointers - Init func ptrs
98 * @hw: Pointer to the HW structure 98 * @hw: Pointer to the HW structure
99 */ 99 */
100void pch_gbe_plat_init_function_pointers(struct pch_gbe_hw *hw) 100static void pch_gbe_plat_init_function_pointers(struct pch_gbe_hw *hw)
101{ 101{
102 /* Set PHY parameter */ 102 /* Set PHY parameter */
103 hw->phy.reset_delay_us = PCH_GBE_PHY_RESET_DELAY_US; 103 hw->phy.reset_delay_us = PCH_GBE_PHY_RESET_DELAY_US;
diff --git a/drivers/net/pch_gbe/pch_gbe_main.c b/drivers/net/pch_gbe/pch_gbe_main.c
index cf4b49d6c6da..472056b47440 100644
--- a/drivers/net/pch_gbe/pch_gbe_main.c
+++ b/drivers/net/pch_gbe/pch_gbe_main.c
@@ -85,6 +85,9 @@ const char pch_driver_version[] = DRV_VERSION;
85 85
86static unsigned int copybreak __read_mostly = PCH_GBE_COPYBREAK_DEFAULT; 86static unsigned int copybreak __read_mostly = PCH_GBE_COPYBREAK_DEFAULT;
87 87
88static int pch_gbe_mdio_read(struct net_device *netdev, int addr, int reg);
89static void pch_gbe_mdio_write(struct net_device *netdev, int addr, int reg,
90 int data);
88/** 91/**
89 * pch_gbe_mac_read_mac_addr - Read MAC address 92 * pch_gbe_mac_read_mac_addr - Read MAC address
90 * @hw: Pointer to the HW structure 93 * @hw: Pointer to the HW structure
@@ -114,7 +117,7 @@ s32 pch_gbe_mac_read_mac_addr(struct pch_gbe_hw *hw)
114 * @reg: Pointer of register 117 * @reg: Pointer of register
115 * @busy: Busy bit 118 * @busy: Busy bit
116 */ 119 */
117void pch_gbe_wait_clr_bit(void *reg, u32 bit) 120static void pch_gbe_wait_clr_bit(void *reg, u32 bit)
118{ 121{
119 u32 tmp; 122 u32 tmp;
120 /* wait busy */ 123 /* wait busy */
@@ -130,7 +133,7 @@ void pch_gbe_wait_clr_bit(void *reg, u32 bit)
130 * @addr: Pointer to the MAC address 133 * @addr: Pointer to the MAC address
131 * @index: MAC address array register 134 * @index: MAC address array register
132 */ 135 */
133void pch_gbe_mac_mar_set(struct pch_gbe_hw *hw, u8 * addr, u32 index) 136static void pch_gbe_mac_mar_set(struct pch_gbe_hw *hw, u8 * addr, u32 index)
134{ 137{
135 u32 mar_low, mar_high, adrmask; 138 u32 mar_low, mar_high, adrmask;
136 139
@@ -161,7 +164,7 @@ void pch_gbe_mac_mar_set(struct pch_gbe_hw *hw, u8 * addr, u32 index)
161 * pch_gbe_mac_reset_hw - Reset hardware 164 * pch_gbe_mac_reset_hw - Reset hardware
162 * @hw: Pointer to the HW structure 165 * @hw: Pointer to the HW structure
163 */ 166 */
164void pch_gbe_mac_reset_hw(struct pch_gbe_hw *hw) 167static void pch_gbe_mac_reset_hw(struct pch_gbe_hw *hw)
165{ 168{
166 /* Read the MAC address. and store to the private data */ 169 /* Read the MAC address. and store to the private data */
167 pch_gbe_mac_read_mac_addr(hw); 170 pch_gbe_mac_read_mac_addr(hw);
@@ -180,7 +183,7 @@ void pch_gbe_mac_reset_hw(struct pch_gbe_hw *hw)
180 * @hw: Pointer to the HW structure 183 * @hw: Pointer to the HW structure
181 * @mar_count: Receive address registers 184 * @mar_count: Receive address registers
182 */ 185 */
183void pch_gbe_mac_init_rx_addrs(struct pch_gbe_hw *hw, u16 mar_count) 186static void pch_gbe_mac_init_rx_addrs(struct pch_gbe_hw *hw, u16 mar_count)
184{ 187{
185 u32 i; 188 u32 i;
186 189
@@ -206,9 +209,9 @@ void pch_gbe_mac_init_rx_addrs(struct pch_gbe_hw *hw, u16 mar_count)
206 * @mar_used_count: The first MAC Address register free to program 209 * @mar_used_count: The first MAC Address register free to program
207 * @mar_total_num: Total number of supported MAC Address Registers 210 * @mar_total_num: Total number of supported MAC Address Registers
208 */ 211 */
209void pch_gbe_mac_mc_addr_list_update(struct pch_gbe_hw *hw, 212static void pch_gbe_mac_mc_addr_list_update(struct pch_gbe_hw *hw,
210 u8 *mc_addr_list, u32 mc_addr_count, 213 u8 *mc_addr_list, u32 mc_addr_count,
211 u32 mar_used_count, u32 mar_total_num) 214 u32 mar_used_count, u32 mar_total_num)
212{ 215{
213 u32 i, adrmask; 216 u32 i, adrmask;
214 217
@@ -285,7 +288,7 @@ s32 pch_gbe_mac_force_mac_fc(struct pch_gbe_hw *hw)
285 * @hw: Pointer to the HW structure 288 * @hw: Pointer to the HW structure
286 * @wu_evt: Wake up event 289 * @wu_evt: Wake up event
287 */ 290 */
288void pch_gbe_mac_set_wol_event(struct pch_gbe_hw *hw, u32 wu_evt) 291static void pch_gbe_mac_set_wol_event(struct pch_gbe_hw *hw, u32 wu_evt)
289{ 292{
290 u32 addr_mask; 293 u32 addr_mask;
291 294
@@ -359,7 +362,7 @@ u16 pch_gbe_mac_ctrl_miim(struct pch_gbe_hw *hw, u32 addr, u32 dir, u32 reg,
359 * pch_gbe_mac_set_pause_packet - Set pause packet 362 * pch_gbe_mac_set_pause_packet - Set pause packet
360 * @hw: Pointer to the HW structure 363 * @hw: Pointer to the HW structure
361 */ 364 */
362void pch_gbe_mac_set_pause_packet(struct pch_gbe_hw *hw) 365static void pch_gbe_mac_set_pause_packet(struct pch_gbe_hw *hw)
363{ 366{
364 unsigned long tmp2, tmp3; 367 unsigned long tmp2, tmp3;
365 368
@@ -482,7 +485,7 @@ static int pch_gbe_init_phy(struct pch_gbe_adapter *adapter)
482 * 0: Successfully 485 * 0: Successfully
483 * Negative value: Failed 486 * Negative value: Failed
484 */ 487 */
485int pch_gbe_mdio_read(struct net_device *netdev, int addr, int reg) 488static int pch_gbe_mdio_read(struct net_device *netdev, int addr, int reg)
486{ 489{
487 struct pch_gbe_adapter *adapter = netdev_priv(netdev); 490 struct pch_gbe_adapter *adapter = netdev_priv(netdev);
488 struct pch_gbe_hw *hw = &adapter->hw; 491 struct pch_gbe_hw *hw = &adapter->hw;
@@ -498,7 +501,8 @@ int pch_gbe_mdio_read(struct net_device *netdev, int addr, int reg)
498 * @reg: Access location 501 * @reg: Access location
499 * @data: Write data 502 * @data: Write data
500 */ 503 */
501void pch_gbe_mdio_write(struct net_device *netdev, int addr, int reg, int data) 504static void pch_gbe_mdio_write(struct net_device *netdev,
505 int addr, int reg, int data)
502{ 506{
503 struct pch_gbe_adapter *adapter = netdev_priv(netdev); 507 struct pch_gbe_adapter *adapter = netdev_priv(netdev);
504 struct pch_gbe_hw *hw = &adapter->hw; 508 struct pch_gbe_hw *hw = &adapter->hw;