History

proc: use named enums for better readability

Alexey Gladkov committed 6 years ago

Commit e61bb8b1 parent 1c6c4d14 files · +8 −8Browse files

Showing the changes to include/linux (1 of 4 files). Show all

Unified · Split

include/linux/proc_fs.h+4−4
@@ -43,7 +43,7 @@ struct proc_ops { · 42 unmodified lines
43} __randomize_layout;43} __randomize_layout;
44 44
45/* definitions for hide_pid field */45/* definitions for hide_pid field */
46enum {46enum proc_hidepid {
47 HIDEPID_OFF = 0,47 HIDEPID_OFF = 0,
48 HIDEPID_NO_ACCESS = 1,48 HIDEPID_NO_ACCESS = 1,
49 HIDEPID_INVISIBLE = 2,49 HIDEPID_INVISIBLE = 2,
@@ -51,7 +51,7 @@ enum { · 1 unmodified line
51};51};
52 52
53/* definitions for proc mount option pidonly */53/* definitions for proc mount option pidonly */
54enum {54enum proc_pidonly {
55 PROC_PIDONLY_OFF = 0,55 PROC_PIDONLY_OFF = 0,
56 PROC_PIDONLY_ON = 1,56 PROC_PIDONLY_ON = 1,
57};57};
@@ -61,8 +61,8 @@ struct proc_fs_info { · 3 unmodified lines
61 struct dentry *proc_self; /* For /proc/self */61 struct dentry *proc_self; /* For /proc/self */
62 struct dentry *proc_thread_self; /* For /proc/thread-self */62 struct dentry *proc_thread_self; /* For /proc/thread-self */
63 kgid_t pid_gid;63 kgid_t pid_gid;
64 int hide_pid;64 enum proc_hidepid hide_pid;
65 int pidonly;65 enum proc_pidonly pidonly;
66};66};
67 67
68static inline struct proc_fs_info *proc_sb_info(struct super_block *sb)68static inline struct proc_fs_info *proc_sb_info(struct super_block *sb)