diff options
author | Roland Dreier <rdreier@cisco.com> | 2008-01-29 17:45:11 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-02-03 07:28:35 -0500 |
commit | 7b9b09436b8720621e5594ce25fd25f34d5d42be (patch) | |
tree | dbcf98ca8f2485d20c50411a50c058f2df602e80 /drivers/net/cxgb3 | |
parent | d96c75a3d170a7c9a1ef062cb6d7a65730a34f22 (diff) |
cxgb3: Remove incorrect __devinit annotations
When PCI error recovery was added to cxgb3, a function t3_io_slot_reset()
was added. This function can call back into t3_prep_adapter() at any
time, so t3_prep_adapter() can no longer be marked __devinit.
This patch removes the __devinit annotation from t3_prep_adapter() and
all the functions that it calls, which fixes
WARNING: drivers/net/cxgb3/built-in.o(.text+0x2427): Section mismatch in reference from the function t3_io_slot_reset() to the function .devinit.text:t3_prep_adapter()
Signed-off-by: Roland Dreier <rolandd@cisco.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/cxgb3')
-rw-r--r-- | drivers/net/cxgb3/mc5.c | 2 | ||||
-rw-r--r-- | drivers/net/cxgb3/sge.c | 2 | ||||
-rw-r--r-- | drivers/net/cxgb3/t3_hw.c | 22 |
3 files changed, 12 insertions, 14 deletions
diff --git a/drivers/net/cxgb3/mc5.c b/drivers/net/cxgb3/mc5.c index 84c1ffa8e2d3..4c4d6e877ea6 100644 --- a/drivers/net/cxgb3/mc5.c +++ b/drivers/net/cxgb3/mc5.c | |||
@@ -452,7 +452,7 @@ void t3_mc5_intr_handler(struct mc5 *mc5) | |||
452 | t3_write_reg(adap, A_MC5_DB_INT_CAUSE, cause); | 452 | t3_write_reg(adap, A_MC5_DB_INT_CAUSE, cause); |
453 | } | 453 | } |
454 | 454 | ||
455 | void __devinit t3_mc5_prep(struct adapter *adapter, struct mc5 *mc5, int mode) | 455 | void t3_mc5_prep(struct adapter *adapter, struct mc5 *mc5, int mode) |
456 | { | 456 | { |
457 | #define K * 1024 | 457 | #define K * 1024 |
458 | 458 | ||
diff --git a/drivers/net/cxgb3/sge.c b/drivers/net/cxgb3/sge.c index cb684d30831f..9ca8c66abd16 100644 --- a/drivers/net/cxgb3/sge.c +++ b/drivers/net/cxgb3/sge.c | |||
@@ -2836,7 +2836,7 @@ void t3_sge_init(struct adapter *adap, struct sge_params *p) | |||
2836 | * defaults for the assorted SGE parameters, which admins can change until | 2836 | * defaults for the assorted SGE parameters, which admins can change until |
2837 | * they are used to initialize the SGE. | 2837 | * they are used to initialize the SGE. |
2838 | */ | 2838 | */ |
2839 | void __devinit t3_sge_prep(struct adapter *adap, struct sge_params *p) | 2839 | void t3_sge_prep(struct adapter *adap, struct sge_params *p) |
2840 | { | 2840 | { |
2841 | int i; | 2841 | int i; |
2842 | 2842 | ||
diff --git a/drivers/net/cxgb3/t3_hw.c b/drivers/net/cxgb3/t3_hw.c index 7469935877bd..a99496a431c4 100644 --- a/drivers/net/cxgb3/t3_hw.c +++ b/drivers/net/cxgb3/t3_hw.c | |||
@@ -2675,7 +2675,7 @@ void t3_tp_set_max_rxsize(struct adapter *adap, unsigned int size) | |||
2675 | V_PMMAXXFERLEN0(size) | V_PMMAXXFERLEN1(size)); | 2675 | V_PMMAXXFERLEN0(size) | V_PMMAXXFERLEN1(size)); |
2676 | } | 2676 | } |
2677 | 2677 | ||
2678 | static void __devinit init_mtus(unsigned short mtus[]) | 2678 | static void init_mtus(unsigned short mtus[]) |
2679 | { | 2679 | { |
2680 | /* | 2680 | /* |
2681 | * See draft-mathis-plpmtud-00.txt for the values. The min is 88 so | 2681 | * See draft-mathis-plpmtud-00.txt for the values. The min is 88 so |
@@ -2703,7 +2703,7 @@ static void __devinit init_mtus(unsigned short mtus[]) | |||
2703 | /* | 2703 | /* |
2704 | * Initial congestion control parameters. | 2704 | * Initial congestion control parameters. |
2705 | */ | 2705 | */ |
2706 | static void __devinit init_cong_ctrl(unsigned short *a, unsigned short *b) | 2706 | static void init_cong_ctrl(unsigned short *a, unsigned short *b) |
2707 | { | 2707 | { |
2708 | a[0] = a[1] = a[2] = a[3] = a[4] = a[5] = a[6] = a[7] = a[8] = 1; | 2708 | a[0] = a[1] = a[2] = a[3] = a[4] = a[5] = a[6] = a[7] = a[8] = 1; |
2709 | a[9] = 2; | 2709 | a[9] = 2; |
@@ -3354,8 +3354,7 @@ out_err: | |||
3354 | * Determines a card's PCI mode and associated parameters, such as speed | 3354 | * Determines a card's PCI mode and associated parameters, such as speed |
3355 | * and width. | 3355 | * and width. |
3356 | */ | 3356 | */ |
3357 | static void __devinit get_pci_mode(struct adapter *adapter, | 3357 | static void get_pci_mode(struct adapter *adapter, struct pci_params *p) |
3358 | struct pci_params *p) | ||
3359 | { | 3358 | { |
3360 | static unsigned short speed_map[] = { 33, 66, 100, 133 }; | 3359 | static unsigned short speed_map[] = { 33, 66, 100, 133 }; |
3361 | u32 pci_mode, pcie_cap; | 3360 | u32 pci_mode, pcie_cap; |
@@ -3395,8 +3394,7 @@ static void __devinit get_pci_mode(struct adapter *adapter, | |||
3395 | * capabilities and default speed/duplex/flow-control/autonegotiation | 3394 | * capabilities and default speed/duplex/flow-control/autonegotiation |
3396 | * settings. | 3395 | * settings. |
3397 | */ | 3396 | */ |
3398 | static void __devinit init_link_config(struct link_config *lc, | 3397 | static void init_link_config(struct link_config *lc, unsigned int caps) |
3399 | unsigned int caps) | ||
3400 | { | 3398 | { |
3401 | lc->supported = caps; | 3399 | lc->supported = caps; |
3402 | lc->requested_speed = lc->speed = SPEED_INVALID; | 3400 | lc->requested_speed = lc->speed = SPEED_INVALID; |
@@ -3419,7 +3417,7 @@ static void __devinit init_link_config(struct link_config *lc, | |||
3419 | * Calculates the size of an MC7 memory in bytes from the value of its | 3417 | * Calculates the size of an MC7 memory in bytes from the value of its |
3420 | * configuration register. | 3418 | * configuration register. |
3421 | */ | 3419 | */ |
3422 | static unsigned int __devinit mc7_calc_size(u32 cfg) | 3420 | static unsigned int mc7_calc_size(u32 cfg) |
3423 | { | 3421 | { |
3424 | unsigned int width = G_WIDTH(cfg); | 3422 | unsigned int width = G_WIDTH(cfg); |
3425 | unsigned int banks = !!(cfg & F_BKS) + 1; | 3423 | unsigned int banks = !!(cfg & F_BKS) + 1; |
@@ -3430,8 +3428,8 @@ static unsigned int __devinit mc7_calc_size(u32 cfg) | |||
3430 | return MBs << 20; | 3428 | return MBs << 20; |
3431 | } | 3429 | } |
3432 | 3430 | ||
3433 | static void __devinit mc7_prep(struct adapter *adapter, struct mc7 *mc7, | 3431 | static void mc7_prep(struct adapter *adapter, struct mc7 *mc7, |
3434 | unsigned int base_addr, const char *name) | 3432 | unsigned int base_addr, const char *name) |
3435 | { | 3433 | { |
3436 | u32 cfg; | 3434 | u32 cfg; |
3437 | 3435 | ||
@@ -3517,7 +3515,7 @@ static int t3_reset_adapter(struct adapter *adapter) | |||
3517 | return 0; | 3515 | return 0; |
3518 | } | 3516 | } |
3519 | 3517 | ||
3520 | static int __devinit init_parity(struct adapter *adap) | 3518 | static int init_parity(struct adapter *adap) |
3521 | { | 3519 | { |
3522 | int i, err, addr; | 3520 | int i, err, addr; |
3523 | 3521 | ||
@@ -3552,8 +3550,8 @@ static int __devinit init_parity(struct adapter *adap) | |||
3552 | * for some adapter tunables, take PHYs out of reset, and initialize the MDIO | 3550 | * for some adapter tunables, take PHYs out of reset, and initialize the MDIO |
3553 | * interface. | 3551 | * interface. |
3554 | */ | 3552 | */ |
3555 | int __devinit t3_prep_adapter(struct adapter *adapter, | 3553 | int t3_prep_adapter(struct adapter *adapter, const struct adapter_info *ai, |
3556 | const struct adapter_info *ai, int reset) | 3554 | int reset) |
3557 | { | 3555 | { |
3558 | int ret; | 3556 | int ret; |
3559 | unsigned int i, j = 0; | 3557 | unsigned int i, j = 0; |