From: Mike Kravetz <mike.kravetz@oracle.com>
To: Nicholas Krause <xerofoify@gmail.com>, akpm@linux-foundation.org
Cc: n-horiguchi@ah.jp.nec.com, rientjes@google.com,
dave@stgolabs.net, lcapitulino@redhat.com, linux-mm@kvack.or,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] hugetlb:Make the function vma_shareable bool
Date: Thu, 25 Jun 2015 21:18:20 -0700 [thread overview]
Message-ID: <558CD28C.5090201@oracle.com> (raw)
In-Reply-To: <1435281568-22312-1-git-send-email-xerofoify@gmail.com>
On 06/25/2015 06:19 PM, Nicholas Krause wrote:
> This makes the function vma_shareable bool now due to this
> particular function only ever returning either one or zero
> as its return value.
>
> Signed-off-by: Nicholas Krause <xerofoify@gmail.com>
> ---
> mm/hugetlb.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/mm/hugetlb.c b/mm/hugetlb.c
> index 75c0eef..c1be0d1 100644
> --- a/mm/hugetlb.c
> +++ b/mm/hugetlb.c
> @@ -3789,7 +3789,7 @@ static unsigned long page_table_shareable(struct vm_area_struct *svma,
> return saddr;
> }
>
> -static int vma_shareable(struct vm_area_struct *vma, unsigned long addr)
> +static bool vma_shareable(struct vm_area_struct *vma, unsigned long addr)
> {
> unsigned long base = addr & PUD_MASK;
> unsigned long end = base + PUD_SIZE;
> @@ -3799,8 +3799,8 @@ static int vma_shareable(struct vm_area_struct *vma, unsigned long addr)
> */
> if (vma->vm_flags & VM_MAYSHARE &&
> vma->vm_start <= base && end <= vma->vm_end)
> - return 1;
> - return 0;
> + return true;
> + return false;
> }
>
> /*
>
I was looking at the page table sharing code just last week.
Acked-by: Mike Kravetz <mike.kravetz@oracle.com>
--
Mike Kravetz
next parent reply other threads:[~2015-06-26 4:18 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <1435281568-22312-1-git-send-email-xerofoify@gmail.com>
2015-06-26 4:18 ` Mike Kravetz [this message]
2015-06-26 5:09 ` [PATCH] hugetlb:Make the function vma_shareable bool Naoya Horiguchi
2015-06-30 22:12 ` David Rientjes
[not found] ` <55949A95.3020506@gmail.com>
2015-07-08 23:51 ` David Rientjes
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=558CD28C.5090201@oracle.com \
--to=mike.kravetz@oracle.com \
--cc=akpm@linux-foundation.org \
--cc=dave@stgolabs.net \
--cc=lcapitulino@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.or \
--cc=n-horiguchi@ah.jp.nec.com \
--cc=rientjes@google.com \
--cc=xerofoify@gmail.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.