net: use ETHTOOL_FWVERS_LEN instead of ETHTOOL_BUSINFO_LEN for fw_ver strings
authorJiri Pirko <jiri@resnulli.us>
Sun, 6 Jan 2013 02:12:51 +0000 (02:12 +0000)
committerDavid S. Miller <davem@davemloft.net>
Mon, 7 Jan 2013 05:06:31 +0000 (21:06 -0800)
Signed-off-by: Jiri Pirko <jiri@resnulli.us>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/wireless/ath/ath9k/htc_drv_init.c
drivers/net/wireless/iwlwifi/iwl-fw.h
drivers/net/wireless/ti/wlcore/wlcore_i.h
include/net/cfg80211.h

index 05d5ba66cac3588f64e8f6ab0545af76fbf88cbb..b2f85cb5ed308f98a2c9ce652fdff013bc95a301 100644 (file)
@@ -783,7 +783,7 @@ static int ath9k_init_firmware_version(struct ath9k_htc_priv *priv)
        priv->fw_version_major = be16_to_cpu(cmd_rsp.major);
        priv->fw_version_minor = be16_to_cpu(cmd_rsp.minor);
 
-       snprintf(hw->wiphy->fw_version, ETHTOOL_BUSINFO_LEN, "%d.%d",
+       snprintf(hw->wiphy->fw_version, sizeof(hw->wiphy->fw_version), "%d.%d",
                 priv->fw_version_major,
                 priv->fw_version_minor);
 
index d1a86b66bc51ee6fab8e797e8aa458b9db3812ea..715291eb7f8e8070d576a5e91341a354a56a1c34 100644 (file)
@@ -157,7 +157,7 @@ struct fw_img {
 struct iwl_fw {
        u32 ucode_ver;
 
-       char fw_version[ETHTOOL_BUSINFO_LEN];
+       char fw_version[ETHTOOL_FWVERS_LEN];
 
        /* ucode images */
        struct fw_img img[IWL_UCODE_TYPE_MAX];
index 6678d4b18611556be7617b6ff79dab0dad851d14..5ce26cf402fcf2b68ebc998dec1aaba258a9d949 100644 (file)
@@ -122,9 +122,9 @@ enum {
 
 struct wl1271_chip {
        u32 id;
-       char fw_ver_str[ETHTOOL_BUSINFO_LEN];
+       char fw_ver_str[ETHTOOL_FWVERS_LEN];
        unsigned int fw_ver[NUM_FW_VER];
-       char phy_fw_ver_str[ETHTOOL_BUSINFO_LEN];
+       char phy_fw_ver_str[ETHTOOL_FWVERS_LEN];
 };
 
 #define NUM_TX_QUEUES              4
index 8e6a6b73b9c9ecc3f8f221c4ff32a9983940dde4..f78fa19a07b0bba0bcefb9c4951f7092e6574e79 100644 (file)
@@ -2333,7 +2333,7 @@ struct wiphy {
        u32 rts_threshold;
        u8 coverage_class;
 
-       char fw_version[ETHTOOL_BUSINFO_LEN];
+       char fw_version[ETHTOOL_FWVERS_LEN];
        u32 hw_version;
 
 #ifdef CONFIG_PM