Skip to content

Commit 2910594

Browse files
committed
Merge tag 'wireless-drivers-2020-03-25' of git://git.kernel.org/pub/scm/linux/kernel/git/kvalo/wireless-drivers
Kalle Valo says: ==================== wireless-drivers fixes for v5.6 Fourth, and last, set of fixes for v5.6. Just two important fixes to iwlwifi regressions. iwlwifi * fix GEO_TX_POWER_LIMIT command on certain devices which caused firmware to crash during initialisation * add back device ids for three devices which were accidentally removed ==================== Signed-off-by: David S. Miller <[email protected]>
2 parents 2c64605 + 0433ae5 commit 2910594

File tree

4 files changed

+27
-13
lines changed

4 files changed

+27
-13
lines changed

drivers/net/wireless/intel/iwlwifi/fw/acpi.c

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
* GPL LICENSE SUMMARY
77
*
88
* Copyright(c) 2017 Intel Deutschland GmbH
9-
* Copyright (C) 2019 Intel Corporation
9+
* Copyright (C) 2019 - 2020 Intel Corporation
1010
*
1111
* This program is free software; you can redistribute it and/or modify
1212
* it under the terms of version 2 of the GNU General Public License as
@@ -27,7 +27,7 @@
2727
* BSD LICENSE
2828
*
2929
* Copyright(c) 2017 Intel Deutschland GmbH
30-
* Copyright (C) 2019 Intel Corporation
30+
* Copyright (C) 2019 - 2020 Intel Corporation
3131
* All rights reserved.
3232
*
3333
* Redistribution and use in source and binary forms, with or without
@@ -491,21 +491,21 @@ int iwl_validate_sar_geo_profile(struct iwl_fw_runtime *fwrt,
491491
}
492492
IWL_EXPORT_SYMBOL(iwl_validate_sar_geo_profile);
493493

494-
void iwl_sar_geo_init(struct iwl_fw_runtime *fwrt,
495-
struct iwl_per_chain_offset_group *table)
494+
int iwl_sar_geo_init(struct iwl_fw_runtime *fwrt,
495+
struct iwl_per_chain_offset_group *table)
496496
{
497497
int ret, i, j;
498498

499499
if (!iwl_sar_geo_support(fwrt))
500-
return;
500+
return -EOPNOTSUPP;
501501

502502
ret = iwl_sar_get_wgds_table(fwrt);
503503
if (ret < 0) {
504504
IWL_DEBUG_RADIO(fwrt,
505505
"Geo SAR BIOS table invalid or unavailable. (%d)\n",
506506
ret);
507507
/* we don't fail if the table is not available */
508-
return;
508+
return -ENOENT;
509509
}
510510

511511
BUILD_BUG_ON(ACPI_NUM_GEO_PROFILES * ACPI_WGDS_NUM_BANDS *
@@ -530,5 +530,7 @@ void iwl_sar_geo_init(struct iwl_fw_runtime *fwrt,
530530
i, j, value[1], value[2], value[0]);
531531
}
532532
}
533+
534+
return 0;
533535
}
534536
IWL_EXPORT_SYMBOL(iwl_sar_geo_init);

drivers/net/wireless/intel/iwlwifi/fw/acpi.h

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
* GPL LICENSE SUMMARY
77
*
88
* Copyright(c) 2017 Intel Deutschland GmbH
9-
* Copyright(c) 2018 - 2019 Intel Corporation
9+
* Copyright(c) 2018 - 2020 Intel Corporation
1010
*
1111
* This program is free software; you can redistribute it and/or modify
1212
* it under the terms of version 2 of the GNU General Public License as
@@ -27,7 +27,7 @@
2727
* BSD LICENSE
2828
*
2929
* Copyright(c) 2017 Intel Deutschland GmbH
30-
* Copyright(c) 2018 - 2019 Intel Corporation
30+
* Copyright(c) 2018 - 2020 Intel Corporation
3131
* All rights reserved.
3232
*
3333
* Redistribution and use in source and binary forms, with or without
@@ -171,8 +171,9 @@ bool iwl_sar_geo_support(struct iwl_fw_runtime *fwrt);
171171
int iwl_validate_sar_geo_profile(struct iwl_fw_runtime *fwrt,
172172
struct iwl_host_cmd *cmd);
173173

