kernel: remove ksu_compat_{open,read,write} because we're in the right context now
Co-authored-by: weishu <twsxtd@gmail.com>
This commit is contained in:
@@ -130,7 +130,7 @@ static void sulog_work_handler(struct work_struct *work)
|
||||
if (list_empty(&local_queue))
|
||||
return;
|
||||
|
||||
fp = ksu_filp_open_compat(SULOG_PATH, O_WRONLY | O_CREAT | O_APPEND, 0640);
|
||||
fp = filp_open(SULOG_PATH, O_WRONLY | O_CREAT | O_APPEND, 0640);
|
||||
if (IS_ERR(fp)) {
|
||||
pr_err("sulog: failed to open log file: %ld\n", PTR_ERR(fp));
|
||||
goto cleanup;
|
||||
@@ -147,7 +147,7 @@ static void sulog_work_handler(struct work_struct *work)
|
||||
}
|
||||
|
||||
list_for_each_entry(entry, &local_queue, list) {
|
||||
ksu_kernel_write_compat(fp, entry->content, strlen(entry->content), &pos);
|
||||
kernel_write(fp, entry->content, strlen(entry->content), &pos);
|
||||
}
|
||||
|
||||
vfs_fsync(fp, 0);
|
||||
|
||||
Reference in New Issue
Block a user