mtwifi/mt7612e: disable set/get_fs by default (#10930)

This commit is contained in:
zfdx 2023-02-24 19:05:51 +08:00 committed by GitHub
parent 53b83ba81a
commit efb9242261
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -914,10 +914,14 @@ static inline void __RtmpOSFSInfoChange(OS_FS_INFO * pOSFSInfo, BOOLEAN bSet)
pOSFSInfo->fsuid = current_fsuid();
pOSFSInfo->fsgid = current_fsgid();
#endif
#if 0
pOSFSInfo->fs = get_fs();
set_fs(KERNEL_DS);
#endif
} else {
#if 0
set_fs(pOSFSInfo->fs);
#endif
#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,29)
current->fsuid = pOSFSInfo->fsuid;
current->fsgid = pOSFSInfo->fsgid;
@ -1936,8 +1940,10 @@ VOID RtmpDrvAllMacPrint(
if (!msg)
return;
#if 0
orig_fs = get_fs();
set_fs(KERNEL_DS);
#endif
/* open file */
file_w = filp_open(fileName, O_WRONLY | O_CREAT, 0);
@ -1965,7 +1971,9 @@ VOID RtmpDrvAllMacPrint(
}
filp_close(file_w, NULL);
}
#if 0
set_fs(orig_fs);
#endif
os_free_mem(NULL, msg);
}
@ -1987,8 +1995,10 @@ VOID RtmpDrvAllE2PPrint(
if (!msg)
return;
#if 0
orig_fs = get_fs();
set_fs(KERNEL_DS);
#endif
/* open file */
file_w = filp_open(fileName, O_WRONLY | O_CREAT, 0);
@ -2017,7 +2027,9 @@ VOID RtmpDrvAllE2PPrint(
}
filp_close(file_w, NULL);
}
#if 0
set_fs(orig_fs);
#endif
os_free_mem(NULL, msg);
}
@ -2031,8 +2043,10 @@ VOID RtmpDrvAllRFPrint(
PSTRING fileName = "RFDump.txt";
mm_segment_t orig_fs;
#if 0
orig_fs = get_fs();
set_fs(KERNEL_DS);
#endif
/* open file */
file_w = filp_open(fileName, O_WRONLY | O_CREAT, 0);
@ -2048,7 +2062,9 @@ VOID RtmpDrvAllRFPrint(
}
filp_close(file_w, NULL);
}
#if 0
set_fs(orig_fs);
#endif
}