From: Mike Rapoport <rppt@linux.ibm.com>
To: "Adeodato Simó" <dato@net.com.org.es>
Cc: linux-mm@kvack.org, kernel-janitors@vger.kernel.org
Subject: Re: [PATCH 2/3] mm: move two private functions to static linkage
Date: Tue, 4 Dec 2018 09:48:24 +0200 [thread overview]
Message-ID: <20181204074823.GG26700@rapoport-lnx> (raw)
In-Reply-To: <75cae66d92a074dbd62590a966d7005b187f4fe5.1543899764.git.dato@net.com.org.es>
On Tue, Dec 04, 2018 at 02:14:23AM -0300, Adeodato Sim� wrote:
> follow_page_context() and __thp_get_unmapped_area() have no public
> declarations and are only used in the files that define them (mm/gup.c
> and mm/huge_memory.c, respectively).
>
> This change also appeases GCC if run with -Wmissing-prototypes.
>
> Signed-off-by: Adeodato Sim� <dato@net.com.org.es>
Reviewed-by: Mike Rapoport <rppt@linux.ibm.com>
> ---
> mm/gup.c | 6 +++---
> mm/huge_memory.c | 5 +++--
> 2 files changed, 6 insertions(+), 5 deletions(-)
>
> diff --git a/mm/gup.c b/mm/gup.c
> index 6dd33e16a806..86a10a9b0344 100644
> --- a/mm/gup.c
> +++ b/mm/gup.c
> @@ -399,9 +399,9 @@ static struct page *follow_p4d_mask(struct vm_area_struct *vma,
> * an error pointer if there is a mapping to something not represented
> * by a page descriptor (see also vm_normal_page()).
> */
> -struct page *follow_page_mask(struct vm_area_struct *vma,
> - unsigned long address, unsigned int flags,
> - struct follow_page_context *ctx)
> +static struct page *follow_page_mask(struct vm_area_struct *vma,
> + unsigned long address, unsigned int flags,
> + struct follow_page_context *ctx)
> {
> pgd_t *pgd;
> struct page *page;
> diff --git a/mm/huge_memory.c b/mm/huge_memory.c
> index 2dba2c1c299a..45c1ff36baf1 100644
> --- a/mm/huge_memory.c
> +++ b/mm/huge_memory.c
> @@ -499,8 +499,9 @@ void prep_transhuge_page(struct page *page)
> set_compound_page_dtor(page, TRANSHUGE_PAGE_DTOR);
> }
>
> -unsigned long __thp_get_unmapped_area(struct file *filp, unsigned long len,
> - loff_t off, unsigned long flags, unsigned long size)
> +static unsigned long __thp_get_unmapped_area(struct file *filp,
> + unsigned long len, loff_t off, unsigned long flags,
> + unsigned long size)
> {
> unsigned long addr;
> loff_t off_end = off + len;
> --
> 2.19.2
>
--
Sincerely yours,
Mike.
next prev parent reply other threads:[~2018-12-04 7:48 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-12-04 5:14 [PATCH 1/3] mm: add include files so that function definitions have a prototype Adeodato Simó
2018-12-04 5:14 ` [PATCH 2/3] mm: move two private functions to static linkage Adeodato Simó
2018-12-04 7:48 ` Mike Rapoport [this message]
2018-12-04 5:14 ` [PATCH 3/3] mm: add missing declaration of memmap_init in linux/mm.h Adeodato Simó
2018-12-04 7:48 ` Mike Rapoport
2018-12-04 7:47 ` [PATCH 1/3] mm: add include files so that function definitions have a prototype Mike Rapoport
2019-01-17 10:36 ` Adeodato Simó
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=20181204074823.GG26700@rapoport-lnx \
--to=rppt@linux.ibm.com \
--cc=dato@net.com.org.es \
--cc=kernel-janitors@vger.kernel.org \
--cc=linux-mm@kvack.org \
/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