mm-commits.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* + mm-thp-check-total_mapcount-instead-of-page_mapcount-fix.patch added to -mm tree
@ 2021-05-14 22:28 akpm
  0 siblings, 0 replies; only message in thread
From: akpm @ 2021-05-14 22:28 UTC (permalink / raw)
  To: mm-commits, pulehui, shy828301


The patch titled
     Subject: mm/huge_memory.c: remove unused variable 'count'
has been added to the -mm tree.  Its filename is
     mm-thp-check-total_mapcount-instead-of-page_mapcount-fix.patch

This patch should soon appear at
    https://ozlabs.org/~akpm/mmots/broken-out/mm-thp-check-total_mapcount-instead-of-page_mapcount-fix.patch
and later at
    https://ozlabs.org/~akpm/mmotm/broken-out/mm-thp-check-total_mapcount-instead-of-page_mapcount-fix.patch

Before you just go and hit "reply", please:
   a) Consider who else should be cc'ed
   b) Prefer to cc a suitable mailing list as well
   c) Ideally: find the original patch on the mailing list and do a
      reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/process/submit-checklist.rst when testing your code ***

The -mm tree is included into linux-next and is updated
there every 3-4 working days

------------------------------------------------------
From: Pu Lehui <pulehui@huawei.com>
Subject: mm/huge_memory.c: remove unused variable 'count'

mm/huge_memory.c:2663:6: warning:
 variable `count' set but not used [-Wunused-but-set-variable]
  2663 |  int count, mapcount, extra_pins, ret;
       |      ^~~~~

This variable is not used in function , this commit
remove it to fix the warning.

Link: https://lkml.kernel.org/r/20210514065912.71734-1-pulehui@huawei.com
Signed-off-by: Pu Lehui <pulehui@huawei.com>
Cc: Yang Shi <shy828301@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---

 mm/huge_memory.c |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

--- a/mm/huge_memory.c~mm-thp-check-total_mapcount-instead-of-page_mapcount-fix
+++ a/mm/huge_memory.c
@@ -2660,7 +2660,7 @@ int split_huge_page_to_list(struct page
 	struct deferred_split *ds_queue = get_deferred_split_queue(head);
 	struct anon_vma *anon_vma = NULL;
 	struct address_space *mapping = NULL;
-	int count, mapcount, extra_pins, ret;
+	int mapcount, extra_pins, ret;
 	pgoff_t end;
 
 	VM_BUG_ON_PAGE(is_huge_zero_page(head), head);
@@ -2737,7 +2737,6 @@ int split_huge_page_to_list(struct page
 
 	/* Prevent deferred_split_scan() touching ->_refcount */
 	spin_lock(&ds_queue->split_queue_lock);
-	count = page_count(head);
 	mapcount = total_mapcount(head);
 	if (!mapcount && page_ref_freeze(head, 1 + extra_pins)) {
 		if (!list_empty(page_deferred_list(head))) {
_

Patches currently in -mm which might be from pulehui@huawei.com are

mm-thp-check-total_mapcount-instead-of-page_mapcount-fix.patch


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-05-14 22:28 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-14 22:28 + mm-thp-check-total_mapcount-instead-of-page_mapcount-fix.patch added to -mm tree akpm

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).