Re: [PATCH v3 4/5] mm: rename zone->lock to zone->_lock
From: kernel test robot
Date: Thu Feb 26 2026 - 18:16:27 EST
Hi Dmitry,
kernel test robot noticed the following build errors:
[auto build test ERROR on linus/master]
[also build test ERROR on v7.0-rc1 next-20260226]
[cannot apply to akpm-mm/mm-everything rppt-memblock/for-next rppt-memblock/fixes]
[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/Dmitry-Ilvokhin/mm-introduce-zone-lock-wrappers/20260227-022914
base: linus/master
patch link: https://lore.kernel.org/r/1221b8e7fa9f5694f3c4e411f01581b5aba9bc63.1772129168.git.d%40ilvokhin.com
patch subject: [PATCH v3 4/5] mm: rename zone->lock to zone->_lock
config: x86_64-defconfig (https://download.01.org/0day-ci/archive/20260227/202602270740.0RL1uwsV-lkp@xxxxxxxxx/config)
compiler: gcc-14 (Debian 14.2.0-19) 14.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260227/202602270740.0RL1uwsV-lkp@xxxxxxxxx/reproduce)
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@xxxxxxxxx>
| Closes: https://lore.kernel.org/oe-kbuild-all/202602270740.0RL1uwsV-lkp@xxxxxxxxx/
All errors (new ones prefixed by >>):
In file included from include/linux/sched.h:37,
from include/linux/percpu.h:12,
from arch/x86/include/asm/msr.h:16,
from arch/x86/include/asm/tsc.h:11,
from arch/x86/include/asm/timex.h:6,
from include/linux/timex.h:67,
from include/linux/time32.h:13,
from include/linux/time.h:60,
from include/linux/stat.h:19,
from include/linux/module.h:13,
from kernel/power/snapshot.c:14:
kernel/power/snapshot.c: In function 'mark_free_pages':
>> kernel/power/snapshot.c:1254:34: error: 'struct zone' has no member named 'lock'; did you mean '_lock'?
1254 | spin_lock_irqsave(&zone->lock, flags);
| ^~~~
include/linux/spinlock.h:244:48: note: in definition of macro 'raw_spin_lock_irqsave'
244 | flags = _raw_spin_lock_irqsave(lock); \
| ^~~~
kernel/power/snapshot.c:1254:9: note: in expansion of macro 'spin_lock_irqsave'
1254 | spin_lock_irqsave(&zone->lock, flags);
| ^~~~~~~~~~~~~~~~~
kernel/power/snapshot.c:1287:39: error: 'struct zone' has no member named 'lock'; did you mean '_lock'?
1287 | spin_unlock_irqrestore(&zone->lock, flags);
| ^~~~
| _lock
vim +1254 kernel/power/snapshot.c
31a1b9d7fe768d Kefeng Wang 2023-05-16 1243
31a1b9d7fe768d Kefeng Wang 2023-05-16 1244 static void mark_free_pages(struct zone *zone)
31a1b9d7fe768d Kefeng Wang 2023-05-16 1245 {
31a1b9d7fe768d Kefeng Wang 2023-05-16 1246 unsigned long pfn, max_zone_pfn, page_count = WD_PAGE_COUNT;
31a1b9d7fe768d Kefeng Wang 2023-05-16 1247 unsigned long flags;
31a1b9d7fe768d Kefeng Wang 2023-05-16 1248 unsigned int order, t;
31a1b9d7fe768d Kefeng Wang 2023-05-16 1249 struct page *page;
31a1b9d7fe768d Kefeng Wang 2023-05-16 1250
31a1b9d7fe768d Kefeng Wang 2023-05-16 1251 if (zone_is_empty(zone))
31a1b9d7fe768d Kefeng Wang 2023-05-16 1252 return;
31a1b9d7fe768d Kefeng Wang 2023-05-16 1253
31a1b9d7fe768d Kefeng Wang 2023-05-16 @1254 spin_lock_irqsave(&zone->lock, flags);
31a1b9d7fe768d Kefeng Wang 2023-05-16 1255
31a1b9d7fe768d Kefeng Wang 2023-05-16 1256 max_zone_pfn = zone_end_pfn(zone);
312eca8a14c5f5 David Woodhouse 2025-04-23 1257 for_each_valid_pfn(pfn, zone->zone_start_pfn, max_zone_pfn) {
31a1b9d7fe768d Kefeng Wang 2023-05-16 1258 page = pfn_to_page(pfn);
31a1b9d7fe768d Kefeng Wang 2023-05-16 1259
31a1b9d7fe768d Kefeng Wang 2023-05-16 1260 if (!--page_count) {
31a1b9d7fe768d Kefeng Wang 2023-05-16 1261 touch_nmi_watchdog();
31a1b9d7fe768d Kefeng Wang 2023-05-16 1262 page_count = WD_PAGE_COUNT;
31a1b9d7fe768d Kefeng Wang 2023-05-16 1263 }
31a1b9d7fe768d Kefeng Wang 2023-05-16 1264
31a1b9d7fe768d Kefeng Wang 2023-05-16 1265 if (page_zone(page) != zone)
31a1b9d7fe768d Kefeng Wang 2023-05-16 1266 continue;
31a1b9d7fe768d Kefeng Wang 2023-05-16 1267
31a1b9d7fe768d Kefeng Wang 2023-05-16 1268 if (!swsusp_page_is_forbidden(page))
31a1b9d7fe768d Kefeng Wang 2023-05-16 1269 swsusp_unset_page_free(page);
31a1b9d7fe768d Kefeng Wang 2023-05-16 1270 }
31a1b9d7fe768d Kefeng Wang 2023-05-16 1271
31a1b9d7fe768d Kefeng Wang 2023-05-16 1272 for_each_migratetype_order(order, t) {
31a1b9d7fe768d Kefeng Wang 2023-05-16 1273 list_for_each_entry(page,
31a1b9d7fe768d Kefeng Wang 2023-05-16 1274 &zone->free_area[order].free_list[t], buddy_list) {
31a1b9d7fe768d Kefeng Wang 2023-05-16 1275 unsigned long i;
31a1b9d7fe768d Kefeng Wang 2023-05-16 1276
31a1b9d7fe768d Kefeng Wang 2023-05-16 1277 pfn = page_to_pfn(page);
31a1b9d7fe768d Kefeng Wang 2023-05-16 1278 for (i = 0; i < (1UL << order); i++) {
31a1b9d7fe768d Kefeng Wang 2023-05-16 1279 if (!--page_count) {
31a1b9d7fe768d Kefeng Wang 2023-05-16 1280 touch_nmi_watchdog();
31a1b9d7fe768d Kefeng Wang 2023-05-16 1281 page_count = WD_PAGE_COUNT;
31a1b9d7fe768d Kefeng Wang 2023-05-16 1282 }
31a1b9d7fe768d Kefeng Wang 2023-05-16 1283 swsusp_set_page_free(pfn_to_page(pfn + i));
31a1b9d7fe768d Kefeng Wang 2023-05-16 1284 }
31a1b9d7fe768d Kefeng Wang 2023-05-16 1285 }
31a1b9d7fe768d Kefeng Wang 2023-05-16 1286 }
31a1b9d7fe768d Kefeng Wang 2023-05-16 1287 spin_unlock_irqrestore(&zone->lock, flags);
31a1b9d7fe768d Kefeng Wang 2023-05-16 1288 }
31a1b9d7fe768d Kefeng Wang 2023-05-16 1289
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki