linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [mmotm:master 42/152] mm/page_alloc.c:1602:18: error: 'struct zone' has no member named 'node'; did you mean 'name'?
@ 2018-02-22 18:36 kbuild test robot
  2018-02-22 20:35 ` Andrew Morton
  0 siblings, 1 reply; 2+ messages in thread
From: kbuild test robot @ 2018-02-22 18:36 UTC (permalink / raw)
  To: Pavel Tatashin
  Cc: kbuild-all, Johannes Weiner, Daniel Jordan, Steven Sistare,
	Andrew Morton, Linux Memory Management List

[-- Attachment #1: Type: text/plain, Size: 4242 bytes --]

tree:   git://git.cmpxchg.org/linux-mmotm.git master
head:   745388a34645dd2b69f5e7115ad47fea7a218726
commit: cb9cc5caafb2b2ad1db9742432754913d36f9cec [42/152] mm: initialize pages on demand during boot
config: x86_64-randconfig-a0-02221139 (attached as .config)
compiler: gcc-7 (Debian 7.3.0-1) 7.3.0
reproduce:
        git checkout cb9cc5caafb2b2ad1db9742432754913d36f9cec
        # save the attached .config to linux build tree
        make ARCH=x86_64 

Note: the mmotm/master HEAD 745388a34645dd2b69f5e7115ad47fea7a218726 builds fine.
      It only hurts bisectibility.

All errors (new ones prefixed by >>):

   mm/page_alloc.c: In function 'deferred_grow_zone':
>> mm/page_alloc.c:1602:18: error: 'struct zone' has no member named 'node'; did you mean 'name'?
     int nid = zone->node;
                     ^~~~
                     name

vim +1602 mm/page_alloc.c

  1583	
  1584	/*
  1585	 * If this zone has deferred pages, try to grow it by initializing enough
  1586	 * deferred pages to satisfy the allocation specified by order, rounded up to
  1587	 * the nearest PAGES_PER_SECTION boundary.  So we're adding memory in increments
  1588	 * of SECTION_SIZE bytes by initializing struct pages in increments of
  1589	 * PAGES_PER_SECTION * sizeof(struct page) bytes.
  1590	 *
  1591	 * Return true when zone was grown by at least number of pages specified by
  1592	 * order. Otherwise return false.
  1593	 *
  1594	 * Note: We use noinline because this function is needed only during boot, and
  1595	 * it is called from a __ref function _deferred_grow_zone. This way we are
  1596	 * making sure that it is not inlined into permanent text section.
  1597	 */
  1598	static noinline bool __init
  1599	deferred_grow_zone(struct zone *zone, unsigned int order)
  1600	{
  1601		int zid = zone_idx(zone);
> 1602		int nid = zone->node;
  1603		pg_data_t *pgdat = NODE_DATA(nid);
  1604		unsigned long nr_pages_needed = ALIGN(1 << order, PAGES_PER_SECTION);
  1605		unsigned long nr_pages = 0;
  1606		unsigned long first_init_pfn, first_deferred_pfn, spfn, epfn, t, flags;
  1607		phys_addr_t spa, epa;
  1608		u64 i;
  1609	
  1610		/* Only the last zone may have deferred pages */
  1611		if (zone_end_pfn(zone) != pgdat_end_pfn(pgdat))
  1612			return false;
  1613	
  1614		spin_lock_irqsave(&deferred_zone_grow_lock, flags);
  1615		/*
  1616		 * Bail if we raced with another thread that disabled on demand
  1617		 * initialization.
  1618		 */
  1619		if (!static_branch_unlikely(&deferred_pages)) {
  1620			spin_unlock_irqrestore(&deferred_zone_grow_lock, flags);
  1621			return false;
  1622		}
  1623	
  1624		first_deferred_pfn = pgdat->first_deferred_pfn;
  1625		first_init_pfn = max(zone->zone_start_pfn, first_deferred_pfn);
  1626	
  1627		if (first_init_pfn >= pgdat_end_pfn(pgdat)) {
  1628			spin_unlock_irqrestore(&deferred_zone_grow_lock, flags);
  1629			return false;
  1630		}
  1631	
  1632		for_each_free_mem_range(i, nid, MEMBLOCK_NONE, &spa, &epa, NULL) {
  1633			spfn = max_t(unsigned long, first_init_pfn, PFN_UP(spa));
  1634			epfn = min_t(unsigned long, zone_end_pfn(zone), PFN_DOWN(epa));
  1635	
  1636			while (spfn < epfn && nr_pages < nr_pages_needed) {
  1637				t = ALIGN(spfn + PAGES_PER_SECTION, PAGES_PER_SECTION);
  1638				first_deferred_pfn = min(t, epfn);
  1639				nr_pages += deferred_init_pages(nid, zid, spfn,
  1640								first_deferred_pfn);
  1641				spfn = first_deferred_pfn;
  1642			}
  1643	
  1644			if (nr_pages >= nr_pages_needed)
  1645				break;
  1646		}
  1647	
  1648		for_each_free_mem_range(i, nid, MEMBLOCK_NONE, &spa, &epa, NULL) {
  1649			spfn = max_t(unsigned long, first_init_pfn, PFN_UP(spa));
  1650			epfn = min_t(unsigned long, first_deferred_pfn, PFN_DOWN(epa));
  1651			deferred_free_pages(nid, zid, spfn, epfn);
  1652	
  1653			if (first_deferred_pfn == epfn)
  1654				break;
  1655		}
  1656		pgdat->first_deferred_pfn = first_deferred_pfn;
  1657		spin_unlock_irqrestore(&deferred_zone_grow_lock, flags);
  1658	
  1659		return nr_pages >= nr_pages_needed;
  1660	}
  1661	

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

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 26951 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [mmotm:master 42/152] mm/page_alloc.c:1602:18: error: 'struct zone' has no member named 'node'; did you mean 'name'?
  2018-02-22 18:36 [mmotm:master 42/152] mm/page_alloc.c:1602:18: error: 'struct zone' has no member named 'node'; did you mean 'name'? kbuild test robot
@ 2018-02-22 20:35 ` Andrew Morton
  0 siblings, 0 replies; 2+ messages in thread
