aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2009-01-16 12:40:11 -0800
committerLinus Torvalds <torvalds@linux-foundation.org>2009-01-16 12:40:11 -0800
commitabcea859783f63c9140ebd9fcb69580d0832f2c8 (patch)
treeb769dd06a0fcf8e86849f31fd1f62358eb7209d0
parentMerge git://git.kernel.org/pub/scm/linux/kernel/git/mason/btrfs-unstable (diff)
parentnetxen: include ipv6.h (fixes build failure) (diff)
downloadlinux-dev-abcea859783f63c9140ebd9fcb69580d0832f2c8.tar.xz
linux-dev-abcea859783f63c9140ebd9fcb69580d0832f2c8.zip
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6: netxen: include ipv6.h (fixes build failure) netxen: avoid invalid iounmap
-rw-r--r--drivers/net/netxen/netxen_nic_main.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/net/netxen/netxen_nic_main.c b/drivers/net/netxen/netxen_nic_main.c
index 86867405a367..d854f07ef4d3 100644
--- a/drivers/net/netxen/netxen_nic_main.c
+++ b/drivers/net/netxen/netxen_nic_main.c
@@ -41,6 +41,7 @@
#include <linux/dma-mapping.h>
#include <linux/if_vlan.h>
#include <net/ip.h>
+#include <linux/ipv6.h>
MODULE_DESCRIPTION("NetXen Multi port (1/10) Gigabit Network Driver");
MODULE_LICENSE("GPL");
@@ -1004,8 +1005,10 @@ static void __devexit netxen_nic_remove(struct pci_dev *pdev)
iounmap(adapter->ahw.db_base);
iounmap(adapter->ahw.pci_base0);
- iounmap(adapter->ahw.pci_base1);
- iounmap(adapter->ahw.pci_base2);
+ if (adapter->ahw.pci_base1 != NULL)
+ iounmap(adapter->ahw.pci_base1);
+ if (adapter->ahw.pci_base2 != NULL)
+ iounmap(adapter->ahw.pci_base2);
pci_release_regions(pdev);
pci_disable_device(pdev);