Inter-revision diff: patch 29

Comparing rfc (message) to v1 (message)

--- vrfc
+++ v1
@@ -1,5 +1,13 @@
 Move remaining definitions and declarations from include/linux/bootmem.h
 into include/linux/memblock.h and remove the redundant header.
+
+The includes were replaced with the semantic patch below and then
+semi-automated removal of duplicated '#include <linux/memblock.h>
+
+@@
+@@
+- #include <linux/bootmem.h>
++ #include <linux/memblock.h>
 
 Signed-off-by: Mike Rapoport <rppt@linux.vnet.ibm.com>
 ---
@@ -89,7 +97,7 @@
  arch/mips/kernel/crash_dump.c               |   2 +-
  arch/mips/kernel/prom.c                     |   2 +-
  arch/mips/kernel/setup.c                    |   1 -
- arch/mips/kernel/traps.c                    |   2 +-
+ arch/mips/kernel/traps.c                    |   1 -
  arch/mips/kernel/vpe.c                      |   2 +-
  arch/mips/kvm/commpage.c                    |   2 +-
  arch/mips/kvm/dyntrans.c                    |   2 +-
@@ -275,7 +283,7 @@
  net/ipv4/udp.c                              |   2 +-
  net/sctp/protocol.c                         |   2 +-
  net/xfrm/xfrm_hash.c                        |   2 +-
- 272 files changed, 352 insertions(+), 474 deletions(-)
+ 272 files changed, 351 insertions(+), 474 deletions(-)
  delete mode 100644 include/linux/bootmem.h
 
 diff --git a/arch/alpha/kernel/core_cia.c b/arch/alpha/kernel/core_cia.c
@@ -494,7 +502,7 @@
  #include <linux/screen_info.h>
  #include <linux/of_platform.h>
 diff --git a/arch/arm/mach-omap2/omap_hwmod.c b/arch/arm/mach-omap2/omap_hwmod.c
-index 314284e..d940a2b 100644
+index 1f9b34a..cd5732a 100644
 --- a/arch/arm/mach-omap2/omap_hwmod.c
 +++ b/arch/arm/mach-omap2/omap_hwmod.c
 @@ -141,7 +141,7 @@
@@ -588,7 +596,7 @@
  #include <linux/init.h>
  #include <linux/kexec.h>
 diff --git a/arch/arm64/mm/dma-mapping.c b/arch/arm64/mm/dma-mapping.c
-index 072c51f..c06bae6 100644
+index cdcb73d..1469f96 100644
 --- a/arch/arm64/mm/dma-mapping.c
 +++ b/arch/arm64/mm/dma-mapping.c
 @@ -19,7 +19,7 @@
@@ -687,18 +695,18 @@
  
  #include <asm/setup.h>
 diff --git a/arch/hexagon/kernel/dma.c b/arch/hexagon/kernel/dma.c
-index 77459df..8e1d2a7 100644
+index ffc4ae8..45a1b42 100644
 --- a/arch/hexagon/kernel/dma.c
 +++ b/arch/hexagon/kernel/dma.c
-@@ -20,7 +20,7 @@
- 
- #include <linux/dma-mapping.h>
- #include <linux/dma-direct.h>
+@@ -19,7 +19,7 @@
+  */
+ 
+ #include <linux/dma-noncoherent.h>
 -#include <linux/bootmem.h>
 +#include <linux/memblock.h>
  #include <linux/genalloc.h>
- #include <asm/dma-mapping.h>
  #include <linux/module.h>
+ #include <asm/page.h>
 diff --git a/arch/hexagon/kernel/setup.c b/arch/hexagon/kernel/setup.c
 index dc8c7e7..b3c3e04 100644
 --- a/arch/hexagon/kernel/setup.c
@@ -1356,7 +1364,7 @@
  #include <linux/of.h>
  #include <linux/of_fdt.h>
 diff --git a/arch/mips/kernel/setup.c b/arch/mips/kernel/setup.c
-index 6d8d0c7..8d9e402 100644
+index 86c9eda..4efa8af 100644
 --- a/arch/mips/kernel/setup.c
 +++ b/arch/mips/kernel/setup.c
 @@ -15,7 +15,6 @@
@@ -1368,18 +1376,17 @@
  #include <linux/root_dev.h>
  #include <linux/highmem.h>
 diff --git a/arch/mips/kernel/traps.c b/arch/mips/kernel/traps.c
-index 31566d5..d4769a1 100644
+index 623dc18..0f852e1 100644
 --- a/arch/mips/kernel/traps.c
 +++ b/arch/mips/kernel/traps.c