From: Andrew Morton @ 2018-02-22 20:35 UTC (permalink / raw)
  To: kbuild test robot
  Cc: Pavel Tatashin, kbuild-all, Johannes Weiner, Daniel Jordan,
	Steven Sistare, Linux Memory Management List

On Fri, 23 Feb 2018 02:36:12 +0800 kbuild test robot <fengguang.wu@intel.com> wrote:

> tree:   git://git.cmpxchg.org/linux-mmotm.git master
> head:   745388a34645dd2b69f5e7115ad47fea7a218726
> commit: cb9cc5caafb2b2ad1db9742432754913d36f9cec [42/152] mm: initialize pages on demand during boot
> config: x86_64-randconfig-a0-02221139 (attached as .config)
> compiler: gcc-7 (Debian 7.3.0-1) 7.3.0
> reproduce:
>         git checkout cb9cc5caafb2b2ad1db9742432754913d36f9cec
>         # save the attached .config to linux build tree
>         make ARCH=x86_64 
> 
> Note: the mmotm/master HEAD 745388a34645dd2b69f5e7115ad47fea7a218726 builds fine.
>       It only hurts bisectibility.
> 
> All errors (new ones prefixed by >>):
> 
>    mm/page_alloc.c: In function 'deferred_grow_zone':
> >> mm/page_alloc.c:1602:18: error: 'struct zone' has no member named 'node'; did you mean 'name'?
>      int nid = zone->node;
>                      ^~~~
>                      name

THis is fixed in the following patch,
mm-initialize-pages-on-demand-during-boot-fix-3.patch

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-02-22 20:35 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-02-22 18:36 [mmotm:master 42/152] mm/page_alloc.c:1602:18: error: 'struct zone' has no member named 'node'; did you mean 'name'? kbuild test robot
2018-02-22 20:35 ` Andrew Morton

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox