[merged] avoid-a-warning-in-sparse-memory-support.patch removed from -mm tree

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

 



The patch titled
     Subject: include/linux/mmzone.h: avoid a warning in sparse memory support
has been removed from the -mm tree.  Its filename was
     avoid-a-warning-in-sparse-memory-support.patch

This patch was dropped because it was merged into mainline or a subsystem tree

------------------------------------------------------
From: Matthew Wilcox <willy@xxxxxxxxxxxxx>
Subject: include/linux/mmzone.h: avoid a warning in sparse memory support

cppcheck warns that we're possibly losing information by shifting an int. 
It's a false positive, because we don't allow for a NUMA node ID that
large, but if we ever change SECTION_NID_SHIFT, it could become a problem,
and in any case this is usually a legitimate warning.  Fix it by adding
the necessary cast, which makes the compiler generate the right code.

Link: https://lkml.kernel.org/r/YOya+aBZFFmC476e@xxxxxxxxxxxxxxxxxxxx
Link: https://lkml.kernel.org/r/202107130348.6LsVT9Nc-lkp@xxxxxxxxx
Cc: Mike Rapoport <rppt@xxxxxxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

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

--- a/mm/sparse.c~avoid-a-warning-in-sparse-memory-support
+++ a/mm/sparse.c
@@ -117,7 +117,7 @@ static inline int sparse_index_init(unsi
  */
 static inline unsigned long sparse_encode_early_nid(int nid)
 {
-	return (nid << SECTION_NID_SHIFT);
+	return ((unsigned long)nid << SECTION_NID_SHIFT);
 }
 
 static inline int sparse_early_nid(struct mem_section *section)
_

Patches currently in -mm which might be from willy@xxxxxxxxxxxxx are

mm-remove-bogus-vm_bug_on.patch
mm-mark-idle-page-tracking-as-broken.patch
mm-move-kvmalloc-related-functions-to-slabh.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