diff options
author | Alexey Dobriyan <adobriyan@gmail.com> | 2008-04-13 08:48:43 -0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2008-04-24 14:09:40 -0300 |
commit | 9faa2d75822e1950b3aacc8ccbdf0cdb595e47de (patch) | |
tree | da40b056cfb87ccad6414f0dd2b37abbe019fe35 /drivers/video | |
parent | b9bc07a006ae94d7b3dd5db873bcf10ceb749253 (diff) | |
download | kernel-crypto-9faa2d75822e1950b3aacc8ccbdf0cdb595e47de.tar.gz kernel-crypto-9faa2d75822e1950b3aacc8ccbdf0cdb595e47de.tar.xz kernel-crypto-9faa2d75822e1950b3aacc8ccbdf0cdb595e47de.zip |
V4L/DVB (7580): Fix concurrent read from /proc/videocodecs
Observation one: ->write_proc and ->data assignments aren't needed. Removed.
Observation two: codecs lists are unprotected. Patch doesn't fix this.
Observation three:
/proc/videocodecs printout is done to temporary _global_ buffer which
is freed in between. Consequently, two users hitting this file can
screwup each other.
Steps to reproduce:
modprobe videocodec
while true; do cat /proc/videocodecs &>/dev/null; done &
while true; do cat /proc/videocodecs &>/dev/null; done &
The fix is switching to seq_files, this removes code, especially some
line-length "logic".
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Acked-by: Jan Kara <jack@suse.cz>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/video')
0 files changed, 0 insertions, 0 deletions