Used in another way instead of set_fs, since v5.10, set_fs cannot be
used.
Change-Id: I581e17a536f3cd8e57e9bd4bc37904ef288f1f5b
Signed-off-by: Hoegeun Kwon <hoegeun.kwon@samsung.com>
char *filename = CONFIG_TIZEN_INFORM_PATH;
struct file *file;
loff_t pos = 0;
- mm_segment_t old_fs = get_fs();
-
- set_fs(KERNEL_DS);
+ mm_segment_t old_fs = force_uaccess_begin();
file = filp_open(filename, O_CREAT | O_WRONLY | O_TRUNC, 0644);
if (file) {
"Inform file path should be described correctly in config.\n");
}
- set_fs(old_fs);
+ force_uaccess_end(old_fs);
return NOTIFY_DONE;
}