All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Kirill A. Shutemov" <kirill@shutemov.name>
To: chengang@emindsoft.com.cn
Cc: akpm@linux-foundation.org, kirill.shutemov@linux.intel.com,
	jmarchan@redhat.com, vbabka@suse.cz, willy@linux.intel.com,
	dan.j.williams@intel.co, dan.j.williams@intel.com,
	mgorman@techsingularity.net, trivial@kernel.org,
	linux-kernel@vger.kernel.org,
	Chen Gang <gang.chen.5i5j@gmail.com>
Subject: Re: [PATCH trivial] include/linux/huge_mm.h: Return NULL instead of false for pmd_trans_huge_lock()
Date: Mon, 28 Mar 2016 17:53:13 +0300	[thread overview]
Message-ID: <20160328145313.GA25200@node.shutemov.name> (raw)
In-Reply-To: <1459176594-1881-1-git-send-email-chengang@emindsoft.com.cn>

On Mon, Mar 28, 2016 at 10:49:54PM +0800, chengang@emindsoft.com.cn wrote:
> From: Chen Gang <chengang@emindsoft.com.cn>
> 
> The return value of pmd_trans_huge_lock() is a pointer, not a boolean
> value, so use NULL instead of false as the return value.
> 
> Signed-off-by: Chen Gang <gang.chen.5i5j@gmail.com>

Acked-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>

> ---
>  include/linux/huge_mm.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/include/linux/huge_mm.h b/include/linux/huge_mm.h
> index 79b0ef6..7008623 100644
> --- a/include/linux/huge_mm.h
> +++ b/include/linux/huge_mm.h
> @@ -127,7 +127,7 @@ static inline spinlock_t *pmd_trans_huge_lock(pmd_t *pmd,
>  	if (pmd_trans_huge(*pmd) || pmd_devmap(*pmd))
>  		return __pmd_trans_huge_lock(pmd, vma);
>  	else
> -		return false;
> +		return NULL;
>  }
>  static inline int hpage_nr_pages(struct page *page)
>  {
> -- 
> 1.9.3
> 

-- 
 Kirill A. Shutemov

      reply	other threads:[~2016-03-28 14:53 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-28 14:49 [PATCH trivial] include/linux/huge_mm.h: Return NULL instead of false for pmd_trans_huge_lock() chengang
2016-03-28 14:53 ` Kirill A. Shutemov [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=20160328145313.GA25200@node.shutemov.name \
    --to=kirill@shutemov.name \
    --cc=akpm@linux-foundation.org \
    --cc=chengang@emindsoft.com.cn \
    --cc=dan.j.williams@intel.co \
    --cc=dan.j.williams@intel.com \
    --cc=gang.chen.5i5j@gmail.com \
    --cc=jmarchan@redhat.com \
    --cc=kirill.shutemov@linux.intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mgorman@techsingularity.net \
    --cc=trivial@kernel.org \
    --cc=vbabka@suse.cz \
    --cc=willy@linux.intel.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.