aboutsummaryrefslogtreecommitdiffstats
path: root/kernel
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2013-05-05 13:35:26 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2013-05-05 13:35:26 -0400
commit24d0c2542b38963ae4d5171ecc0a2c1326c656bc (patch)
tree1d7de3d2f79f65c34e8f29d7bb6fe5ed512b226c /kernel
parent802d0db827eaa5a34dd655623c71134ec63d8c3f (diff)
parent7ee2b9e56495c56dcaffa2bab19b39451d9fdc8a (diff)
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs
Pull single_open() leak fixes from Al Viro: "A bunch of fixes for a moderately common class of bugs: file with single_open() done by its ->open() and seq_release as its ->release(). That leaks; fortunately, it's not _too_ common (either people manage to RTFM that says "When using single_open(), the programmer should use single_release() instead of seq_release() in the file_operations structure to avoid a memory leak", or they just copy a correct instance), but grepping through the tree has caught quite a pile. All of that is, AFAICS, -stable fodder, for as far as the patches apply. I tried to carve it up into reasonably-sized pieces (more or less "comes from the same tree")" * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: rcutrace: single_open() leaks gadget: single_open() leaks staging: single_open() leaks megaraid: single_open() leak wireless: single_open() leaks input: single_open() leak rtc: single_open() leaks ds1620: single_open() leak sh: single_open() leaks parisc: single_open() leaks mips: single_open() leaks ia64: single_open() leaks h8300: single_open() leaks cris: single_open() leaks arm: single_open() leaks
Diffstat (limited to 'kernel')
-rw-r--r--kernel/rcutree_trace.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/kernel/rcutree_trace.c b/kernel/rcutree_trace.c
index 49099e81c87b..cf6c17412932 100644
--- a/kernel/rcutree_trace.c
+++ b/kernel/rcutree_trace.c
@@ -95,7 +95,7 @@ static const struct file_operations rcubarrier_fops = {
95 .open = rcubarrier_open, 95 .open = rcubarrier_open,
96 .read = seq_read, 96 .read = seq_read,
97 .llseek = no_llseek, 97 .llseek = no_llseek,
98 .release = seq_release, 98 .release = single_release,
99}; 99};
100 100
101#ifdef CONFIG_RCU_BOOST 101#ifdef CONFIG_RCU_BOOST
@@ -206,7 +206,7 @@ static const struct file_operations rcuexp_fops = {
206 .open = rcuexp_open, 206 .open = rcuexp_open,
207 .read = seq_read, 207 .read = seq_read,
208 .llseek = no_llseek, 208 .llseek = no_llseek,
209 .release = seq_release, 209 .release = single_release,
210}; 210};
211 211
212#ifdef CONFIG_RCU_BOOST 212#ifdef CONFIG_RCU_BOOST
@@ -306,7 +306,7 @@ static const struct file_operations rcuhier_fops = {
306 .open = rcuhier_open, 306 .open = rcuhier_open,
307 .read = seq_read, 307 .read = seq_read,
308 .llseek = no_llseek, 308 .llseek = no_llseek,
309 .release = seq_release, 309 .release = single_release,
310}; 310};
311 311
312static void show_one_rcugp(struct seq_file *m, struct rcu_state *rsp) 312static void show_one_rcugp(struct seq_file *m, struct rcu_state *rsp)
@@ -348,7 +348,7 @@ static const struct file_operations rcugp_fops = {
348 .open = rcugp_open, 348 .open = rcugp_open,
349 .read = seq_read, 349 .read = seq_read,
350 .llseek = no_llseek, 350 .llseek = no_llseek,
351 .release = seq_release, 351 .release = single_release,
352}; 352};
353 353
354static void print_one_rcu_pending(struct seq_file *m, struct rcu_data *rdp) 354static void print_one_rcu_pending(struct seq_file *m, struct rcu_data *rdp)