diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2013-05-05 10:35:26 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-05-05 10:35:26 -0700 |
commit | 24d0c2542b38963ae4d5171ecc0a2c1326c656bc (patch) | |
tree | 1d7de3d2f79f65c34e8f29d7bb6fe5ed512b226c /drivers | |
parent | 802d0db827eaa5a34dd655623c71134ec63d8c3f (diff) | |
parent | 7ee2b9e56495c56dcaffa2bab19b39451d9fdc8a (diff) | |
download | op-kernel-dev-24d0c2542b38963ae4d5171ecc0a2c1326c656bc.zip op-kernel-dev-24d0c2542b38963ae4d5171ecc0a2c1326c656bc.tar.gz |
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 'drivers')
-rw-r--r-- | drivers/char/ds1620.c | 2 | ||||
-rw-r--r-- | drivers/char/efirtc.c | 2 | ||||
-rw-r--r-- | drivers/char/genrtc.c | 2 | ||||
-rw-r--r-- | drivers/input/misc/hp_sdc_rtc.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/atmel.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/hostap/hostap_ap.c | 4 | ||||
-rw-r--r-- | drivers/net/wireless/hostap/hostap_hw.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/hostap/hostap_proc.c | 6 | ||||
-rw-r--r-- | drivers/scsi/megaraid.c | 2 | ||||
-rw-r--r-- | drivers/staging/comedi/proc.c | 2 | ||||
-rw-r--r-- | drivers/staging/csr/io.c | 2 | ||||
-rw-r--r-- | drivers/staging/cxt1e1/sbeproc.c | 2 | ||||
-rw-r--r-- | drivers/staging/ft1000/ft1000-pcmcia/ft1000_proc.c | 2 | ||||
-rw-r--r-- | drivers/staging/ft1000/ft1000-usb/ft1000_proc.c | 2 | ||||
-rw-r--r-- | drivers/staging/rtl8187se/r8180_core.c | 2 | ||||
-rw-r--r-- | drivers/staging/rtl8192u/r8192U_core.c | 2 | ||||
-rw-r--r-- | drivers/staging/wlags49_h2/wl_main.c | 2 | ||||
-rw-r--r-- | drivers/usb/gadget/fsl_udc_core.c | 2 | ||||
-rw-r--r-- | drivers/usb/gadget/goku_udc.c | 2 |
19 files changed, 22 insertions, 22 deletions
diff --git a/drivers/char/ds1620.c b/drivers/char/ds1620.c index 544b4ce..0fae529 100644 --- a/drivers/char/ds1620.c +++ b/drivers/char/ds1620.c @@ -355,7 +355,7 @@ static const struct file_operations ds1620_proc_therm_fops = { .open = ds1620_proc_therm_open, .read = seq_read, .llseek = seq_lseek, - .release = seq_release, + .release = single_release, }; #endif diff --git a/drivers/char/efirtc.c b/drivers/char/efirtc.c index ea54a6e..e39e740 100644 --- a/drivers/char/efirtc.c +++ b/drivers/char/efirtc.c @@ -369,7 +369,7 @@ static const struct file_operations efi_rtc_proc_fops = { .open = efi_rtc_proc_open, .read = seq_read, .llseek = seq_lseek, - .release = seq_release, + .release = single_release, }; static int __init diff --git a/drivers/char/genrtc.c b/drivers/char/genrtc.c index bc9b84d..4f94375 100644 --- a/drivers/char/genrtc.c +++ b/drivers/char/genrtc.c @@ -465,7 +465,7 @@ static const struct file_operations gen_rtc_proc_fops = { .open = gen_rtc_proc_open, .read = seq_read, .llseek = seq_lseek, - .release = seq_release, + .release = single_release, }; static int __init gen_rtc_proc_init(void) diff --git a/drivers/input/misc/hp_sdc_rtc.c b/drivers/input/misc/hp_sdc_rtc.c index 770479d..86b8228 100644 --- a/drivers/input/misc/hp_sdc_rtc.c +++ b/drivers/input/misc/hp_sdc_rtc.c @@ -515,7 +515,7 @@ static const struct file_operations hp_sdc_rtc_proc_fops = { .open = hp_sdc_rtc_proc_open, .read = seq_read, .llseek = seq_lseek, - .release = seq_release, + .release = single_release, }; static int hp_sdc_rtc_ioctl(struct file *file, diff --git a/drivers/net/wireless/atmel.c b/drivers/net/wireless/atmel.c index 23a3498..830bb1d 100644 --- a/drivers/net/wireless/atmel.c +++ b/drivers/net/wireless/atmel.c @@ -1502,7 +1502,7 @@ static const struct file_operations atmel_proc_fops = { .open = atmel_proc_open, .read = seq_read, .llseek = seq_lseek, - .release = seq_release, + .release = single_release, }; static const struct net_device_ops atmel_netdev_ops = { diff --git a/drivers/net/wireless/hostap/hostap_ap.c b/drivers/net/wireless/hostap/hostap_ap.c index 19c45e3..d6033a8 100644 --- a/drivers/net/wireless/hostap/hostap_ap.c +++ b/drivers/net/wireless/hostap/hostap_ap.c @@ -89,7 +89,7 @@ static const struct file_operations ap_debug_proc_fops = { .open = ap_debug_proc_open, .read = seq_read, .llseek = seq_lseek, - .release = seq_release, + .release = single_release, }; #endif /* PRISM2_NO_PROCFS_DEBUG */ @@ -1116,7 +1116,7 @@ static const struct file_operations prism2_sta_proc_fops = { .open = prism2_sta_proc_open, .read = seq_read, .llseek = seq_lseek, - .release = seq_release, + .release = single_release, }; static void handle_add_proc_queue(struct work_struct *work) diff --git a/drivers/net/wireless/hostap/hostap_hw.c b/drivers/net/wireless/hostap/hostap_hw.c index 507ab99..6307a4e 100644 --- a/drivers/net/wireless/hostap/hostap_hw.c +++ b/drivers/net/wireless/hostap/hostap_hw.c @@ -2957,7 +2957,7 @@ static const struct file_operations prism2_registers_proc_fops = { .open = prism2_registers_proc_open, .read = seq_read, .llseek = seq_lseek, - .release = seq_release, + .release = single_release, }; #endif /* PRISM2_NO_PROCFS_DEBUG */ diff --git a/drivers/net/wireless/hostap/hostap_proc.c b/drivers/net/wireless/hostap/hostap_proc.c index 7491dab..aa7ad3a7 100644 --- a/drivers/net/wireless/hostap/hostap_proc.c +++ b/drivers/net/wireless/hostap/hostap_proc.c @@ -52,7 +52,7 @@ static const struct file_operations prism2_debug_proc_fops = { .open = prism2_debug_proc_open, .read = seq_read, .llseek = seq_lseek, - .release = seq_release, + .release = single_release, }; #endif /* PRISM2_NO_PROCFS_DEBUG */ @@ -103,7 +103,7 @@ static const struct file_operations prism2_stats_proc_fops = { .open = prism2_stats_proc_open, .read = seq_read, .llseek = seq_lseek, - .release = seq_release, + .release = single_release, }; @@ -265,7 +265,7 @@ static const struct file_operations prism2_crypt_proc_fops = { .open = prism2_crypt_proc_open, .read = seq_read, .llseek = seq_lseek, - .release = seq_release, + .release = single_release, }; diff --git a/drivers/scsi/megaraid.c b/drivers/scsi/megaraid.c index 7373255..846f475f 100644 --- a/drivers/scsi/megaraid.c +++ b/drivers/scsi/megaraid.c @@ -2770,7 +2770,7 @@ static const struct file_operations mega_proc_fops = { .open = mega_proc_open, .read = seq_read, .llseek = seq_lseek, - .release = seq_release, + .release = single_release, }; /* diff --git a/drivers/staging/comedi/proc.c b/drivers/staging/comedi/proc.c index db790f9..886c202 100644 --- a/drivers/staging/comedi/proc.c +++ b/drivers/staging/comedi/proc.c @@ -86,7 +86,7 @@ static const struct file_operations comedi_proc_fops = { .open = comedi_proc_open, .read = seq_read, .llseek = seq_lseek, - .release = seq_release, + .release = single_release, }; void comedi_proc_init(void) diff --git a/drivers/staging/csr/io.c b/drivers/staging/csr/io.c index f9b5c22..fe4a7ba 100644 --- a/drivers/staging/csr/io.c +++ b/drivers/staging/csr/io.c @@ -95,7 +95,7 @@ static const struct file_operations uf_proc_fops = { .open = uf_proc_open, .read = seq_read, .llseek = seq_lseek, - .release = seq_release, + .release = single_release, }; #endif /* CONFIG_PROC_FS */ diff --git a/drivers/staging/cxt1e1/sbeproc.c b/drivers/staging/cxt1e1/sbeproc.c index 49f10f0..9361dd8 100644 --- a/drivers/staging/cxt1e1/sbeproc.c +++ b/drivers/staging/cxt1e1/sbeproc.c @@ -189,7 +189,7 @@ static const struct file_operations sbecom_proc_fops = { .open = sbecom_proc_open, .read = seq_read, .llseek = seq_lseek, - .release = seq_release, + .release = single_release, }; /* diff --git a/drivers/staging/ft1000/ft1000-pcmcia/ft1000_proc.c b/drivers/staging/ft1000/ft1000-pcmcia/ft1000_proc.c index 21b369e..94e426e 100644 --- a/drivers/staging/ft1000/ft1000-pcmcia/ft1000_proc.c +++ b/drivers/staging/ft1000/ft1000-pcmcia/ft1000_proc.c @@ -158,7 +158,7 @@ static const struct file_operations ft1000_proc_fops = { .open = ft1000_proc_open, .read = seq_read, .llseek = seq_lseek, - .release = seq_release, + .release = single_release, }; static int ft1000NotifyProc(struct notifier_block *this, unsigned long event, diff --git a/drivers/staging/ft1000/ft1000-usb/ft1000_proc.c b/drivers/staging/ft1000/ft1000-usb/ft1000_proc.c index d8294d6..eca6f02 100644 --- a/drivers/staging/ft1000/ft1000-usb/ft1000_proc.c +++ b/drivers/staging/ft1000/ft1000-usb/ft1000_proc.c @@ -160,7 +160,7 @@ static const struct file_operations ft1000_proc_fops = { .open = ft1000_proc_open, .read = seq_read, .llseek = seq_lseek, - .release = seq_release, + .release = single_release, }; static int diff --git a/drivers/staging/rtl8187se/r8180_core.c b/drivers/staging/rtl8187se/r8180_core.c index f7c1d99..ca69155 100644 --- a/drivers/staging/rtl8187se/r8180_core.c +++ b/drivers/staging/rtl8187se/r8180_core.c @@ -306,7 +306,7 @@ static const struct file_operations rtl8180_proc_fops = { .open = rtl8180_proc_open, .read = seq_read, .llseek = seq_lseek, - .release = seq_release, + .release = single_release, }; /* diff --git a/drivers/staging/rtl8192u/r8192U_core.c b/drivers/staging/rtl8192u/r8192U_core.c index 1459233..71f5cde 100644 --- a/drivers/staging/rtl8192u/r8192U_core.c +++ b/drivers/staging/rtl8192u/r8192U_core.c @@ -647,7 +647,7 @@ static const struct file_operations rtl8192_proc_fops = { .open = rtl8192_proc_open, .read = seq_read, .llseek = seq_lseek, - .release = seq_release, + .release = single_release, }; /* diff --git a/drivers/staging/wlags49_h2/wl_main.c b/drivers/staging/wlags49_h2/wl_main.c index c4264e8..f28f15b 100644 --- a/drivers/staging/wlags49_h2/wl_main.c +++ b/drivers/staging/wlags49_h2/wl_main.c @@ -160,7 +160,7 @@ static const struct file_operations scull_read_procmem_fops = { .open = scull_read_procmem_open, .read = seq_read, .llseek = seq_lseek, - .release = seq_release, + .release = single_release, }; #endif /* SCULL_USE_PROC */ diff --git a/drivers/usb/gadget/fsl_udc_core.c b/drivers/usb/gadget/fsl_udc_core.c index 2d8c1cf..a766a4c 100644 --- a/drivers/usb/gadget/fsl_udc_core.c +++ b/drivers/usb/gadget/fsl_udc_core.c @@ -2211,7 +2211,7 @@ static const struct file_operations fsl_proc_fops = { .open = fsl_proc_open, .read = seq_read, .llseek = seq_lseek, - .release = seq_release, + .release = single_release, }; #define create_proc_file() proc_create(proc_filename, 0, NULL, &fsl_proc_fops) diff --git a/drivers/usb/gadget/goku_udc.c b/drivers/usb/gadget/goku_udc.c index 480eeb7..52dd6cc 100644 --- a/drivers/usb/gadget/goku_udc.c +++ b/drivers/usb/gadget/goku_udc.c @@ -1214,7 +1214,7 @@ static const struct file_operations udc_proc_fops = { .open = udc_proc_open, .read = seq_read, .llseek = seq_lseek, - .release = seq_release, + .release = single_release, }; #endif /* CONFIG_USB_GADGET_DEBUG_FILES */ |