[folded-merged] mm-memcontrol-drop-unused-try-commit-cancel-charge-api-fix.patch removed from -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled
     Subject: mm: memcontrol: fix an unused-function warning
has been removed from the -mm tree.  Its filename was
     mm-memcontrol-drop-unused-try-commit-cancel-charge-api-fix.patch

This patch was dropped because it was folded into mm-memcontrol-drop-unused-try-commit-cancel-charge-api.patch

------------------------------------------------------
From: Arnd Bergmann <arnd@xxxxxxxx>
Subject: mm: memcontrol: fix an unused-function warning

On NOMMU kernels without CONFIG_MEMCG_KMEM, we now get a harmless
warning about an unused function:

mm/memcontrol.c:2595:13: error: unused function 'cancel_charge' [-Werror,-Wunused-function]

Hide this function in a matching #ifdef.

Link: http://lkml.kernel.org/r/20200528095640.151454-1-arnd@xxxxxxxx
Fixes: 5bd144bf764c ("mm: memcontrol: drop unused try/commit/cancel charge API")
Signed-off-by: Arnd Bergmann <arnd@xxxxxxxx>
Acked-by: Johannes Weiner <hannes@xxxxxxxxxxx>
Acked-by: Michal Hocko <mhocko@xxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 mm/memcontrol.c |    2 ++
 1 file changed, 2 insertions(+)

--- a/mm/memcontrol.c~mm-memcontrol-drop-unused-try-commit-cancel-charge-api-fix
+++ a/mm/memcontrol.c
@@ -2641,6 +2641,7 @@ done_restock:
 	return 0;
 }
 
+#if defined(CONFIG_MEMCG_KMEM) || defined(CONFIG_MMU)
 static void cancel_charge(struct mem_cgroup *memcg, unsigned int nr_pages)
 {
 	if (mem_cgroup_is_root(memcg))
@@ -2652,6 +2653,7 @@ static void cancel_charge(struct mem_cgr
 
 	css_put_many(&memcg->css, nr_pages);
 }
+#endif
 
 static void lock_page_lru(struct page *page, int *isolated)
 {
_

Patches currently in -mm which might be from arnd@xxxxxxxx are

mm-memcontrol-drop-unused-try-commit-cancel-charge-api.patch
drm-remove-drm-specific-kmap_atomic-code-fix.patch
bitops-avoid-clang-shift-count-overflow-warnings.patch
ubsan-fix-gcc-10-warnings.patch
arm64-add-support-for-folded-p4d-page-tables-fix.patch




[Index of Archives]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux