proc_sysctl.c (2f221d6f7b881d95de1f356a3097d755ab1e47d4) proc_sysctl.c (0d56a4518d5eaf595a24ab2202e171330bb2ed72)
1// SPDX-License-Identifier: GPL-2.0
2/*
3 * /proc/sys support
4 */
5#include <linux/init.h>
6#include <linux/sysctl.h>
7#include <linux/poll.h>
8#include <linux/proc_fs.h>

--- 826 unchanged lines hidden (view full) ---

835{
836 struct inode *inode = d_inode(path->dentry);
837 struct ctl_table_header *head = grab_header(inode);
838 struct ctl_table *table = PROC_I(inode)->sysctl_entry;
839
840 if (IS_ERR(head))
841 return PTR_ERR(head);
842
1// SPDX-License-Identifier: GPL-2.0
2/*
3 * /proc/sys support
4 */
5#include <linux/init.h>
6#include <linux/sysctl.h>
7#include <linux/poll.h>
8#include <linux/proc_fs.h>

--- 826 unchanged lines hidden (view full) ---

835{
836 struct inode *inode = d_inode(path->dentry);
837 struct ctl_table_header *head = grab_header(inode);
838 struct ctl_table *table = PROC_I(inode)->sysctl_entry;
839
840 if (IS_ERR(head))
841 return PTR_ERR(head);
842
843 generic_fillattr(inode, stat);
843 generic_fillattr(&init_user_ns, inode, stat);
844 if (table)
845 stat->mode = (stat->mode & S_IFMT) | table->mode;
846
847 sysctl_head_finish(head);
848 return 0;
849}
850
851static const struct file_operations proc_sys_file_operations = {

--- 1003 unchanged lines hidden ---
844 if (table)
845 stat->mode = (stat->mode & S_IFMT) | table->mode;
846
847 sysctl_head_finish(head);
848 return 0;
849}
850
851static const struct file_operations proc_sys_file_operations = {

--- 1003 unchanged lines hidden ---