aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorArve Hjønnevåg <arve@android.com>2014-02-17 16:58:29 -0500
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-02-21 15:30:54 -0500
commite194fd8a5d8e0a7eeed239a8534460724b62fe2d (patch)
tree180b189c9cdc3d72b9abac23917542f1a053116d
parent6d0abeca3242a88cab8232e4acd7e2bf088f3bc2 (diff)
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>
-rw-r--r--drivers/staging/android/binder.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/staging/android/binder.c b/drivers/staging/android/binder.c
index eaec1dab7fe4..1432d956769c 100644
--- a/drivers/staging/android/binder.c
+++ b/drivers/staging/android/binder.c
@@ -2904,7 +2904,7 @@ static int binder_node_release(struct binder_node *node, int refs)
2904 refs++; 2904 refs++;
2905 2905
2906 if (!ref->death) 2906 if (!ref->death)
2907 goto out; 2907 continue;
2908 2908
2909 death++; 2909 death++;
2910 2910
@@ -2917,7 +2917,6 @@ static int binder_node_release(struct binder_node *node, int refs)
2917 BUG(); 2917 BUG();
2918 } 2918 }
2919 2919
2920out:
2921 binder_debug(BINDER_DEBUG_DEAD_BINDER, 2920 binder_debug(BINDER_DEBUG_DEAD_BINDER,
2922 "node %d now dead, refs %d, death %d\n", 2921 "node %d now dead, refs %d, death %d\n",
2923 node->debug_id, refs, death); 2922 node->debug_id, refs, death);