Skip to contentSkip to conversation

afs: proc cells and rootcell are writeable [ver #2]

PATCH New David Howells 1 participant 1 message Jan 28, 2014 Afs filesystem

lore
Share & tools
lore

David Howells

author maintainer
#0 lore raw

PATCH 1/1 afs: proc cells and rootcell are writeable [ver #2]

From: Pali Rohár <[email protected]>

Both proc files are writeable and used for configuring cells. But there is missing correct mode flag for writeable files. Without this patch both proc files are read only.

---

 fs/afs/proc.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
fs/afs/proc.c +2 -2
index 526e4bbbde59..2d9279fcf25e 100644
@@ -147,11 +147,11 @@ int afs_proc_init(void)
 	if (!proc_afs)
 		goto error_dir;
 
-	p = proc_create("cells", 0, proc_afs, &afs_proc_cells_fops);
+	p = proc_create("cells", 0644, proc_afs, &afs_proc_cells_fops);
 	if (!p)
 		goto error_cells;
 
-	p = proc_create("rootcell", 0, proc_afs, &afs_proc_rootcell_fops);
+	p = proc_create("rootcell", 0644, proc_afs, &afs_proc_rootcell_fops);
 	if (!p)
 		goto error_rootcell;