+ mm-throttle-allocators-when-failing-reclaim-over-memoryhigh-fix.patch added to -mm tree

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

 



The patch titled
     Subject: mm-throttle-allocators-when-failing-reclaim-over-memoryhigh-fix
has been added to the -mm tree.  Its filename is
     mm-throttle-allocators-when-failing-reclaim-over-memoryhigh-fix.patch

This patch should soon appear at
    http://ozlabs.org/~akpm/mmots/broken-out/mm-throttle-allocators-when-failing-reclaim-over-memoryhigh-fix.patch
and later at
    http://ozlabs.org/~akpm/mmotm/broken-out/mm-throttle-allocators-when-failing-reclaim-over-memoryhigh-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: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
Subject: mm-throttle-allocators-when-failing-reclaim-over-memoryhigh-fix

fix max() warning

mm/memcontrol.c: In function mem_cgroup_handle_over_high:
./include/linux/kernel.h:821:29: warning: comparison of distinct pointer types lacks a cast
   (!!(sizeof((typeof(x) *)1 == (typeof(y) *)1)))
                             ^
./include/linux/kernel.h:835:4: note: in expansion of macro __typecheck
   (__typecheck(x, y) && __no_side_effects(x, y))
    ^~~~~~~~~~~
./include/linux/kernel.h:845:24: note: in expansion of macro __safe_cmp
  __builtin_choose_expr(__safe_cmp(x, y), \
                        ^~~~~~~~~~
./include/linux/kernel.h:861:19: note: in expansion of macro __careful_cmp
 #define max(x, y) __careful_cmp(x, y, >)
                   ^~~~~~~~~~~~~
mm/memcontrol.c:2420:17: note: in expansion of macro max
  clamped_high = max(high, 1);

Cc: Chris Down <chris@xxxxxxxxxxxxxx>

Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 mm/memcontrol.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/mm/memcontrol.c~mm-throttle-allocators-when-failing-reclaim-over-memoryhigh-fix
+++ a/mm/memcontrol.c
@@ -2417,7 +2417,7 @@ void mem_cgroup_handle_over_high(void)
 	 * Prevent division by 0 in overage calculation by acting as if it was a
 	 * threshold of 1 page
 	 */
-	clamped_high = max(high, 1);
+	clamped_high = max(high, 1UL);
 
 	overage = ((u64)(usage - high) << MEMCG_DELAY_PRECISION_SHIFT)
 		/ clamped_high;
_

Patches currently in -mm which might be from akpm@xxxxxxxxxxxxxxxxxxxx are

asm-generic-fix-wtype-limits-compiler-warnings-fix.patch
ocfs2-clear-zero-in-unaligned-direct-io-checkpatch-fixes.patch
mm.patch
mm-introduce-page_shift-fix.patch
mm-memory_hotplug-remove-move_pfn_range-fix.patch
mm-compaction-clear-total_migratefree_scanned-before-scanning-a-new-zone-fix-fix.patch
mm-compaction-clear-total_migratefree_scanned-before-scanning-a-new-zone-fix-2-fix.patch
mm-oom-avoid-printk-iteration-under-rcu-fix.patch
mm-oom_killer-add-task-uid-to-info-message-on-an-oom-kill-fix.patch
psi-annotate-refault-stalls-from-io-submission-fix.patch
diff-sucks.patch
drivers-tty-serial-sh-scic-suppress-warning.patch
kernel-forkc-export-kernel_thread-to-modules.patch
mm-throttle-allocators-when-failing-reclaim-over-memoryhigh-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