-@@ -28,7 +28,7 @@
+@@ -28,7 +28,6 @@
  #include <linux/smp.h>
  #include <linux/spinlock.h>
  #include <linux/kallsyms.h>
 -#include <linux/bootmem.h>
-+#include <linux/memblock.h>
+ #include <linux/memblock.h>
  #include <linux/interrupt.h>
  #include <linux/ptrace.h>
- #include <linux/kgdb.h>
 diff --git a/arch/mips/kernel/vpe.c b/arch/mips/kernel/vpe.c
 index 0bef238..6176b9a 100644
 --- a/arch/mips/kernel/vpe.c
@@ -2454,7 +2461,7 @@
  #include <asm/irqdomain.h>
  #include <asm/io.h>
 diff --git a/arch/x86/kernel/cpu/common.c b/arch/x86/kernel/cpu/common.c
-index 44c4ef3..9a50a1e 100644
+index f48f0b9..344865c 100644
 --- a/arch/x86/kernel/cpu/common.c
 +++ b/arch/x86/kernel/cpu/common.c
 @@ -1,7 +1,7 @@
@@ -2596,7 +2603,7 @@
  #include <asm/io.h>
  #include <linux/pci_ids.h>
 diff --git a/arch/x86/mm/fault.c b/arch/x86/mm/fault.c
-index 47bebfe..258af30 100644
+index cf16dfe..b6381b0 100644
 --- a/arch/x86/mm/fault.c
 +++ b/arch/x86/mm/fault.c
 @@ -8,7 +8,7 @@
@@ -2865,10 +2872,12 @@
  #include <asm/page.h>
  #include <asm/pgtable.h>
 diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c
-index 2eeddd8..a3600b6 100644
+index 749fb4b..ec1394c 100644
 --- a/arch/x86/xen/enlighten.c
 +++ b/arch/x86/xen/enlighten.c
-@@ -1,5 +1,5 @@
+@@ -1,7 +1,7 @@
+ // SPDX-License-Identifier: GPL-2.0
+ 
  #ifdef CONFIG_XEN_BALLOON_MEMORY_HOTPLUG
 -#include <linux/bootmem.h>
 +#include <linux/memblock.h>
@@ -2876,7 +2885,7 @@
  #include <linux/cpu.h>
  #include <linux/kexec.h>
 diff --git a/arch/x86/xen/enlighten_pv.c b/arch/x86/xen/enlighten_pv.c
-index 52a7c3f..4367ac4 100644
+index ec7a420..2f6787f 100644
 --- a/arch/x86/xen/enlighten_pv.c
 +++ b/arch/x86/xen/enlighten_pv.c
 @@ -23,7 +23,7 @@
@@ -2897,10 +2906,10 @@
  #include <linux/frame.h>
  
 diff --git a/arch/x86/xen/p2m.c b/arch/x86/xen/p2m.c
-index 3cedc0b..c0ca672 100644
+index b3e11af..b067317 100644
 --- a/arch/x86/xen/p2m.c
 +++ b/arch/x86/xen/p2m.c
-@@ -65,7 +65,6 @@
+@@ -67,7 +67,6 @@
  #include <linux/hash.h>
  #include <linux/sched.h>
  #include <linux/seq_file.h>
@@ -2991,7 +3000,7 @@
  #include <linux/rtnetlink.h>
  #include <linux/platform_device.h>
 diff --git a/arch/xtensa/platforms/iss/setup.c b/arch/xtensa/platforms/iss/setup.c
-index a922511..e64c500 100644
+index 58709e8..c14cc67 100644
 --- a/arch/xtensa/platforms/iss/setup.c
 +++ b/arch/xtensa/platforms/iss/setup.c
 @@ -16,7 +16,7 @@
@@ -3246,7 +3255,7 @@
  #include <linux/mutex.h>
  #include <linux/of.h>
 diff --git a/drivers/of/unittest.c b/drivers/of/unittest.c
-index bc2a78f..b82538c 100644
+index 07c9217..5de5ceb 100644
 --- a/drivers/of/unittest.c
 +++ b/drivers/of/unittest.c
 @@ -5,7 +5,7 @@
@@ -3439,7 +3448,7 @@
  #include <linux/mm.h>
  #include <linux/mman.h>
 diff --git a/fs/dcache.c b/fs/dcache.c
-index 2e7e8d8..fe87489 100644
+index c2e443f..2593153 100644
 --- a/fs/dcache.c
 +++ b/fs/dcache.c
 @@ -26,7 +26,7 @@
