zd1211rw: update fw version info in wiphy struct

This makes the information available through ethtool...

Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
John W. Linville 2010-07-29 13:58:48 -04:00
parent dd358c9a45
commit 68e887ef21
1 changed files with 5 additions and 0 deletions

View File

@ -973,6 +973,7 @@ static void dump_fw_registers(struct zd_chip *chip)
static int print_fw_version(struct zd_chip *chip)
{
struct wiphy *wiphy = zd_chip_to_mac(chip)->hw->wiphy;
int r;
u16 version;
@ -982,6 +983,10 @@ static int print_fw_version(struct zd_chip *chip)
return r;
dev_info(zd_chip_dev(chip),"firmware version %04hx\n", version);
snprintf(wiphy->fw_version, sizeof(wiphy->fw_version),
"%04hx", version);
return 0;
}