summaryrefslogtreecommitdiff
path: root/drivers/staging/hv
diff options
context:
space:
mode:
authorFederico Vaga <federico.vaga@gmail.com>2011-10-29 09:45:39 +0200
committerGreg Kroah-Hartman <gregkh@suse.de>2011-12-09 08:54:42 -0800
commit3762465d4a6c6a92a93d361b95dd453fd736ba73 (patch)
tree949323bc7c567cd834f528345e44bb1b53efa02b /drivers/staging/hv
parent7994d8747d9ac088be8a2136dc25ea30135ca1e8 (diff)
Staging: comedi: fix mmap_count
commit df30b21cb0eed5ba8a8e0cdfeebc66ba8cde821d upstream. 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> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/hv')
0 files changed, 0 insertions, 0 deletions