From: Hugh Dickins <hughd@google.com>
To: Wang Sheng-Hui <shhuiw@gmail.com>
Cc: linux-mm@kvack.org
Subject: Re: [PATCH] mm: remove the unused gfp arg to shmem_add_to_page_cache
Date: Mon, 14 Jul 2014 21:03:21 -0700 (PDT) [thread overview]
Message-ID: <alpine.LSU.2.11.1407142047390.983@eggly.anvils> (raw)
In-Reply-To: <53C46CBE.60605@gmail.com>
On Tue, 15 Jul 2014, Wang Sheng-Hui wrote:
>
> The gfp arg is not used in shmem_add_to_page_cache.
> Remove this unused arg.
>
> Signed-off-by: Wang Sheng-Hui <shhuiw@gmail.com>
Looks right, but checkpatch.pl has some complaints about the spaces:
please fix those. Maybe you started off with tabs, and gmail turned
them into spaces. gmail is an outstandingly excellent mailer (;)
but unhelpful on patches. See Documentation/email-clients.txt or
Documentation/zh_CN/email-clients.txt. Maybe "git send-email" will
get around it for you.
Thanks,
Hugh
> ---
> mm/shmem.c | 8 ++++----
> 1 file changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/mm/shmem.c b/mm/shmem.c
> index 1140f49..63cc6af 100644
> --- a/mm/shmem.c
> +++ b/mm/shmem.c
> @@ -280,7 +280,7 @@ static bool shmem_confirm_swap(struct address_space *mapping,
> */
> static int shmem_add_to_page_cache(struct page *page,
> struct address_space *mapping,
> - pgoff_t index, gfp_t gfp, void *expected)
> + pgoff_t index, void *expected)
> {
> int error;
>
> @@ -643,7 +643,7 @@ static int shmem_unuse_inode(struct shmem_inode_info *info,
> */
> if (!error)
> error = shmem_add_to_page_cache(*pagep, mapping, index,
> - GFP_NOWAIT, radswap);
> + radswap);
> if (error != -ENOMEM) {
> /*
> * Truncation and eviction use free_swap_and_cache(), which
> @@ -1089,7 +1089,7 @@ repeat:
> gfp & GFP_RECLAIM_MASK);
> if (!error) {
> error = shmem_add_to_page_cache(page, mapping, index,
> - gfp, swp_to_radix_entry(swap));
> + swp_to_radix_entry(swap));
> /*
> * We already confirmed swap under page lock, and make
> * no memory allocation here, so usually no possibility
> @@ -1152,7 +1152,7 @@ repeat:
> error = radix_tree_maybe_preload(gfp & GFP_RECLAIM_MASK);
> if (!error) {
> error = shmem_add_to_page_cache(page, mapping, index,
> - gfp, NULL);
> + NULL);
> radix_tree_preload_end();
> }
> if (error) {
> --
> 1.8.3.2
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next prev parent reply other threads:[~2014-07-15 4:05 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-14 23:50 Wang Sheng-Hui
2014-07-15 4:03 ` Hugh Dickins [this message]
2014-07-16 1:48 Wang Sheng-Hui
2014-07-16 19:30 ` Hugh Dickins
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=alpine.LSU.2.11.1407142047390.983@eggly.anvils \
--to=hughd@google.com \
--cc=linux-mm@kvack.org \
--cc=shhuiw@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox