kernel/resource.c:1653:28: error: 'PA_SECTION_SHIFT' undeclared; did you mean 'SECTIONS_PGSHIFT'?

From: kbuild test robot
Date: Wed Jan 08 2020 - 07:43:54 EST


tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: ae6088216ce4b99b3a4aaaccd2eb2dd40d473d42
commit: 013a53f2d25a9fa9b9e1f70f5baa3f56e3454052 powerpc: Ultravisor: Add PPC_UV config option
date: 6 weeks ago
config: powerpc-randconfig-a001-20200108 (attached as .config)
compiler: powerpc64le-linux-gcc (GCC) 7.5.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
git checkout 013a53f2d25a9fa9b9e1f70f5baa3f56e3454052
# save the attached .config to linux build tree
GCC_VERSION=7.5.0 make.cross ARCH=powerpc

If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp@xxxxxxxxx>

All error/warnings (new ones prefixed by >>):

In file included from include/linux/cache.h:5:0,
from include/linux/printk.h:9,
from include/linux/kernel.h:15,
from include/asm-generic/bug.h:19,
from arch/powerpc/include/asm/bug.h:120,
from include/linux/bug.h:5,
from include/linux/mmdebug.h:5,
from include/linux/gfp.h:5,
from include/linux/slab.h:15,
from kernel/resource.c:17:
kernel/resource.c: In function '__request_free_mem_region':
>> kernel/resource.c:1653:28: error: 'PA_SECTION_SHIFT' undeclared (first use in this function); did you mean 'SECTIONS_PGSHIFT'?
size = ALIGN(size, 1UL << PA_SECTION_SHIFT);
^
include/uapi/linux/kernel.h:11:47: note: in definition of macro '__ALIGN_KERNEL_MASK'
#define __ALIGN_KERNEL_MASK(x, mask) (((x) + (mask)) & ~(mask))
^~~~
>> include/linux/kernel.h:33:22: note: in expansion of macro '__ALIGN_KERNEL'
#define ALIGN(x, a) __ALIGN_KERNEL((x), (a))
^~~~~~~~~~~~~~
>> kernel/resource.c:1653:9: note: in expansion of macro 'ALIGN'
size = ALIGN(size, 1UL << PA_SECTION_SHIFT);
^~~~~
kernel/resource.c:1653:28: note: each undeclared identifier is reported only once for each function it appears in
size = ALIGN(size, 1UL << PA_SECTION_SHIFT);
^
include/uapi/linux/kernel.h:11:47: note: in definition of macro '__ALIGN_KERNEL_MASK'
#define __ALIGN_KERNEL_MASK(x, mask) (((x) + (mask)) & ~(mask))
^~~~
>> include/linux/kernel.h:33:22: note: in expansion of macro '__ALIGN_KERNEL'
#define ALIGN(x, a) __ALIGN_KERNEL((x), (a))
^~~~~~~~~~~~~~
>> kernel/resource.c:1653:9: note: in expansion of macro 'ALIGN'
size = ALIGN(size, 1UL << PA_SECTION_SHIFT);
^~~~~
--
In file included from include/linux/mmzone.h:811:0,
from include/linux/gfp.h:6,
from include/linux/xarray.h:14,
from include/linux/radix-tree.h:18,
from include/linux/fs.h:15,
from mm/vmstat.c:13:
mm/vmstat.c: In function 'pagetypeinfo_showblockcount_print':
>> include/linux/memory_hotplug.h:28:24: error: implicit declaration of function 'pfn_to_section_nr'; did you mean '__section'? [-Werror=implicit-function-declaration]
unsigned long ___nr = pfn_to_section_nr(___pfn); \
^
mm/vmstat.c:1443:10: note: in expansion of macro 'pfn_to_online_page'
page = pfn_to_online_page(pfn);
^~~~~~~~~~~~~~~~~~
>> include/linux/memory_hotplug.h:30:14: error: 'NR_MEM_SECTIONS' undeclared (first use in this function); did you mean 'END_FTR_SECTION'?
if (___nr < NR_MEM_SECTIONS && online_section_nr(___nr) && \
^
mm/vmstat.c:1443:10: note: in expansion of macro 'pfn_to_online_page'
page = pfn_to_online_page(pfn);
^~~~~~~~~~~~~~~~~~
include/linux/memory_hotplug.h:30:14: note: each undeclared identifier is reported only once for each function it appears in
if (___nr < NR_MEM_SECTIONS && online_section_nr(___nr) && \
^
mm/vmstat.c:1443:10: note: in expansion of macro 'pfn_to_online_page'
page = pfn_to_online_page(pfn);
^~~~~~~~~~~~~~~~~~
>> include/linux/memory_hotplug.h:30:33: error: implicit declaration of function 'online_section_nr' [-Werror=implicit-function-declaration]
if (___nr < NR_MEM_SECTIONS && online_section_nr(___nr) && \
^
mm/vmstat.c:1443:10: note: in expansion of macro 'pfn_to_online_page'
page = pfn_to_online_page(pfn);
^~~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
--
In file included from include/linux/mmzone.h:811:0,
from include/linux/gfp.h:6,
from include/linux/xarray.h:14,
from include/linux/radix-tree.h:18,
from include/linux/idr.h:15,
from include/linux/kernfs.h:13,
from include/linux/sysfs.h:16,
from include/linux/kobject.h:20,
from include/linux/device.h:16,
from include/linux/node.h:18,
from include/linux/cpu.h:17,
from mm/compaction.c:11:
mm/compaction.c: In function '__reset_isolation_pfn':
>> include/linux/memory_hotplug.h:28:24: error: implicit declaration of function 'pfn_to_section_nr'; did you mean '__section'? [-Werror=implicit-function-declaration]
unsigned long ___nr = pfn_to_section_nr(___pfn); \
^
mm/compaction.c:244:22: note: in expansion of macro 'pfn_to_online_page'
struct page *page = pfn_to_online_page(pfn);
^~~~~~~~~~~~~~~~~~
>> include/linux/memory_hotplug.h:30:14: error: 'NR_MEM_SECTIONS' undeclared (first use in this function); did you mean 'END_FTR_SECTION'?
if (___nr < NR_MEM_SECTIONS && online_section_nr(___nr) && \
^
mm/compaction.c:244:22: note: in expansion of macro 'pfn_to_online_page'
struct page *page = pfn_to_online_page(pfn);
^~~~~~~~~~~~~~~~~~
include/linux/memory_hotplug.h:30:14: note: each undeclared identifier is reported only once for each function it appears in
if (___nr < NR_MEM_SECTIONS && online_section_nr(___nr) && \
^
mm/compaction.c:244:22: note: in expansion of macro 'pfn_to_online_page'
struct page *page = pfn_to_online_page(pfn);
^~~~~~~~~~~~~~~~~~
>> include/linux/memory_hotplug.h:30:33: error: implicit declaration of function 'online_section_nr' [-Werror=implicit-function-declaration]
if (___nr < NR_MEM_SECTIONS && online_section_nr(___nr) && \
^
mm/compaction.c:244:22: note: in expansion of macro 'pfn_to_online_page'
struct page *page = pfn_to_online_page(pfn);
^~~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
--
In file included from include/linux/mmzone.h:811:0,
from include/linux/gfp.h:6,
from include/linux/mm.h:10,
from mm/page_alloc.c:19:
mm/page_alloc.c: In function '__pageblock_pfn_to_page':
>> include/linux/memory_hotplug.h:28:24: error: implicit declaration of function 'pfn_to_section_nr'; did you mean 'pfn_to_bitidx'? [-Werror=implicit-function-declaration]
unsigned long ___nr = pfn_to_section_nr(___pfn); \
^
mm/page_alloc.c:1534:15: note: in expansion of macro 'pfn_to_online_page'
start_page = pfn_to_online_page(start_pfn);
^~~~~~~~~~~~~~~~~~
>> include/linux/memory_hotplug.h:30:14: error: 'NR_MEM_SECTIONS' undeclared (first use in this function); did you mean 'END_FTR_SECTION'?
if (___nr < NR_MEM_SECTIONS && online_section_nr(___nr) && \
^
mm/page_alloc.c:1534:15: note: in expansion of macro 'pfn_to_online_page'
start_page = pfn_to_online_page(start_pfn);
^~~~~~~~~~~~~~~~~~
include/linux/memory_hotplug.h:30:14: note: each undeclared identifier is reported only once for each function it appears in
if (___nr < NR_MEM_SECTIONS && online_section_nr(___nr) && \
^
mm/page_alloc.c:1534:15: note: in expansion of macro 'pfn_to_online_page'
start_page = pfn_to_online_page(start_pfn);
^~~~~~~~~~~~~~~~~~
>> include/linux/memory_hotplug.h:30:33: error: implicit declaration of function 'online_section_nr' [-Werror=implicit-function-declaration]
if (___nr < NR_MEM_SECTIONS && online_section_nr(___nr) && \
^
mm/page_alloc.c:1534:15: note: in expansion of macro 'pfn_to_online_page'
start_page = pfn_to_online_page(start_pfn);
^~~~~~~~~~~~~~~~~~
mm/page_alloc.c: In function '__offline_isolated_pages':
>> mm/page_alloc.c:8575:2: error: implicit declaration of function 'offline_mem_sections'; did you mean 'link_mem_sections'? [-Werror=implicit-function-declaration]
offline_mem_sections(pfn, end_pfn);
^~~~~~~~~~~~~~~~~~~~
link_mem_sections
cc1: some warnings being treated as errors
--
mm/memory_hotplug.c: In function 'add_memory_resource':
>> mm/memory_hotplug.c:1051:8: error: implicit declaration of function 'create_memory_block_devices'; did you mean 'set_memory_block_size_order'? [-Werror=implicit-function-declaration]
ret = create_memory_block_devices(start, size);
^~~~~~~~~~~~~~~~~~~~~~~~~~~
set_memory_block_size_order
>> mm/memory_hotplug.c:1080:3: error: implicit declaration of function 'walk_memory_blocks'; did you mean 'online_memory_block'? [-Werror=implicit-function-declaration]
walk_memory_blocks(start, size, NULL, online_memory_block);
^~~~~~~~~~~~~~~~~~
online_memory_block
mm/memory_hotplug.c: In function 'test_pages_in_a_zone':
>> mm/memory_hotplug.c:1207:38: error: implicit declaration of function 'SECTION_ALIGN_UP'; did you mean 'SET_UNALIGN_CTL'? [-Werror=implicit-function-declaration]
for (pfn = start_pfn, sec_end_pfn = SECTION_ALIGN_UP(start_pfn + 1);
^~~~~~~~~~~~~~~~
SET_UNALIGN_CTL
>> mm/memory_hotplug.c:1209:41: error: 'PAGES_PER_SECTION' undeclared (first use in this function); did you mean 'BEGIN_FTR_SECTION'?
pfn = sec_end_pfn, sec_end_pfn += PAGES_PER_SECTION) {
^~~~~~~~~~~~~~~~~
BEGIN_FTR_SECTION
mm/memory_hotplug.c:1209:41: note: each undeclared identifier is reported only once for each function it appears in
>> mm/memory_hotplug.c:1211:8: error: implicit declaration of function 'present_section_nr'; did you mean 'rq_end_sector'? [-Werror=implicit-function-declaration]
if (!present_section_nr(pfn_to_section_nr(pfn)))
^~~~~~~~~~~~~~~~~~
rq_end_sector
>> mm/memory_hotplug.c:1211:27: error: implicit declaration of function 'pfn_to_section_nr'; did you mean '__section'? [-Werror=implicit-function-declaration]
if (!present_section_nr(pfn_to_section_nr(pfn)))
^~~~~~~~~~~~~~~~~
__section
In file included from include/asm-generic/memory_model.h:5:0,
from arch/powerpc/include/asm/page.h:328,
from arch/powerpc/include/asm/mmu.h:132,
from arch/powerpc/include/asm/lppaca.h:47,
from arch/powerpc/include/asm/paca.h:17,
from arch/powerpc/include/asm/current.h:13,
from include/linux/thread_info.h:21,
from include/asm-generic/preempt.h:5,
from ./arch/powerpc/include/generated/asm/preempt.h:1,
from include/linux/preempt.h:78,
from include/linux/spinlock.h:51,
from include/linux/mmzone.h:8,
from include/linux/gfp.h:6,
from include/linux/mm.h:10,
from mm/memory_hotplug.c:9:
mm/memory_hotplug.c: In function 'check_memblock_offlined_cb':
>> mm/memory_hotplug.c:1623:22: error: implicit declaration of function 'section_nr_to_pfn' [-Werror=implicit-function-declaration]
beginpa = PFN_PHYS(section_nr_to_pfn(mem->start_section_nr));
^
include/linux/pfn.h:21:36: note: in definition of macro 'PFN_PHYS'
#define PFN_PHYS(x) ((phys_addr_t)(x) << PAGE_SHIFT)
^
mm/memory_hotplug.c: In function 'try_offline_node':
mm/memory_hotplug.c:1665:46: error: 'PAGES_PER_SECTION' undeclared (first use in this function); did you mean 'BEGIN_FTR_SECTION'?
for (pfn = start_pfn; pfn < end_pfn; pfn += PAGES_PER_SECTION) {
^~~~~~~~~~~~~~~~~
BEGIN_FTR_SECTION
mm/memory_hotplug.c: In function 'try_remove_memory':
>> mm/memory_hotplug.c:1736:2: error: implicit declaration of function 'remove_memory_block_devices'; did you mean 'arch_get_memory_phys_device'? [-Werror=implicit-function-declaration]
remove_memory_block_devices(start, size);
^~~~~~~~~~~~~~~~~~~~~~~~~~~
arch_get_memory_phys_device
mm/memory_hotplug.c: At top level:
mm/memory_hotplug.c:52:13: warning: 'generic_online_page' used but never defined
static void generic_online_page(struct page *page, unsigned int order);
^~~~~~~~~~~~~~~~~~~
mm/memory_hotplug.c:54:31: warning: 'online_page_callback' defined but not used [-Wunused-variable]
static online_page_callback_t online_page_callback = generic_online_page;
^~~~~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
--
In file included from include/linux/mmzone.h:811:0,
from include/linux/gfp.h:6,
from include/linux/xarray.h:14,
from include/linux/radix-tree.h:18,
from include/linux/fs.h:15,
from include/linux/debugfs.h:15,
from mm/page_owner.c:2:
mm/page_owner.c: In function 'pagetypeinfo_showmixedcount_print':
>> include/linux/memory_hotplug.h:28:24: error: implicit declaration of function 'pfn_to_section_nr'; did you mean '__section'? [-Werror=implicit-function-declaration]
unsigned long ___nr = pfn_to_section_nr(___pfn); \
^
mm/page_owner.c:274:10: note: in expansion of macro 'pfn_to_online_page'
page = pfn_to_online_page(pfn);
^~~~~~~~~~~~~~~~~~
>> include/linux/memory_hotplug.h:30:14: error: 'NR_MEM_SECTIONS' undeclared (first use in this function); did you mean 'END_FTR_SECTION'?
if (___nr < NR_MEM_SECTIONS && online_section_nr(___nr) && \
^
mm/page_owner.c:274:10: note: in expansion of macro 'pfn_to_online_page'
page = pfn_to_online_page(pfn);
^~~~~~~~~~~~~~~~~~
include/linux/memory_hotplug.h:30:14: note: each undeclared identifier is reported only once for each function it appears in
if (___nr < NR_MEM_SECTIONS && online_section_nr(___nr) && \
^
mm/page_owner.c:274:10: note: in expansion of macro 'pfn_to_online_page'
page = pfn_to_online_page(pfn);
^~~~~~~~~~~~~~~~~~
>> include/linux/memory_hotplug.h:30:33: error: implicit declaration of function 'online_section_nr' [-Werror=implicit-function-declaration]
if (___nr < NR_MEM_SECTIONS && online_section_nr(___nr) && \
^
mm/page_owner.c:274:10: note: in expansion of macro 'pfn_to_online_page'
page = pfn_to_online_page(pfn);
^~~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
--
In file included from include/linux/mmzone.h:811:0,
from include/linux/gfp.h:6,
from include/linux/mm.h:10,
from mm/page_isolation.c:6:
mm/page_isolation.c: In function '__first_valid_page':
>> include/linux/memory_hotplug.h:28:24: error: implicit declaration of function 'pfn_to_section_nr'; did you mean '__section'? [-Werror=implicit-function-declaration]
unsigned long ___nr = pfn_to_section_nr(___pfn); \
^
mm/page_isolation.c:154:10: note: in expansion of macro 'pfn_to_online_page'
page = pfn_to_online_page(pfn + i);
^~~~~~~~~~~~~~~~~~
>> include/linux/memory_hotplug.h:30:14: error: 'NR_MEM_SECTIONS' undeclared (first use in this function); did you mean 'END_FTR_SECTION'?
if (___nr < NR_MEM_SECTIONS && online_section_nr(___nr) && \
^
mm/page_isolation.c:154:10: note: in expansion of macro 'pfn_to_online_page'
page = pfn_to_online_page(pfn + i);
^~~~~~~~~~~~~~~~~~
include/linux/memory_hotplug.h:30:14: note: each undeclared identifier is reported only once for each function it appears in
if (___nr < NR_MEM_SECTIONS && online_section_nr(___nr) && \
^
mm/page_isolation.c:154:10: note: in expansion of macro 'pfn_to_online_page'
page = pfn_to_online_page(pfn + i);
^~~~~~~~~~~~~~~~~~
>> include/linux/memory_hotplug.h:30:33: error: implicit declaration of function 'online_section_nr' [-Werror=implicit-function-declaration]
if (___nr < NR_MEM_SECTIONS && online_section_nr(___nr) && \
^
mm/page_isolation.c:154:10: note: in expansion of macro 'pfn_to_online_page'
page = pfn_to_online_page(pfn + i);
^~~~~~~~~~~~~~~~~~
mm/page_isolation.c: In function 'start_isolate_page_range':
>> include/linux/memory_hotplug.h:30:14: error: 'NR_MEM_SECTIONS' undeclared (first use in this function); did you mean 'END_FTR_SECTION'?
if (___nr < NR_MEM_SECTIONS && online_section_nr(___nr) && \
^
mm/page_isolation.c:221:23: note: in expansion of macro 'pfn_to_online_page'
struct page *page = pfn_to_online_page(pfn);
^~~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
--
In file included from include/linux/mmzone.h:811:0,
from include/linux/gfp.h:6,
from include/linux/mm.h:10,
from include/linux/memblock.h:13,
from fs/proc/page.c:2:
fs/proc/page.c: In function 'kpagecount_read':
>> include/linux/memory_hotplug.h:28:24: error: implicit declaration of function 'pfn_to_section_nr'; did you mean '__section'? [-Werror=implicit-function-declaration]
unsigned long ___nr = pfn_to_section_nr(___pfn); \
^
fs/proc/page.c:49:11: note: in expansion of macro 'pfn_to_online_page'
ppage = pfn_to_online_page(pfn);
^~~~~~~~~~~~~~~~~~
>> include/linux/memory_hotplug.h:30:14: error: 'NR_MEM_SECTIONS' undeclared (first use in this function); did you mean 'END_FTR_SECTION'?
if (___nr < NR_MEM_SECTIONS && online_section_nr(___nr) && \
^
fs/proc/page.c:49:11: note: in expansion of macro 'pfn_to_online_page'
ppage = pfn_to_online_page(pfn);
^~~~~~~~~~~~~~~~~~
include/linux/memory_hotplug.h:30:14: note: each undeclared identifier is reported only once for each function it appears in
if (___nr < NR_MEM_SECTIONS && online_section_nr(___nr) && \
^
fs/proc/page.c:49:11: note: in expansion of macro 'pfn_to_online_page'
ppage = pfn_to_online_page(pfn);
^~~~~~~~~~~~~~~~~~
>> include/linux/memory_hotplug.h:30:33: error: implicit declaration of function 'online_section_nr' [-Werror=implicit-function-declaration]
if (___nr < NR_MEM_SECTIONS && online_section_nr(___nr) && \
^
fs/proc/page.c:49:11: note: in expansion of macro 'pfn_to_online_page'
ppage = pfn_to_online_page(pfn);
^~~~~~~~~~~~~~~~~~
fs/proc/page.c: In function 'kpageflags_read':
>> include/linux/memory_hotplug.h:30:14: error: 'NR_MEM_SECTIONS' undeclared (first use in this function); did you mean 'END_FTR_SECTION'?
if (___nr < NR_MEM_SECTIONS && online_section_nr(___nr) && \
^
fs/proc/page.c:225:11: note: in expansion of macro 'pfn_to_online_page'
ppage = pfn_to_online_page(pfn);
^~~~~~~~~~~~~~~~~~
fs/proc/page.c: In function 'kpagecgroup_read':
>> include/linux/memory_hotplug.h:30:14: error: 'NR_MEM_SECTIONS' undeclared (first use in this function); did you mean 'END_FTR_SECTION'?
if (___nr < NR_MEM_SECTIONS && online_section_nr(___nr) && \
^
fs/proc/page.c:271:11: note: in expansion of macro 'pfn_to_online_page'
ppage = pfn_to_online_page(pfn);
^~~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors

vim +1653 kernel/resource.c

90e97820619dc9 Jiang Liu 2015-02-05 1645
0092908d16c604 Christoph Hellwig 2019-06-26 1646 #ifdef CONFIG_DEVICE_PRIVATE
0c385190392d8c Christoph Hellwig 2019-08-18 1647 static struct resource *__request_free_mem_region(struct device *dev,
0c385190392d8c Christoph Hellwig 2019-08-18 1648 struct resource *base, unsigned long size, const char *name)
0092908d16c604 Christoph Hellwig 2019-06-26 1649 {
0092908d16c604 Christoph Hellwig 2019-06-26 1650 resource_size_t end, addr;
0092908d16c604 Christoph Hellwig 2019-06-26 1651 struct resource *res;
0092908d16c604 Christoph Hellwig 2019-06-26 1652
0092908d16c604 Christoph Hellwig 2019-06-26 @1653 size = ALIGN(size, 1UL << PA_SECTION_SHIFT);
0092908d16c604 Christoph Hellwig 2019-06-26 1654 end = min_t(unsigned long, base->end, (1UL << MAX_PHYSMEM_BITS) - 1);
0092908d16c604 Christoph Hellwig 2019-06-26 1655 addr = end - size + 1UL;
0092908d16c604 Christoph Hellwig 2019-06-26 1656
0092908d16c604 Christoph Hellwig 2019-06-26 1657 for (; addr > size && addr >= base->start; addr -= size) {
0092908d16c604 Christoph Hellwig 2019-06-26 1658 if (region_intersects(addr, size, 0, IORES_DESC_NONE) !=
0092908d16c604 Christoph Hellwig 2019-06-26 1659 REGION_DISJOINT)
0092908d16c604 Christoph Hellwig 2019-06-26 1660 continue;
0092908d16c604 Christoph Hellwig 2019-06-26 1661
0c385190392d8c Christoph Hellwig 2019-08-18 1662 if (dev)
0c385190392d8c Christoph Hellwig 2019-08-18 1663 res = devm_request_mem_region(dev, addr, size, name);
0c385190392d8c Christoph Hellwig 2019-08-18 1664 else
0c385190392d8c Christoph Hellwig 2019-08-18 1665 res = request_mem_region(addr, size, name);
0092908d16c604 Christoph Hellwig 2019-06-26 1666 if (!res)
0092908d16c604 Christoph Hellwig 2019-06-26 1667 return ERR_PTR(-ENOMEM);
0092908d16c604 Christoph Hellwig 2019-06-26 1668 res->desc = IORES_DESC_DEVICE_PRIVATE_MEMORY;
0092908d16c604 Christoph Hellwig 2019-06-26 1669 return res;
0092908d16c604 Christoph Hellwig 2019-06-26 1670 }
0092908d16c604 Christoph Hellwig 2019-06-26 1671
0092908d16c604 Christoph Hellwig 2019-06-26 1672 return ERR_PTR(-ERANGE);
0092908d16c604 Christoph Hellwig 2019-06-26 1673 }
0c385190392d8c Christoph Hellwig 2019-08-18 1674

:::::: The code at line 1653 was first introduced by commit
:::::: 0092908d16c604b8207c2141ec64b0fa4473bb03 mm: factor out a devm_request_free_mem_region helper

:::::: TO: Christoph Hellwig <hch@xxxxxx>
:::::: CC: Jason Gunthorpe <jgg@xxxxxxxxxxxx>

---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx Intel Corporation

Attachment: .config.gz
Description: application/gzip