diff options
author | Michael Chan <mchan@broadcom.com> | 2009-08-14 11:49:43 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-08-15 21:50:42 -0400 |
commit | 64c6460875957502541a4ba30835ac625a0bee79 (patch) | |
tree | 2e8f6b993b05c856a071e66f66064fbf7f64d300 /drivers | |
parent | 8cdb045632e5ee22854538619ac6f150eb0a4894 (diff) |
cnic: Fix symbol_put_addr() panic on ia64.
When the cnic driver tries to grab a symbol from bnx2 when bnx2 is
running init code, symbol_get() will succeed but symbol_put_addr()
will hit BUG() a moment later. module_text_address() fails because
bnx2 is still in init code.
This is fixed by using symbol_put() instead which does the exact
opposite of symbol_get().
Signed-off-by: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/cnic.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/cnic.c b/drivers/net/cnic.c index 4869d77cbe91..ecde186fccd6 100644 --- a/drivers/net/cnic.c +++ b/drivers/net/cnic.c | |||
@@ -2543,7 +2543,7 @@ static struct cnic_dev *init_bnx2_cnic(struct net_device *dev) | |||
2543 | probe = symbol_get(bnx2_cnic_probe); | 2543 | probe = symbol_get(bnx2_cnic_probe); |
2544 | if (probe) { | 2544 | if (probe) { |
2545 | ethdev = (*probe)(dev); | 2545 | ethdev = (*probe)(dev); |
2546 | symbol_put_addr(probe); | 2546 | symbol_put(bnx2_cnic_probe); |
2547 | } | 2547 | } |
2548 | if (!ethdev) | 2548 | if (!ethdev) |
2549 | return NULL; | 2549 | return NULL; |