All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: oe-kbuild@lists.linux.dev
Cc: lkp@intel.com, Dan Carpenter <error27@gmail.com>
Subject: Re: [PATCH v3 17/35] mm: enable page allocation tagging
Date: Fri, 16 Feb 2024 06:54:45 +0800	[thread overview]
Message-ID: <202402160659.khaz4wMj-lkp@intel.com> (raw)

BCC: lkp@intel.com
CC: oe-kbuild-all@lists.linux.dev
In-Reply-To: <20240212213922.783301-18-surenb@google.com>
References: <20240212213922.783301-18-surenb@google.com>
TO: Suren Baghdasaryan <surenb@google.com>
TO: akpm@linux-foundation.org
CC: kent.overstreet@linux.dev
CC: mhocko@suse.com
CC: vbabka@suse.cz
CC: hannes@cmpxchg.org
CC: roman.gushchin@linux.dev
CC: mgorman@suse.de
CC: dave@stgolabs.net
CC: willy@infradead.org
CC: liam.howlett@oracle.com
CC: corbet@lwn.net
CC: void@manifault.com
CC: peterz@infradead.org
CC: juri.lelli@redhat.com
CC: catalin.marinas@arm.com
CC: will@kernel.org
CC: arnd@arndb.de
CC: tglx@linutronix.de
CC: mingo@redhat.com
CC: dave.hansen@linux.intel.com
CC: x86@kernel.org
CC: peterx@redhat.com
CC: david@redhat.com
CC: axboe@kernel.dk
CC: mcgrof@kernel.org
CC: masahiroy@kernel.org
CC: nathan@kernel.org
CC: dennis@kernel.org
CC: tj@kernel.org
CC: muchun.song@linux.dev

Hi Suren,

kernel test robot noticed the following build warnings:

[auto build test WARNING on akpm-mm/mm-nonmm-unstable]
[also build test WARNING on linus/master v6.8-rc4]
[cannot apply to akpm-mm/mm-everything vbabka-slab/for-next next-20240215]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]

