aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/net/e100.c2
-rw-r--r--drivers/net/e1000/e1000_main.c2
-rw-r--r--drivers/net/ixgb/ixgb_main.c2
3 files changed, 3 insertions, 3 deletions
diff --git a/drivers/net/e100.c b/drivers/net/e100.c
index d9750e269a56..ab0868cb120c 100644
--- a/drivers/net/e100.c
+++ b/drivers/net/e100.c
@@ -2572,7 +2572,7 @@ static int __devinit e100_probe(struct pci_dev *pdev,
2572#ifdef CONFIG_NET_POLL_CONTROLLER 2572#ifdef CONFIG_NET_POLL_CONTROLLER
2573 netdev->poll_controller = e100_netpoll; 2573 netdev->poll_controller = e100_netpoll;
2574#endif 2574#endif
2575 strcpy(netdev->name, pci_name(pdev)); 2575 strncpy(netdev->name, pci_name(pdev), sizeof(netdev->name) - 1);
2576 2576
2577 nic = netdev_priv(netdev); 2577 nic = netdev_priv(netdev);
2578 nic->netdev = netdev; 2578 nic->netdev = netdev;
diff --git a/drivers/net/e1000/e1000_main.c b/drivers/net/e1000/e1000_main.c
index 082c02918a41..bd673802e8ce 100644
--- a/drivers/net/e1000/e1000_main.c
+++ b/drivers/net/e1000/e1000_main.c
@@ -759,7 +759,7 @@ e1000_probe(struct pci_dev *pdev,
759#ifdef CONFIG_NET_POLL_CONTROLLER 759#ifdef CONFIG_NET_POLL_CONTROLLER
760 netdev->poll_controller = e1000_netpoll; 760 netdev->poll_controller = e1000_netpoll;
761#endif 761#endif
762 strcpy(netdev->name, pci_name(pdev)); 762 strncpy(netdev->name, pci_name(pdev), sizeof(netdev->name) - 1);
763 763
764 netdev->mem_start = mmio_start; 764 netdev->mem_start = mmio_start;
765 netdev->mem_end = mmio_start + mmio_len; 765 netdev->mem_end = mmio_start + mmio_len;
diff --git a/drivers/net/ixgb/ixgb_main.c b/drivers/net/ixgb/ixgb_main.c
index a88c2b8b66b1..fb4c1ad745b2 100644
--- a/drivers/net/ixgb/ixgb_main.c
+++ b/drivers/net/ixgb/ixgb_main.c
@@ -437,7 +437,7 @@ ixgb_probe(struct pci_dev *pdev,
437 netdev->poll_controller = ixgb_netpoll; 437 netdev->poll_controller = ixgb_netpoll;
438#endif 438#endif
439 439
440 strcpy(netdev->name, pci_name(pdev)); 440 strncpy(netdev->name, pci_name(pdev), sizeof(netdev->name) - 1);
441 netdev->mem_start = mmio_start; 441 netdev->mem_start = mmio_start;
442 netdev->mem_end = mmio_start + mmio_len; 442 netdev->mem_end = mmio_start + mmio_len;
443 netdev->base_addr = adapter->hw.io_base; 443 netdev->base_addr = adapter->hw.io_base;