diff options
author | Kalle Valo <kvalo@qca.qualcomm.com> | 2011-11-14 19:31:07 +0200 |
---|---|---|
committer | Kalle Valo <kvalo@qca.qualcomm.com> | 2011-11-16 10:22:33 +0200 |
commit | 0d0192babc2f5ff9a5c047e61567d414806c1137 (patch) | |
tree | 98e52b57d1b06712575ed7419729690a02068db8 /drivers | |
parent | 293badf4e2fcb81aeab92616856c65fedc454c94 (diff) | |
download | linux-0d0192babc2f5ff9a5c047e61567d414806c1137.tar.bz2 |
ath6kl: use hardware version names consistently
Part of ath6kl uses "REV3" style of naming hardware versions and elsewhere
"hw 2.1.1" is used instead for the same version. This is confusing, use
the latter term everywhere.
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/wireless/ath/ath6kl/core.h | 60 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath6kl/init.c | 88 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath6kl/sdio.c | 20 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath6kl/usb.c | 12 |
4 files changed, 91 insertions, 89 deletions
diff --git a/drivers/net/wireless/ath/ath6kl/core.h b/drivers/net/wireless/ath/ath6kl/core.h index b034001a97a6..b14ad11f3147 100644 --- a/drivers/net/wireless/ath/ath6kl/core.h +++ b/drivers/net/wireless/ath/ath6kl/core.h @@ -89,44 +89,46 @@ struct ath6kl_fw_ie { }; /* AR6003 1.0 definitions */ -#define AR6003_REV1_VERSION 0x300002ba +#define AR6003_HW_1_0_VERSION 0x300002ba /* AR6003 2.0 definitions */ -#define AR6003_REV2_VERSION 0x30000384 -#define AR6003_REV2_PATCH_DOWNLOAD_ADDRESS 0x57e910 -#define AR6003_REV2_OTP_FILE "ath6k/AR6003/hw2.0/otp.bin.z77" -#define AR6003_REV2_FIRMWARE_FILE "ath6k/AR6003/hw2.0/athwlan.bin.z77" -#define AR6003_REV2_TCMD_FIRMWARE_FILE "ath6k/AR6003/hw2.0/athtcmd_ram.bin" -#define AR6003_REV2_PATCH_FILE "ath6k/AR6003/hw2.0/data.patch.bin" -#define AR6003_REV2_FIRMWARE_2_FILE "ath6k/AR6003/hw2.0/fw-2.bin" -#define AR6003_REV2_BOARD_DATA_FILE "ath6k/AR6003/hw2.0/bdata.bin" -#define AR6003_REV2_DEFAULT_BOARD_DATA_FILE "ath6k/AR6003/hw2.0/bdata.SD31.bin" +#define AR6003_HW_2_0_VERSION 0x30000384 +#define AR6003_HW_2_0_PATCH_DOWNLOAD_ADDRESS 0x57e910 +#define AR6003_HW_2_0_OTP_FILE "ath6k/AR6003/hw2.0/otp.bin.z77" +#define AR6003_HW_2_0_FIRMWARE_FILE "ath6k/AR6003/hw2.0/athwlan.bin.z77" +#define AR6003_HW_2_0_TCMD_FIRMWARE_FILE "ath6k/AR6003/hw2.0/athtcmd_ram.bin" +#define AR6003_HW_2_0_PATCH_FILE "ath6k/AR6003/hw2.0/data.patch.bin" +#define AR6003_HW_2_0_FIRMWARE_2_FILE "ath6k/AR6003/hw2.0/fw-2.bin" +#define AR6003_HW_2_0_BOARD_DATA_FILE "ath6k/AR6003/hw2.0/bdata.bin" +#define AR6003_HW_2_0_DEFAULT_BOARD_DATA_FILE \ + "ath6k/AR6003/hw2.0/bdata.SD31.bin" /* AR6003 3.0 definitions */ -#define AR6003_REV3_VERSION 0x30000582 -#define AR6003_REV3_OTP_FILE "ath6k/AR6003/hw2.1.1/otp.bin" -#define AR6003_REV3_FIRMWARE_FILE "ath6k/AR6003/hw2.1.1/athwlan.bin" -#define AR6003_REV3_TCMD_FIRMWARE_FILE "ath6k/AR6003/hw2.1.1/athtcmd_ram.bin" -#define AR6003_REV3_PATCH_FILE "ath6k/AR6003/hw2.1.1/data.patch.bin" -#define AR6003_REV3_FIRMWARE_2_FILE "ath6k/AR6003/hw2.1.1/fw-2.bin" -#define AR6003_REV3_BOARD_DATA_FILE "ath6k/AR6003/hw2.1.1/bdata.bin" -#define AR6003_REV3_DEFAULT_BOARD_DATA_FILE \ - "ath6k/AR6003/hw2.1.1/bdata.SD31.bin" +#define AR6003_HW_2_1_1_VERSION 0x30000582 +#define AR6003_HW_2_1_1_OTP_FILE "ath6k/AR6003/hw2.1.1/otp.bin" +#define AR6003_HW_2_1_1_FIRMWARE_FILE "ath6k/AR6003/hw2.1.1/athwlan.bin" +#define AR6003_HW_2_1_1_TCMD_FIRMWARE_FILE \ + "ath6k/AR6003/hw2.1.1/athtcmd_ram.bin" +#define AR6003_HW_2_1_1_PATCH_FILE "ath6k/AR6003/hw2.1.1/data.patch.bin" +#define AR6003_HW_2_1_1_FIRMWARE_2_FILE "ath6k/AR6003/hw2.1.1/fw-2.bin" +#define AR6003_HW_2_1_1_BOARD_DATA_FILE "ath6k/AR6003/hw2.1.1/bdata.bin" +#define AR6003_HW_2_1_1_DEFAULT_BOARD_DATA_FILE \ + "ath6k/AR6003/hw2.1.1/bdata.SD31.bin" /* AR6004 1.0 definitions */ -#define AR6004_REV1_VERSION 0x30000623 -#define AR6004_REV1_FIRMWARE_2_FILE "ath6k/AR6004/hw1.0/fw-2.bin" -#define AR6004_REV1_FIRMWARE_FILE "ath6k/AR6004/hw1.0/fw.ram.bin" -#define AR6004_REV1_BOARD_DATA_FILE "ath6k/AR6004/hw1.0/bdata.bin" -#define AR6004_REV1_DEFAULT_BOARD_DATA_FILE \ +#define AR6004_HW_1_0_VERSION 0x30000623 +#define AR6004_HW_1_0_FIRMWARE_2_FILE "ath6k/AR6004/hw1.0/fw-2.bin" +#define AR6004_HW_1_0_FIRMWARE_FILE "ath6k/AR6004/hw1.0/fw.ram.bin" +#define AR6004_HW_1_0_BOARD_DATA_FILE "ath6k/AR6004/hw1.0/bdata.bin" +#define AR6004_HW_1_0_DEFAULT_BOARD_DATA_FILE \ "ath6k/AR6004/hw1.0/bdata.DB132.bin" /* AR6004 1.1 definitions */ -#define AR6004_REV2_VERSION 0x30000001 -#define AR6004_REV2_FIRMWARE_2_FILE "ath6k/AR6004/hw1.1/fw-2.bin" -#define AR6004_REV2_FIRMWARE_FILE "ath6k/AR6004/hw1.1/fw.ram.bin" -#define AR6004_REV2_BOARD_DATA_FILE "ath6k/AR6004/hw1.1/bdata.bin" -#define AR6004_REV2_DEFAULT_BOARD_DATA_FILE \ +#define AR6004_HW_1_1_VERSION 0x30000001 +#define AR6004_HW_1_1_FIRMWARE_2_FILE "ath6k/AR6004/hw1.1/fw-2.bin" +#define AR6004_HW_1_1_FIRMWARE_FILE "ath6k/AR6004/hw1.1/fw.ram.bin" +#define AR6004_HW_1_1_BOARD_DATA_FILE "ath6k/AR6004/hw1.1/bdata.bin" +#define AR6004_HW_1_1_DEFAULT_BOARD_DATA_FILE \ "ath6k/AR6004/hw1.1/bdata.DB132.bin" /* Per STA data, used in AP mode */ diff --git a/drivers/net/wireless/ath/ath6kl/init.c b/drivers/net/wireless/ath/ath6kl/init.c index acfe79a0f1a1..208e77e3a90d 100644 --- a/drivers/net/wireless/ath/ath6kl/init.c +++ b/drivers/net/wireless/ath/ath6kl/init.c @@ -35,7 +35,7 @@ module_param(suspend_cutpower, bool, 0444); static const struct ath6kl_hw hw_list[] = { { - .id = AR6003_REV2_VERSION, + .id = AR6003_HW_2_0_VERSION, .name = "ar6003 hw 2.0", .dataset_patch_addr = 0x57e884, .app_load_addr = 0x543180, @@ -46,7 +46,7 @@ static const struct ath6kl_hw hw_list[] = { .app_start_override_addr = 0x944C00, }, { - .id = AR6003_REV3_VERSION, + .id = AR6003_HW_2_1_1_VERSION, .name = "ar6003 hw 2.1.1", .dataset_patch_addr = 0x57ff74, .app_load_addr = 0x1234, @@ -54,7 +54,7 @@ static const struct ath6kl_hw hw_list[] = { .reserved_ram_size = 512, }, { - .id = AR6004_REV1_VERSION, + .id = AR6004_HW_1_0_VERSION, .name = "ar6004 hw 1.0", .dataset_patch_addr = 0x57e884, .app_load_addr = 0x1234, @@ -63,7 +63,7 @@ static const struct ath6kl_hw hw_list[] = { .board_addr = 0x433900, }, { - .id = AR6004_REV2_VERSION, + .id = AR6004_HW_1_1_VERSION, .name = "ar6004 hw 1.1", .dataset_patch_addr = 0x57e884, .app_load_addr = 0x1234, @@ -590,11 +590,11 @@ static int ath6kl_get_fw(struct ath6kl *ar, const char *filename, static const char *get_target_ver_dir(const struct ath6kl *ar) { switch (ar->version.target_ver) { - case AR6003_REV1_VERSION: + case AR6003_HW_1_0_VERSION: return "ath6k/AR6003/hw1.0"; - case AR6003_REV2_VERSION: + case AR6003_HW_2_0_VERSION: return "ath6k/AR6003/hw2.0"; - case AR6003_REV3_VERSION: + case AR6003_HW_2_1_1_VERSION: return "ath6k/AR6003/hw2.1.1"; } ath6kl_warn("%s: unsupported target version 0x%x.\n", __func__, @@ -653,14 +653,14 @@ static int ath6kl_fetch_board_file(struct ath6kl *ar) return 0; switch (ar->version.target_ver) { - case AR6003_REV2_VERSION: - filename = AR6003_REV2_BOARD_DATA_FILE; + case AR6003_HW_2_0_VERSION: + filename = AR6003_HW_2_0_BOARD_DATA_FILE; break; - case AR6004_REV1_VERSION: - filename = AR6004_REV1_BOARD_DATA_FILE; + case AR6004_HW_1_0_VERSION: + filename = AR6004_HW_1_0_BOARD_DATA_FILE; break; default: - filename = AR6003_REV3_BOARD_DATA_FILE; + filename = AR6003_HW_2_1_1_BOARD_DATA_FILE; break; } @@ -681,14 +681,14 @@ static int ath6kl_fetch_board_file(struct ath6kl *ar) filename, ret); switch (ar->version.target_ver) { - case AR6003_REV2_VERSION: - filename = AR6003_REV2_DEFAULT_BOARD_DATA_FILE; + case AR6003_HW_2_0_VERSION: + filename = AR6003_HW_2_0_DEFAULT_BOARD_DATA_FILE; break; - case AR6004_REV1_VERSION: - filename = AR6004_REV1_DEFAULT_BOARD_DATA_FILE; + case AR6004_HW_1_0_VERSION: + filename = AR6004_HW_1_0_DEFAULT_BOARD_DATA_FILE; break; default: - filename = AR6003_REV3_DEFAULT_BOARD_DATA_FILE; + filename = AR6003_HW_2_1_1_DEFAULT_BOARD_DATA_FILE; break; } @@ -715,15 +715,15 @@ static int ath6kl_fetch_otp_file(struct ath6kl *ar) return 0; switch (ar->version.target_ver) { - case AR6003_REV2_VERSION: - filename = AR6003_REV2_OTP_FILE; + case AR6003_HW_2_0_VERSION: + filename = AR6003_HW_2_0_OTP_FILE; break; - case AR6004_REV1_VERSION: + case AR6004_HW_1_0_VERSION: ath6kl_dbg(ATH6KL_DBG_TRC, "AR6004 doesn't need OTP file\n"); return 0; break; default: - filename = AR6003_REV3_OTP_FILE; + filename = AR6003_HW_2_1_1_OTP_FILE; break; } @@ -748,13 +748,13 @@ static int ath6kl_fetch_fw_file(struct ath6kl *ar) if (testmode) { switch (ar->version.target_ver) { - case AR6003_REV2_VERSION: - filename = AR6003_REV2_TCMD_FIRMWARE_FILE; + case AR6003_HW_2_0_VERSION: + filename = AR6003_HW_2_0_TCMD_FIRMWARE_FILE; break; - case AR6003_REV3_VERSION: - filename = AR6003_REV3_TCMD_FIRMWARE_FILE; + case AR6003_HW_2_1_1_VERSION: + filename = AR6003_HW_2_1_1_TCMD_FIRMWARE_FILE; break; - case AR6004_REV1_VERSION: + case AR6004_HW_1_0_VERSION: ath6kl_warn("testmode not supported with ar6004\n"); return -EOPNOTSUPP; default: @@ -769,14 +769,14 @@ static int ath6kl_fetch_fw_file(struct ath6kl *ar) } switch (ar->version.target_ver) { - case AR6003_REV2_VERSION: - filename = AR6003_REV2_FIRMWARE_FILE; + case AR6003_HW_2_0_VERSION: + filename = AR6003_HW_2_0_FIRMWARE_FILE; break; - case AR6004_REV1_VERSION: - filename = AR6004_REV1_FIRMWARE_FILE; + case AR6004_HW_1_0_VERSION: + filename = AR6004_HW_1_0_FIRMWARE_FILE; break; default: - filename = AR6003_REV3_FIRMWARE_FILE; + filename = AR6003_HW_2_1_1_FIRMWARE_FILE; break; } @@ -797,15 +797,15 @@ static int ath6kl_fetch_patch_file(struct ath6kl *ar) int ret; switch (ar->version.target_ver) { - case AR6003_REV2_VERSION: - filename = AR6003_REV2_PATCH_FILE; + case AR6003_HW_2_0_VERSION: + filename = AR6003_HW_2_0_PATCH_FILE; break; - case AR6004_REV1_VERSION: + case AR6004_HW_1_0_VERSION: /* FIXME: implement for AR6004 */ return 0; break; default: - filename = AR6003_REV3_PATCH_FILE; + filename = AR6003_HW_2_1_1_PATCH_FILE; break; } @@ -852,17 +852,17 @@ static int ath6kl_fetch_fw_api2(struct ath6kl *ar) __le32 *val; switch (ar->version.target_ver) { - case AR6003_REV2_VERSION: - filename = AR6003_REV2_FIRMWARE_2_FILE; + case AR6003_HW_2_0_VERSION: + filename = AR6003_HW_2_0_FIRMWARE_2_FILE; break; - case AR6003_REV3_VERSION: - filename = AR6003_REV3_FIRMWARE_2_FILE; + case AR6003_HW_2_1_1_VERSION: + filename = AR6003_HW_2_1_1_FIRMWARE_2_FILE; break; - case AR6004_REV1_VERSION: - filename = AR6004_REV1_FIRMWARE_2_FILE; + case AR6004_HW_1_0_VERSION: + filename = AR6004_HW_1_0_FIRMWARE_2_FILE; break; - case AR6004_REV2_VERSION: - filename = AR6004_REV2_FIRMWARE_2_FILE; + case AR6004_HW_1_1_VERSION: + filename = AR6004_HW_1_1_FIRMWARE_2_FILE; break; default: return -EOPNOTSUPP; @@ -1313,7 +1313,7 @@ static int ath6kl_init_upload(struct ath6kl *ar) return status; /* WAR to avoid SDIO CRC err */ - if (ar->version.target_ver == AR6003_REV2_VERSION) { + if (ar->version.target_ver == AR6003_HW_2_0_VERSION) { ath6kl_err("temporary war to avoid sdio crc error\n"); param = 0x20; diff --git a/drivers/net/wireless/ath/ath6kl/sdio.c b/drivers/net/wireless/ath/ath6kl/sdio.c index fff2f90e7a19..c0edf0be584e 100644 --- a/drivers/net/wireless/ath/ath6kl/sdio.c +++ b/drivers/net/wireless/ath/ath6kl/sdio.c @@ -1328,13 +1328,13 @@ MODULE_AUTHOR("Atheros Communications, Inc."); MODULE_DESCRIPTION("Driver support for Atheros AR600x SDIO devices"); MODULE_LICENSE("Dual BSD/GPL"); -MODULE_FIRMWARE(AR6003_REV2_OTP_FILE); -MODULE_FIRMWARE(AR6003_REV2_FIRMWARE_FILE); -MODULE_FIRMWARE(AR6003_REV2_PATCH_FILE); -MODULE_FIRMWARE(AR6003_REV2_BOARD_DATA_FILE); -MODULE_FIRMWARE(AR6003_REV2_DEFAULT_BOARD_DATA_FILE); -MODULE_FIRMWARE(AR6003_REV3_OTP_FILE); -MODULE_FIRMWARE(AR6003_REV3_FIRMWARE_FILE); -MODULE_FIRMWARE(AR6003_REV3_PATCH_FILE); -MODULE_FIRMWARE(AR6003_REV3_BOARD_DATA_FILE); -MODULE_FIRMWARE(AR6003_REV3_DEFAULT_BOARD_DATA_FILE); +MODULE_FIRMWARE(AR6003_HW_2_0_OTP_FILE); +MODULE_FIRMWARE(AR6003_HW_2_0_FIRMWARE_FILE); +MODULE_FIRMWARE(AR6003_HW_2_0_PATCH_FILE); +MODULE_FIRMWARE(AR6003_HW_2_0_BOARD_DATA_FILE); +MODULE_FIRMWARE(AR6003_HW_2_0_DEFAULT_BOARD_DATA_FILE); +MODULE_FIRMWARE(AR6003_HW_2_1_1_OTP_FILE); +MODULE_FIRMWARE(AR6003_HW_2_1_1_FIRMWARE_FILE); +MODULE_FIRMWARE(AR6003_HW_2_1_1_PATCH_FILE); +MODULE_FIRMWARE(AR6003_HW_2_1_1_BOARD_DATA_FILE); +MODULE_FIRMWARE(AR6003_HW_2_1_1_DEFAULT_BOARD_DATA_FILE); diff --git a/drivers/net/wireless/ath/ath6kl/usb.c b/drivers/net/wireless/ath/ath6kl/usb.c index b85ca3f29f32..e3cf397fcafe 100644 --- a/drivers/net/wireless/ath/ath6kl/usb.c +++ b/drivers/net/wireless/ath/ath6kl/usb.c @@ -423,9 +423,9 @@ module_exit(ath6kl_usb_exit); MODULE_AUTHOR("Atheros Communications, Inc."); MODULE_DESCRIPTION("Driver support for Atheros AR600x USB devices"); MODULE_LICENSE("Dual BSD/GPL"); -MODULE_FIRMWARE(AR6004_REV1_FIRMWARE_FILE); -MODULE_FIRMWARE(AR6004_REV1_BOARD_DATA_FILE); -MODULE_FIRMWARE(AR6004_REV1_DEFAULT_BOARD_DATA_FILE); -MODULE_FIRMWARE(AR6004_REV2_FIRMWARE_FILE); -MODULE_FIRMWARE(AR6004_REV2_BOARD_DATA_FILE); -MODULE_FIRMWARE(AR6004_REV2_DEFAULT_BOARD_DATA_FILE); +MODULE_FIRMWARE(AR6004_HW_1_0_FIRMWARE_FILE); +MODULE_FIRMWARE(AR6004_HW_1_0_BOARD_DATA_FILE); +MODULE_FIRMWARE(AR6004_HW_1_0_DEFAULT_BOARD_DATA_FILE); +MODULE_FIRMWARE(AR6004_HW_1_1_FIRMWARE_FILE); +MODULE_FIRMWARE(AR6004_HW_1_1_BOARD_DATA_FILE); +MODULE_FIRMWARE(AR6004_HW_1_1_DEFAULT_BOARD_DATA_FILE); |