url:    https://github.com/intel-lab-lkp/linux/commits/Suren-Baghdasaryan/lib-string_helpers-Add-flags-param-to-string_get_size/20240213-054335
base:   https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-nonmm-unstable
patch link:    https://lore.kernel.org/r/20240212213922.783301-18-surenb%40google.com
patch subject: [PATCH v3 17/35] mm: enable page allocation tagging
:::::: branch date: 3 days ago
:::::: commit date: 3 days ago
config: s390-randconfig-r071-20240213 (https://download.01.org/0day-ci/archive/20240216/202402160659.khaz4wMj-lkp@intel.com/config)
compiler: clang version 19.0.0git (https://github.com/llvm/llvm-project c08b90c50bcac9f3f563c79491c8dbcbe7c3b574)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Reported-by: Dan Carpenter <error27@gmail.com>
| Closes: https://lore.kernel.org/r/202402160659.khaz4wMj-lkp@intel.com/

smatch warnings:
mm/page_alloc.c:4502 alloc_pages_bulk_noprof() error: we previously assumed 'page_array' could be null (see line 4481)

vim +/page_array +4502 mm/page_alloc.c

187ad460b8413e Mel Gorman             2021-07-14  4433  
387ba26fb1cb9b Mel Gorman             2021-04-29  4434  	/* May set ALLOC_NOFRAGMENT, fragmentation will return 1 page. */
387ba26fb1cb9b Mel Gorman             2021-04-29  4435  	gfp &= gfp_allowed_mask;
387ba26fb1cb9b Mel Gorman             2021-04-29  4436  	alloc_gfp = gfp;
387ba26fb1cb9b Mel Gorman             2021-04-29  4437  	if (!prepare_alloc_pages(gfp, 0, preferred_nid, nodemask, &ac, &alloc_gfp, &alloc_flags))
061478438d0477 Chuck Lever            2021-07-14  4438  		goto out;
387ba26fb1cb9b Mel Gorman             2021-04-29  4439  	gfp = alloc_gfp;
387ba26fb1cb9b Mel Gorman             2021-04-29  4440  
387ba26fb1cb9b Mel Gorman             2021-04-29  4441  	/* Find an allowed local zone that meets the low watermark. */
387ba26fb1cb9b Mel Gorman             2021-04-29  4442  	for_each_zone_zonelist_nodemask(zone, z, ac.zonelist, ac.highest_zoneidx, ac.nodemask) {
387ba26fb1cb9b Mel Gorman             2021-04-29  4443  		unsigned long mark;
387ba26fb1cb9b Mel Gorman             2021-04-29  4444  
387ba26fb1cb9b Mel Gorman             2021-04-29  4445  		if (cpusets_enabled() && (alloc_flags & ALLOC_CPUSET) &&
387ba26fb1cb9b Mel Gorman             2021-04-29  4446  		    !__cpuset_zone_allowed(zone, gfp)) {
387ba26fb1cb9b Mel Gorman             2021-04-29  4447  			continue;
387ba26fb1cb9b Mel Gorman             2021-04-29  4448  		}
387ba26fb1cb9b Mel Gorman             2021-04-29  4449  
387ba26fb1cb9b Mel Gorman             2021-04-29  4450  		if (nr_online_nodes > 1 && zone != ac.preferred_zoneref->zone &&
387ba26fb1cb9b Mel Gorman             2021-04-29  4451  		    zone_to_nid(zone) != zone_to_nid(ac.preferred_zoneref->zone)) {
387ba26fb1cb9b Mel Gorman             2021-04-29  4452  			goto failed;
387ba26fb1cb9b Mel Gorman             2021-04-29  4453  		}
387ba26fb1cb9b Mel Gorman             2021-04-29  4454  
387ba26fb1cb9b Mel Gorman             2021-04-29  4455  		mark = wmark_pages(zone, alloc_flags & ALLOC_WMARK_MASK) + nr_pages;
387ba26fb1cb9b Mel Gorman             2021-04-29  4456  		if (zone_watermark_fast(zone, 0,  mark,
387ba26fb1cb9b Mel Gorman             2021-04-29  4457  				zonelist_zone_idx(ac.preferred_zoneref),
387ba26fb1cb9b Mel Gorman             2021-04-29  4458  				alloc_flags, gfp)) {
387ba26fb1cb9b Mel Gorman             2021-04-29  4459  			break;
387ba26fb1cb9b Mel Gorman             2021-04-29  4460  		}
387ba26fb1cb9b Mel Gorman             2021-04-29  4461  	}
387ba26fb1cb9b Mel Gorman             2021-04-29  4462  
387ba26fb1cb9b Mel Gorman             2021-04-29  4463  	/*
387ba26fb1cb9b Mel Gorman             2021-04-29  4464  	 * If there are no allowed local zones that meets the watermarks then
387ba26fb1cb9b Mel Gorman             2021-04-29  4465  	 * try to allocate a single page and reclaim if necessary.
387ba26fb1cb9b Mel Gorman             2021-04-29  4466  	 */
ce76f9a1d9a21c Jesper Dangaard Brouer 2021-04-29  4467  	if (unlikely(!zone))
387ba26fb1cb9b Mel Gorman             2021-04-29  4468  		goto failed;
387ba26fb1cb9b Mel Gorman             2021-04-29  4469  
5749077415994e Mel Gorman             2022-11-18  4470  	/* spin_trylock may fail due to a parallel drain or IRQ reentrancy. */
4b23a68f953628 Mel Gorman             2022-06-24  4471  	pcp_trylock_prepare(UP_flags);
5749077415994e Mel Gorman             2022-11-18  4472  	pcp = pcp_spin_trylock(zone->per_cpu_pageset);
01b44456a7aa7c Mel Gorman             2022-06-24  4473  	if (!pcp)
4b23a68f953628 Mel Gorman             2022-06-24  4474  		goto failed_irq;
387ba26fb1cb9b Mel Gorman             2021-04-29  4475  
387ba26fb1cb9b Mel Gorman             2021-04-29  4476  	/* Attempt the batch allocation */
44042b4498728f Mel Gorman             2021-06-28  4477  	pcp_list = &pcp->lists[order_to_pindex(ac.migratetype, 0)];
0f87d9d30f2139 Mel Gorman             2021-04-29  4478  	while (nr_populated < nr_pages) {
0f87d9d30f2139 Mel Gorman             2021-04-29  4479  
0f87d9d30f2139 Mel Gorman             2021-04-29  4480  		/* Skip existing pages */
0f87d9d30f2139 Mel Gorman             2021-04-29 @4481  		if (page_array && page_array[nr_populated]) {
0f87d9d30f2139 Mel Gorman             2021-04-29  4482  			nr_populated++;
0f87d9d30f2139 Mel Gorman             2021-04-29  4483  			continue;
0f87d9d30f2139 Mel Gorman             2021-04-29  4484  		}
0f87d9d30f2139 Mel Gorman             2021-04-29  4485  
44042b4498728f Mel Gorman             2021-06-28  4486  		page = __rmqueue_pcplist(zone, 0, ac.migratetype, alloc_flags,
387ba26fb1cb9b Mel Gorman             2021-04-29  4487  								pcp, pcp_list);
ce76f9a1d9a21c Jesper Dangaard Brouer 2021-04-29  4488  		if (unlikely(!page)) {
c572e4888ad1be Mel Gorman             2022-05-26  4489  			/* Try and allocate at least one page */
4b23a68f953628 Mel Gorman             2022-06-24  4490  			if (!nr_account) {
5749077415994e Mel Gorman             2022-11-18  4491  				pcp_spin_unlock(pcp);
387ba26fb1cb9b Mel Gorman             2021-04-29  4492  				goto failed_irq;
4b23a68f953628 Mel Gorman             2022-06-24  4493  			}
387ba26fb1cb9b Mel Gorman             2021-04-29  4494  			break;
387ba26fb1cb9b Mel Gorman             2021-04-29  4495  		}
3e23060b2d0b7e Mel Gorman             2021-06-28  4496  		nr_account++;
387ba26fb1cb9b Mel Gorman             2021-04-29  4497  
387ba26fb1cb9b Mel Gorman             2021-04-29  4498  		prep_new_page(page, 0, gfp, 0);
0f87d9d30f2139 Mel Gorman             2021-04-29  4499  		if (page_list)
387ba26fb1cb9b Mel Gorman             2021-04-29  4500  			list_add(&page->lru, page_list);
0f87d9d30f2139 Mel Gorman             2021-04-29  4501  		else
0f87d9d30f2139 Mel Gorman             2021-04-29 @4502  			page_array[nr_populated] = page;
0f87d9d30f2139 Mel Gorman             2021-04-29  4503  		nr_populated++;
387ba26fb1cb9b Mel Gorman             2021-04-29  4504  	}
387ba26fb1cb9b Mel Gorman             2021-04-29  4505  
5749077415994e Mel Gorman             2022-11-18  4506  	pcp_spin_unlock(pcp);
4b23a68f953628 Mel Gorman             2022-06-24  4507  	pcp_trylock_finish(UP_flags);
43c95bcc51e4e7 Mel Gorman             2021-06-28  4508  
3e23060b2d0b7e Mel Gorman             2021-06-28  4509  	__count_zid_vm_events(PGALLOC, zone_idx(zone), nr_account);
3e23060b2d0b7e Mel Gorman             2021-06-28  4510  	zone_statistics(ac.preferred_zoneref->zone, zone, nr_account);
387ba26fb1cb9b Mel Gorman             2021-04-29  4511  
061478438d0477 Chuck Lever            2021-07-14  4512  out:
0f87d9d30f2139 Mel Gorman             2021-04-29  4513  	return nr_populated;
387ba26fb1cb9b Mel Gorman             2021-04-29  4514  
387ba26fb1cb9b Mel Gorman             2021-04-29  4515  failed_irq:
4b23a68f953628 Mel Gorman             2022-06-24  4516  	pcp_trylock_finish(UP_flags);
387ba26fb1cb9b Mel Gorman             2021-04-29  4517  
387ba26fb1cb9b Mel Gorman             2021-04-29  4518  failed:
32217ecdde79fa Suren Baghdasaryan     2024-02-12  4519  	page = __alloc_pages_noprof(gfp, 0, preferred_nid, nodemask);
387ba26fb1cb9b Mel Gorman             2021-04-29  4520  	if (page) {
0f87d9d30f2139 Mel Gorman             2021-04-29  4521  		if (page_list)
387ba26fb1cb9b Mel Gorman             2021-04-29  4522  			list_add(&page->lru, page_list);
0f87d9d30f2139 Mel Gorman             2021-04-29  4523  		else
0f87d9d30f2139 Mel Gorman             2021-04-29  4524  			page_array[nr_populated] = page;
0f87d9d30f2139 Mel Gorman             2021-04-29  4525  		nr_populated++;
387ba26fb1cb9b Mel Gorman             2021-04-29  4526  	}
387ba26fb1cb9b Mel Gorman             2021-04-29  4527  
061478438d0477 Chuck Lever            2021-07-14  4528  	goto out;
387ba26fb1cb9b Mel Gorman             2021-04-29  4529  }
32217ecdde79fa Suren Baghdasaryan     2024-02-12  4530  EXPORT_SYMBOL_GPL(alloc_pages_bulk_noprof);
387ba26fb1cb9b Mel Gorman             2021-04-29  4531  

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

             reply	other threads:[~2024-02-15 22:55 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-15 22:54 kernel test robot [this message]
  -- strict thread matches above, loose matches on Subject: below --
2024-02-14  3:17 [PATCH v3 17/35] mm: enable page allocation tagging kernel test robot
2024-02-12 21:38 [PATCH v3 00/35] Memory allocation profiling Suren Baghdasaryan
2024-02-12 21:39 ` [PATCH v3 17/35] mm: enable page allocation tagging Suren Baghdasaryan
2024-02-12 22:59   ` Kees Cook

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=202402160659.khaz4wMj-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=error27@gmail.com \
    --cc=oe-kbuild@lists.linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.