mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Jesper Nilsson <jesper.nilsson@axis.com>
To: Wei Yongjun <weiyj.lk@gmail.com>
Cc: starvik@axis.com, yongjun_wei@trendmicro.com.cn,
	linux-cris-kernel@axis.com, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] CRIS: locking: fix the return value of arch_read_trylock()
Date: Fri, 19 Oct 2012 10:35:24 +0200	[thread overview]
Message-ID: <20121019083524.GH29793@axis.com> (raw)
In-Reply-To: <CAPgLHd9enojK7tbCxWKyHnzgnSYZUGqAiAgevn6uamrw_3t4Mg@mail.gmail.com>

On Wed, Oct 17, 2012 at 10:54:27PM +0800, Wei Yongjun wrote:
> From: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
> 
> arch_write_trylock() should return 'ret' instead of always
> return 1.
> 
> dpatch engine is used to auto generate this patch.
> (https://github.com/weiyj/dpatch)

I've taken this into the CRIS-tree, thanks!

> Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
> ---
>  arch/cris/include/arch-v32/arch/spinlock.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/arch/cris/include/arch-v32/arch/spinlock.h b/arch/cris/include/arch-v32/arch/spinlock.h
> index f171a66..f132755 100644
> --- a/arch/cris/include/arch-v32/arch/spinlock.h
> +++ b/arch/cris/include/arch-v32/arch/spinlock.h
> @@ -118,7 +118,7 @@ static  inline int arch_write_trylock(arch_rwlock_t *rw)
>  		ret = 1;
>  	}
>  	arch_spin_unlock(&rw->slock);
> -	return 1;
> +	return ret;
>  }
>  
>  #define _raw_read_lock_flags(lock, flags) _raw_read_lock(lock)
> 
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at  http://www.tux.org/lkml/

/^JN - Jesper Nilsson
-- 
               Jesper Nilsson -- jesper.nilsson@axis.com

      reply	other threads:[~2012-10-19  8:35 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-17 14:54 Wei Yongjun
2012-10-19  8:35 ` Jesper Nilsson [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20121019083524.GH29793@axis.com \
    --to=jesper.nilsson@axis.com \
    --cc=linux-cris-kernel@axis.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=starvik@axis.com \
    --cc=weiyj.lk@gmail.com \
    --cc=yongjun_wei@trendmicro.com.cn \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome