Hi Daniel,

kernel test robot noticed the following build errors:

[auto build test ERROR on 32f85e8468ce081d8e73ca3f0d588f1004013037]

url:    
https://github.com/intel-lab-lkp/linux/commits/Daniel-Wagner/lib-group_cpus-Add-group_masks_cpus_evenly/20250703-003811
base:   32f85e8468ce081d8e73ca3f0d588f1004013037
patch link:    
https://lore.kernel.org/r/20250702-isolcpus-io-queues-v7-8-557aa7eacce4%40kernel.org
patch subject: [PATCH v7 08/10] blk-mq: use hk cpus only when isolcpus=io_queue 
is enabled
config: arm-allnoconfig 
(https://download.01.org/0day-ci/archive/20250703/202507032238.aotmqngp-...@intel.com/config)
compiler: clang version 21.0.0git (https://github.com/llvm/llvm-project 
f1a4bb62452d88a0edd9340b3ca7c9b11ad9193f)
reproduce (this is a W=1 build): 
(https://download.01.org/0day-ci/archive/20250703/202507032238.aotmqngp-...@intel.com/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 <l...@intel.com>
| Closes: 
https://lore.kernel.org/oe-kbuild-all/202507032238.aotmqngp-...@intel.com/

All errors (new ones prefixed by >>):

>> block/blk-mq-cpumap.c:155:16: error: array initializer must be an 
>> initializer list
     155 |         cpumask_var_t active_hctx __free(free_cpumask_var) = NULL;
         |                       ^
   block/blk-mq-cpumap.c:219:16: error: array initializer must be an 
initializer list
     219 |         cpumask_var_t active_hctx __free(free_cpumask_var) = NULL;
         |                       ^
   block/blk-mq-cpumap.c:220:16: error: array initializer must be an 
initializer list
     220 |         cpumask_var_t mask __free(free_cpumask_var) = NULL;
         |                       ^
   3 errors generated.


vim +155 block/blk-mq-cpumap.c

   144  
   145  /*
   146   * blk_mq_map_hk_queues - Create housekeeping CPU to
   147   *                        hardware queue mapping
   148   * @qmap:       CPU to hardware queue map
   149   *
   150   * Create a housekeeping CPU to hardware queue mapping in @qmap. @qmap
   151   * contains a valid configuration honoring the isolcpus configuration.
   152   */
   153  static void blk_mq_map_hk_queues(struct blk_mq_queue_map *qmap)
   154  {
 > 155          cpumask_var_t active_hctx __free(free_cpumask_var) = NULL;
   156          struct cpumask *hk_masks __free(kfree) = NULL;
   157          const struct cpumask *mask;
   158          unsigned int queue, cpu, nr_masks;
   159  
   160          if (housekeeping_enabled(HK_TYPE_IO_QUEUE))
   161                  mask = housekeeping_cpumask(HK_TYPE_IO_QUEUE);
   162          else
   163                  goto fallback;
   164  
   165          if (!zalloc_cpumask_var(&active_hctx, GFP_KERNEL))
   166                  goto fallback;
   167  
   168          /* Map housekeeping CPUs to a hctx */
   169          hk_masks = group_mask_cpus_evenly(qmap->nr_queues, mask, 
&nr_masks);
   170          if (!hk_masks)
   171                  goto fallback;
   172  
   173          for (queue = 0; queue < qmap->nr_queues; queue++) {
   174                  unsigned int idx = (qmap->queue_offset + queue) % 
nr_masks;
   175  
   176                  for_each_cpu(cpu, &hk_masks[idx]) {
   177                          qmap->mq_map[cpu] = idx;
   178  
   179                          if (cpu_online(cpu))
   180                                  cpumask_set_cpu(qmap->mq_map[cpu], 
active_hctx);
   181                  }
   182          }
   183  
   184          /* Map isolcpus to hardware context */
   185          queue = cpumask_first(active_hctx);
   186          for_each_cpu_andnot(cpu, cpu_possible_mask, mask) {
   187                  qmap->mq_map[cpu] = (qmap->queue_offset + queue) % 
nr_masks;
   188                  queue = cpumask_next_wrap(queue, active_hctx);
   189          }
   190  
   191          if (!blk_mq_hk_validate(qmap, active_hctx))
   192                  goto fallback;
   193  
   194          return;
   195  
   196  fallback:
   197          /*
   198           * Map all CPUs to the first hctx to ensure at least one online
   199           * housekeeping CPU is serving it.
   200           */
   201          for_each_possible_cpu(cpu)
   202                  qmap->mq_map[cpu] = 0;
   203  }
   204  

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

Reply via email to