Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

staging: binder: Fix death notifications

The change (008fa749e0fe5b2fffd20b7fe4891bb80d072c6a) that moved the
node release code to a separate function broke death notifications in
some cases. When it encountered a reference without a death
notification request, it would skip looking at the remaining
references, and therefore fail to send death notifications for them.

Cc: Colin Cross <ccross@android.com>
Cc: Android Kernel Team <kernel-team@android.com>
Cc: stable <stable@vger.kernel.org> # 3.10
Signed-off-by: Arve Hjønnevåg <arve@android.com>
Signed-off-by: John Stultz <john.stultz@linaro.org>
Signed-off-by: Jeremy Compostella <jeremy.compostella@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Arve Hjønnevåg and committed by
Greg Kroah-Hartman
e194fd8a 6d0abeca

+1 -2
+1 -2
drivers/staging/android/binder.c
··· 2904 2904 refs++; 2905 2905 2906 2906 if (!ref->death) 2907 - goto out; 2907 + continue; 2908 2908 2909 2909 death++; 2910 2910 ··· 2917 2917 BUG(); 2918 2918 } 2919 2919 2920 - out: 2921 2920 binder_debug(BINDER_DEBUG_DEAD_BINDER, 2922 2921 "node %d now dead, refs %d, death %d\n", 2923 2922 node->debug_id, refs, death);