mirror of
https://github.com/openwrt/openwrt.git
synced 2024-12-26 08:51:13 +00:00
40 lines
1.2 KiB
Diff
40 lines
1.2 KiB
Diff
|
From 16e51cb83f9fa1717383c9d67f5531df7348347c Mon Sep 17 00:00:00 2001
|
||
|
From: Robert Marko <robert.marko@sartura.hr>
|
||
|
Date: Wed, 30 Mar 2022 19:51:56 +0200
|
||
|
Subject: [PATCH] mwlwifi: replace get/set_fs() calls
|
||
|
|
||
|
Since kernel 5.9 the get/set_fs() call implementation have started to get
|
||
|
dropped from individual architectures, ARM64 one got dropped in 5.11.
|
||
|
|
||
|
Replace the get/set_fs() calls with force_uaccess_begin/end() to allow
|
||
|
compiling on newer kernels.
|
||
|
There is no need to add kernel version checks as the replacement functions
|
||
|
are available since kernel 5.9.
|
||
|
|
||
|
Signed-off-by: Robert Marko <robert.marko@sartura.hr>
|
||
|
---
|
||
|
hif/pcie/pcie.c | 5 ++---
|
||
|
1 file changed, 2 insertions(+), 3 deletions(-)
|
||
|
|
||
|
--- a/hif/pcie/pcie.c
|
||
|
+++ b/hif/pcie/pcie.c
|
||
|
@@ -1293,8 +1293,7 @@ static void pcie_bf_mimo_ctrl_decode(str
|
||
|
char *buf = &str_buf[0];
|
||
|
mm_segment_t oldfs;
|
||
|
|
||
|
- oldfs = get_fs();
|
||
|
- set_fs(KERNEL_DS);
|
||
|
+ oldfs = force_uaccess_begin();
|
||
|
|
||
|
buf += sprintf(buf, "\nMAC: %pM\n", bf_mimo_ctrl->rec_mac);
|
||
|
buf += sprintf(buf, "SU_0_MU_1: %d\n", bf_mimo_ctrl->type);
|
||
|
@@ -1314,7 +1313,7 @@ static void pcie_bf_mimo_ctrl_decode(str
|
||
|
filename, (unsigned int)fp_data);
|
||
|
}
|
||
|
|
||
|
- set_fs(oldfs);
|
||
|
+ force_uaccess_end(oldfs);
|
||
|
}
|
||
|
|
||
|
static void pcie_process_account(struct ieee80211_hw *hw)
|