This repository has been archived by the owner on Jul 7, 2021. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
qcacld-3.0: Fix mac address fallback when generation fails
Adapted from LineageOS/android_kernel_oneplus_sm8150@794b511 Recently, Chinese users have reported inline qcacld-3.0 failures (although it's possible that this may pertain to a minority of other users as well). This occurs as a result of wlan_mac.bin failing to generate. Under normal circumstances, qcacld-3.0 would fallback to a firmware provided mac address. However, OnePlus' firmware byte-ordering results in a reversed address being fed to the driver, breaking fallback logic and preventing WLAN from getting off the ground entirely. This reworks the original LineageOS patch to correct improper in-loop variable declaration which triggers the following compilation error not only on GCC, but current LLVM toolchains as well: ../drivers/staging/qcacld-3.0/core/hdd/src/wlan_hdd_main.c:11006:7: error: GCC does not allow variable declarations in for loop initializers before C99 [-Werror,-Wgcc-compat] for (int i = 0; i < len / 2; i++) { ^ Co-authored-by: Peter Cai <peter@typeblog.net> Signed-off-by: Adam W. Willis <return.of.octobot@gmail.com>
- Loading branch information