174-
void iwl_sar_geo_init(struct iwl_fw_runtime *fwrt,
175-
struct iwl_per_chain_offset_group *table);
174+
int iwl_sar_geo_init(struct iwl_fw_runtime *fwrt,
175+
struct iwl_per_chain_offset_group *table);
176+
176177
#else /* CONFIG_ACPI */
177178

178179
static inline void *iwl_acpi_get_object(struct device *dev, acpi_string method)
@@ -243,9 +244,10 @@ static inline int iwl_validate_sar_geo_profile(struct iwl_fw_runtime *fwrt,
243244
return -ENOENT;
244245
}
245246

246-
static inline void iwl_sar_geo_init(struct iwl_fw_runtime *fwrt,
247-
struct iwl_per_chain_offset_group *table)
247+
static inline int iwl_sar_geo_init(struct iwl_fw_runtime *fwrt,
248+
struct iwl_per_chain_offset_group *table)
248249
{
250+
return -ENOENT;
249251
}
250252

251253
#endif /* CONFIG_ACPI */

drivers/net/wireless/intel/iwlwifi/mvm/fw.c

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -762,10 +762,17 @@ static int iwl_mvm_sar_geo_init(struct iwl_mvm *mvm)
762762
u16 cmd_wide_id = WIDE_ID(PHY_OPS_GROUP, GEO_TX_POWER_LIMIT);
763763
union geo_tx_power_profiles_cmd cmd;
764764
u16 len;
765+
int ret;
765766

766767
cmd.geo_cmd.ops = cpu_to_le32(IWL_PER_CHAIN_OFFSET_SET_TABLES);
767768

768-
iwl_sar_geo_init(&mvm->fwrt, cmd.geo_cmd.table);
769+
ret = iwl_sar_geo_init(&mvm->fwrt, cmd.geo_cmd.table);
770+
/*
771+
* It is a valid scenario to not support SAR, or miss wgds table,
772+
* but in that case there is no need to send the command.
773+
*/
774+
if (ret)
775+
return 0;
769776

770777
cmd.geo_cmd.table_revision = cpu_to_le32(mvm->fwrt.geo_rev);
771778

drivers/net/wireless/intel/iwlwifi/pcie/drv.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -981,6 +981,9 @@ static const struct iwl_dev_info iwl_dev_info_table[] = {
981981
IWL_DEV_INFO(0x2526, 0x0014, iwl9260_2ac_160_cfg, iwl9260_160_name),
982982
IWL_DEV_INFO(0x2526, 0x0018, iwl9260_2ac_160_cfg, iwl9260_160_name),
983983
IWL_DEV_INFO(0x2526, 0x001C, iwl9260_2ac_160_cfg, iwl9260_160_name),
984+
IWL_DEV_INFO(0x2526, 0x4010, iwl9260_2ac_160_cfg, iwl9260_160_name),
985+
IWL_DEV_INFO(0x2526, 0x4018, iwl9260_2ac_160_cfg, iwl9260_160_name),
986+
IWL_DEV_INFO(0x2526, 0x401C, iwl9260_2ac_160_cfg, iwl9260_160_name),
984987
IWL_DEV_INFO(0x2526, 0x6010, iwl9260_2ac_160_cfg, iwl9260_160_name),
985988
IWL_DEV_INFO(0x2526, 0x6014, iwl9260_2ac_160_cfg, iwl9260_160_name),
986989
IWL_DEV_INFO(0x2526, 0x8014, iwl9260_2ac_160_cfg, iwl9260_160_name),

0 commit comments

Comments
 (0)