@@ -3465,7 +3474,7 @@
  #include <linux/mount.h>
  #include <linux/posix_acl.h>
 diff --git a/fs/namespace.c b/fs/namespace.c
-index 1d20945..f59f085 100644
+index a240e20..8000a71 100644
 --- a/fs/namespace.c
 +++ b/fs/namespace.c
 @@ -24,7 +24,7 @@
@@ -3478,7 +3487,7 @@
  #include <linux/file.h>
  #include <linux/sched/task.h>
 diff --git a/fs/proc/kcore.c b/fs/proc/kcore.c
-index 50036f6..89b8a04 100644
+index d297fe4..bbcc185 100644
 --- a/fs/proc/kcore.c
 +++ b/fs/proc/kcore.c
 @@ -22,7 +22,7 @@
@@ -3694,7 +3703,7 @@
 -
 -#endif /* _LINUX_BOOTMEM_H */
 diff --git a/include/linux/memblock.h b/include/linux/memblock.h
-index ab5f11b..ccc8f44 100644
+index f16833c..d3bc270 100644
 --- a/include/linux/memblock.h
 +++ b/include/linux/memblock.h
 @@ -15,6 +15,19 @@
@@ -3728,7 +3737,7 @@
  /* Low level functions */
  int memblock_add_range(struct memblock_type *type,
  		       phys_addr_t base, phys_addr_t size,
-@@ -317,11 +334,116 @@ static inline int memblock_get_region_node(const struct memblock_region *r)
+@@ -315,11 +332,116 @@ static inline int memblock_get_region_node(const struct memblock_region *r)
  }
  #endif /* CONFIG_HAVE_MEMBLOCK_NODE_MAP */
  
@@ -3845,7 +3854,7 @@
  /*
   * Set the allocation direction to bottom-up or top-down.
   */
-@@ -340,10 +462,6 @@ static inline bool memblock_bottom_up(void)
+@@ -338,10 +460,6 @@ static inline bool memblock_bottom_up(void)
  	return memblock.bottom_up;
  }
  
@@ -3856,7 +3865,7 @@
  phys_addr_t __init memblock_alloc_range(phys_addr_t size, phys_addr_t align,
  					phys_addr_t start, phys_addr_t end,
  					enum memblock_flags flags);
-@@ -449,6 +567,31 @@ static inline unsigned long memblock_region_reserved_end_pfn(const struct memblo
+@@ -447,6 +565,31 @@ static inline unsigned long memblock_region_reserved_end_pfn(const struct memblo
  	     i < memblock_type->cnt;					\
  	     i++, rgn = &memblock_type->regions[i])
  
@@ -3967,7 +3976,7 @@
  #include <linux/syscalls.h>
  #include <linux/console.h>
 diff --git a/kernel/printk/printk.c b/kernel/printk/printk.c
-index 72e6d38..473a745 100644
+index 3efcbe518..54ebe01 100644
 --- a/kernel/printk/printk.c
 +++ b/kernel/printk/printk.c
 @@ -29,7 +29,6 @@
@@ -4005,7 +4014,7 @@
  /**
   * cpumask_next - get the next cpu in a cpumask
 diff --git a/mm/hugetlb.c b/mm/hugetlb.c
-index ee0b140..eb52e8a 100644
+index 67629dc..10b360e 100644
 --- a/mm/hugetlb.c
 +++ b/mm/hugetlb.c
 @@ -15,7 +15,6 @@
@@ -4047,7 +4056,7 @@
  #include <linux/mmzone.h>
  #include <linux/slab.h>
 diff --git a/mm/memblock.c b/mm/memblock.c
-index 6061914..1568727 100644
+index 86a4b80..32e5c62 100644
 --- a/mm/memblock.c
 +++ b/mm/memblock.c
 @@ -20,7 +20,6 @@
@@ -4071,7 +4080,7 @@
  
  #include <asm/tlbflush.h>
 diff --git a/mm/page_alloc.c b/mm/page_alloc.c
-index e143fae..8b58b3d 100644
+index f4a8bc8..511447a 100644
 --- a/mm/page_alloc.c
 +++ b/mm/page_alloc.c
 @@ -20,7 +20,6 @@
@@ -4171,7 +4180,7 @@
  #include <net/addrconf.h>
  #include <net/inet_connection_sock.h>
 diff --git a/net/ipv4/tcp.c b/net/ipv4/tcp.c
-index 8c4235c..718d436 100644
+index 67670fa..a74a4a7 100644
 --- a/net/ipv4/tcp.c
 +++ b/net/ipv4/tcp.c
 @@ -262,7 +262,7 @@
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help