Re: [PATCH] Staging: Android: looping issue, need break when get value firstly.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



  oh, sorry, forgot to send to related public mailing list.



On 2013年04月05日 16:05, Chen Gang wrote:
> 
>   need break when 'target_thread' get value, firstly.
> 
>     'tmp' is a stack (thread->transaction_stack),
>     if 'proc' was the same between child node and parent node,
>     the child would have higher priority than parent.
> 
> Signed-off-by: Chen Gang <gang.chen@xxxxxxxxxxx>
> ---
>  drivers/staging/android/binder.c |    5 ++++-
>  1 files changed, 4 insertions(+), 1 deletions(-)
> 
> diff --git a/drivers/staging/android/binder.c b/drivers/staging/android/binder.c
> index 1567ac2..8972ec6 100644
> --- a/drivers/staging/android/binder.c
> +++ b/drivers/staging/android/binder.c
> @@ -1395,8 +1395,11 @@ static void binder_transaction(struct binder_proc *proc,
>  				goto err_bad_call_stack;
>  			}
>  			while (tmp) {
> -				if (tmp->from && tmp->from->proc == target_proc)
> +				if (tmp->from &&
> +				    tmp->from->proc == target_proc) {
>  					target_thread = tmp->from;
> +					break;
> +				}
>  				tmp = tmp->from_parent;
>  			}
>  		}
> 


-- 
Chen Gang

Asianux Corporation
_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/devel





[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux