diff options
author | Federico Vaga <federico.vaga@gmail.com> | 2011-10-29 09:45:39 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2011-11-26 18:34:14 -0800 |
commit | df30b21cb0eed5ba8a8e0cdfeebc66ba8cde821d (patch) | |
tree | 5bd4f9b7050691a53abfff32f1218cadd4425a2b /lib/mpi/mpi-mpow.c | |
parent | 3ffab428f40849ed5f21bcfd7285bdef7902f9ca (diff) |
Staging: comedi: fix mmap_count
In comedi_fops, mmap_count is decremented at comedi_vm_ops->close but
it is not incremented at comedi_vm_ops->open. This may result in a negative
counter. The patch introduces the open method to keep the counter
consistent.
The bug was triggerd by this sample code:
mmap(0, ...., comedi_fd);
fork();
exit(0);
Acked-by: Alessandro Rubini <rubini@gnudd.com>
Signed-off-by: Federico Vaga <federico.vaga@gmail.com>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'lib/mpi/mpi-mpow.c')
0 files changed, 0 insertions, 0 deletions