summaryrefslogtreecommitdiffstats
path: root/lib/mpi/mpi-bit.c
diff options
context:
space:
mode:
authorArve Hjønnevåg <arve@android.com>2012-02-01 15:29:13 -0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-02-08 14:14:13 -0800
commitbd1eff9741af27378b241b347041c724bb28e857 (patch)
tree47ec1db37ae76c3b8b4b2908cc6a5129191b5089 /lib/mpi/mpi-bit.c
parentb0d017e80e9f4e6b37e699b9a944646e64deb473 (diff)
Staging: android: binder: Fix crashes when sharing a binder file between processes
Opening the binder driver and sharing the file returned with other processes (e.g. by calling fork) can crash the kernel. Prevent these crashes with the following changes: - Add a mutex to protect against two processes mmapping the same binder_proc. - After locking mmap_sem, check that the vma we want to access (still) points to the same mm_struct. - Use proc->tsk instead of current to get the files struct since this is where we get the rlimit from. Signed-off-by: Arve Hjønnevåg <arve@android.com> Cc: stable <stable@vger.kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'lib/mpi/mpi-bit.c')
0 files changed, 0 insertions, 0 deletions