[source] mac80211: ath10k: allow failure getting board id via otp

LEDE Commits lede-commits at lists.infradead.org
Tue Mar 28 00:11:15 PDT 2017


blogic pushed a commit to source.git, branch master:
https://git.lede-project.org/c69a89fe23a526ec3eef9c4e63eb672387e5177e

commit c69a89fe23a526ec3eef9c4e63eb672387e5177e
Author: Hannu Nyman <hannu.nyman at iki.fi>
AuthorDate: Thu Mar 23 16:53:17 2017 +0200

    mac80211: ath10k: allow failure getting board id via otp
    
    ath10k tries to fetch board id via otp, but that fails for many chips
    like QCA988x, QCA9984 etc. Recent commit cc189c0b7f removed the earlier
    hack that had allowed QCA radios to work, as that hack was incompatible
    with the new wifi chips being introduced to the source tree.
    
    Restore functionality for the existing wifi chips by modifying the
    return value of the 'board id via otp' function to a value that is recognised
    as a harmless error, so that name evaluation continues by using the board file.
    
    Patch originally suggested by Christian Lamparter in forum discussion.
    
    Signed-off-by: Hannu Nyman <hannu.nyman at iki.fi>
---
 .../mac80211/patches/936-ath10k-fix-otp-failure-result.patch  | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/package/kernel/mac80211/patches/936-ath10k-fix-otp-failure-result.patch b/package/kernel/mac80211/patches/936-ath10k-fix-otp-failure-result.patch
new file mode 100644
index 0000000..e28fa8f
--- /dev/null
+++ b/package/kernel/mac80211/patches/936-ath10k-fix-otp-failure-result.patch
@@ -0,0 +1,11 @@
+--- a/drivers/net/wireless/ath/ath10k/core.c
++++ b/drivers/net/wireless/ath/ath10k/core.c
+@@ -686,7 +686,7 @@
+ 	if (ret) {
+ 		ath10k_err(ar, "could not execute otp for board id check: %d\n",
+ 			   ret);
+-		return ret;
++		return -EOPNOTSUPP;
+ 	}
+ 
+ 	board_id = MS(result, ATH10K_BMI_BOARD_ID_FROM_OTP);



More information about the lede-commits mailing list