Skip to contentSkip to conversation

lockdep: Fix file mode of lock_stat

PATCH In review Li Zefan 1 participant 2 messages Aug 7, 2009

lore
Share & tools
lore

Li Zefan

author
#0 lore raw

PATCH 1/1 lockdep: Fix file mode of lock_stat

/proc/lock_stat is writable.

---
 kernel/lockdep_proc.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
kernel/lockdep_proc.c +2 -1
index fba81f1..98cc796 100644
@@ -762,7 +762,8 @@ static int __init lockdep_proc_init(void)
 		    &proc_lockdep_stats_operations);
 
 #ifdef CONFIG_LOCK_STAT
-	proc_create("lock_stat", S_IRUSR, NULL, &proc_lock_stat_operations);
+	proc_create("lock_stat", S_IRUSR | S_IWUSR, NULL,
+		    &proc_lock_stat_operations);
 #endif
 
 	return 0;
Signature · 1 line
1.6.3
#1 lore raw
Commit-ID:  9795447f71324d8f14c19ed68b43c883135c3f59
Gitweb:     http://git.kernel.org/tip/9795447f71324d8f14c19ed68b43c883135c3f59
Author:     Li Zefan <[email protected]>
AuthorDate: Fri, 7 Aug 2009 16:37:10 +0800
Committer:  Ingo Molnar <[email protected]>
CommitDate: Fri, 7 Aug 2009 11:58:38 +0200

lockdep: Fix file mode of lock_stat

/proc/lock_stat is writable.

Cc Peter Zijlstra <[email protected]>

LKML-Reference: <[email protected]>

---
 kernel/lockdep_proc.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
kernel/lockdep_proc.c +2 -1
index d7135aa..e94caa6 100644
@@ -758,7 +758,8 @@ static int __init lockdep_proc_init(void)
 		    &proc_lockdep_stats_operations);
 
 #ifdef CONFIG_LOCK_STAT
-	proc_create("lock_stat", S_IRUSR, NULL, &proc_lock_stat_operations);
+	proc_create("lock_stat", S_IRUSR | S_IWUSR, NULL,
+		    &proc_lock_stat_operations);
 #endif
 
 	return 0;