aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/ipw2x00
diff options
context:
space:
mode:
authorRick Jones <rick.jones2@hp.com>2011-11-15 13:40:49 -0500
committerJohn W. Linville <linville@tuxdriver.com>2011-11-17 15:44:50 -0500
commit1f80c230a7d291a10045a3cdc2efd18a4185674d (patch)
treedcf356277b35b0584196675f084ca330a9392123 /drivers/net/wireless/ipw2x00
parent6048d76384ed531123588277fe1fd95b24067cbc (diff)
wireless: use strlcpy routine in .get_drvinfo
Convert various seemingly still compiled wireless drivers' .get_drvinfo routines to use the preferred strlcpy() routine. Signed-off-by: Rick Jones <rick.jones2@hp.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ipw2x00')
-rw-r--r--drivers/net/wireless/ipw2x00/ipw2100.c7
-rw-r--r--drivers/net/wireless/ipw2x00/ipw2200.c7
2 files changed, 8 insertions, 6 deletions
diff --git a/drivers/net/wireless/ipw2x00/ipw2100.c b/drivers/net/wireless/ipw2x00/ipw2100.c
index 127e9c63beaf..a0e5c21d3657 100644
--- a/drivers/net/wireless/ipw2x00/ipw2100.c
+++ b/drivers/net/wireless/ipw2x00/ipw2100.c
@@ -5981,8 +5981,8 @@ static void ipw_ethtool_get_drvinfo(struct net_device *dev,
5981 struct ipw2100_priv *priv = libipw_priv(dev); 5981 struct ipw2100_priv *priv = libipw_priv(dev);
5982 char fw_ver[64], ucode_ver[64]; 5982 char fw_ver[64], ucode_ver[64];
5983 5983
5984 strcpy(info->driver, DRV_NAME); 5984 strlcpy(info->driver, DRV_NAME, sizeof(info->driver));
5985 strcpy(info->version, DRV_VERSION); 5985 strlcpy(info->version, DRV_VERSION, sizeof(info->version));
5986 5986
5987 ipw2100_get_fwversion(priv, fw_ver, sizeof(fw_ver)); 5987 ipw2100_get_fwversion(priv, fw_ver, sizeof(fw_ver));
5988 ipw2100_get_ucodeversion(priv, ucode_ver, sizeof(ucode_ver)); 5988 ipw2100_get_ucodeversion(priv, ucode_ver, sizeof(ucode_ver));
@@ -5990,7 +5990,8 @@ static void ipw_ethtool_get_drvinfo(struct net_device *dev,
5990 snprintf(info->fw_version, sizeof(info->fw_version), "%s:%d:%s", 5990 snprintf(info->fw_version, sizeof(info->fw_version), "%s:%d:%s",
5991 fw_ver, priv->eeprom_version, ucode_ver); 5991 fw_ver, priv->eeprom_version, ucode_ver);
5992 5992
5993 strcpy(info->bus_info, pci_name(priv->pci_dev)); 5993 strlcpy(info->bus_info, pci_name(priv->pci_dev),
5994 sizeof(info->bus_info));
5994} 5995}
5995 5996
5996static u32 ipw2100_ethtool_get_link(struct net_device *dev) 5997static u32 ipw2100_ethtool_get_link(struct net_device *dev)
diff --git a/drivers/net/wireless/ipw2x00/ipw2200.c b/drivers/net/wireless/ipw2x00/ipw2200.c
index 99575884ff52..018a8deb88a8 100644
--- a/drivers/net/wireless/ipw2x00/ipw2200.c
+++ b/drivers/net/wireless/ipw2x00/ipw2200.c
@@ -10548,8 +10548,8 @@ static void ipw_ethtool_get_drvinfo(struct net_device *dev,
10548 char date[32]; 10548 char date[32];
10549 u32 len; 10549 u32 len;
10550 10550
10551 strcpy(info->driver, DRV_NAME); 10551 strlcpy(info->driver, DRV_NAME, sizeof(info->driver));
10552 strcpy(info->version, DRV_VERSION); 10552 strlcpy(info->version, DRV_VERSION, sizeof(info->version));
10553 10553
10554 len = sizeof(vers); 10554 len = sizeof(vers);
10555 ipw_get_ordinal(p, IPW_ORD_STAT_FW_VERSION, vers, &len); 10555 ipw_get_ordinal(p, IPW_ORD_STAT_FW_VERSION, vers, &len);
@@ -10558,7 +10558,8 @@ static void ipw_ethtool_get_drvinfo(struct net_device *dev,
10558 10558
10559 snprintf(info->fw_version, sizeof(info->fw_version), "%s (%s)", 10559 snprintf(info->fw_version, sizeof(info->fw_version), "%s (%s)",
10560 vers, date); 10560 vers, date);
10561 strcpy(info->bus_info, pci_name(p->pci_dev)); 10561 strlcpy(info->bus_info, pci_name(p->pci_dev),
10562 sizeof(info->bus_info));
10562 info->eedump_len = IPW_EEPROM_IMAGE_SIZE; 10563 info->eedump_len = IPW_EEPROM_IMAGE_SIZE;
10563} 10564}
10564 10565