CC: [email protected]
CC: [email protected]
TO: "Cédric Le Goater" <[email protected]>
CC: Michael Ellerman <[email protected]>

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 
master
head:   cb323ee75d24e7acc2f188d123ba6df46159cf09
commit: 7dcc37b3eff97379b194adb17eb9a8270512dd1d powerpc/xive: Map one IPI 
interrupt per node
date:   10 months ago
:::::: branch date: 8 hours ago
:::::: commit date: 10 months ago
compiler: powerpc64le-linux-gcc (GCC) 11.2.0

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <[email protected]>


cppcheck possible warnings: (new ones prefixed by >>, may not real problems)

>> drivers/block/floppy.c:2525:4: warning: Assignment of function parameter has 
>> no effect outside the function. [uselessAssignmentArg]
      max_sector -= remaining >> 9;
      ^
>> drivers/block/floppy.c:4014:4: warning: %d in format string (no. 1) requires 
>> 'int' but the argument type is 'unsigned int'. [invalidPrintfArgType_sint]
      snprintf(temparea, sizeof(temparea),
      ^
   drivers/block/floppy.c:4607:3: warning: %d in format string (no. 1) requires 
'int' but the argument type is 'unsigned int'. [invalidPrintfArgType_sint]
     sprintf(disk->disk_name, "fd%d_type%d", drive, type);
     ^
   drivers/block/floppy.c:4607:3: warning: %d in format string (no. 2) requires 
'int' but the argument type is 'unsigned int'. [invalidPrintfArgType_sint]
     sprintf(disk->disk_name, "fd%d_type%d", drive, type);
     ^
   drivers/block/floppy.c:4609:3: warning: %d in format string (no. 1) requires 
'int' but the argument type is 'unsigned int'. [invalidPrintfArgType_sint]
     sprintf(disk->disk_name, "fd%d", drive);
     ^

vim +1155 arch/powerpc/sysdev/xive/common.c

7d348494136c8b4 Cédric Le Goater       2021-03-31  1115  
7d348494136c8b4 Cédric Le Goater       2021-03-31  1116  static int __init 
xive_request_ipi(void)
7d348494136c8b4 Cédric Le Goater       2021-03-31  1117  {
7d348494136c8b4 Cédric Le Goater       2021-03-31  1118         struct 
fwnode_handle *fwnode;
7d348494136c8b4 Cédric Le Goater       2021-03-31  1119         struct 
irq_domain *ipi_domain;
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1120         unsigned int 
node;
7d348494136c8b4 Cédric Le Goater       2021-03-31  1121         int ret = 
-ENOMEM;
243e25112d06b34 Benjamin Herrenschmidt 2017-04-05  1122  
7d348494136c8b4 Cédric Le Goater       2021-03-31  1123         fwnode = 
irq_domain_alloc_named_fwnode("XIVE-IPI");
7d348494136c8b4 Cédric Le Goater       2021-03-31  1124         if (!fwnode)
7d348494136c8b4 Cédric Le Goater       2021-03-31  1125                 goto 
out;
7d348494136c8b4 Cédric Le Goater       2021-03-31  1126  
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1127         ipi_domain = 
irq_domain_create_linear(fwnode, nr_node_ids,
7d348494136c8b4 Cédric Le Goater       2021-03-31  1128                         
                      &xive_ipi_irq_domain_ops, NULL);
7d348494136c8b4 Cédric Le Goater       2021-03-31  1129         if (!ipi_domain)
7d348494136c8b4 Cédric Le Goater       2021-03-31  1130                 goto 
out_free_fwnode;
243e25112d06b34 Benjamin Herrenschmidt 2017-04-05  1131  
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1132         xive_ipis = 
kcalloc(nr_node_ids, sizeof(*xive_ipis), GFP_KERNEL | __GFP_NOFAIL);
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1133         if (!xive_ipis)
7d348494136c8b4 Cédric Le Goater       2021-03-31  1134                 goto 
out_free_domain;
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1135  
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1136         
for_each_node(node) {
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1137                 struct 
xive_ipi_desc *xid = &xive_ipis[node];
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1138                 
irq_hw_number_t ipi_hwirq = node;
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1139  
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1140                 /* Skip 
nodes without CPUs */
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1141                 if 
(cpumask_empty(cpumask_of_node(node)))
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1142                         
continue;
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1143  
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1144                 /*
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1145                  * Map 
one IPI interrupt per node for all cpus of that node.
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1146                  * 
Since the HW interrupt number doesn't have any meaning,
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1147                  * 
simply use the node number.
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1148                  */
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1149                 
xid->irq = irq_create_mapping(ipi_domain, ipi_hwirq);
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1150                 if 
(!xid->irq) {
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1151                         
ret = -EINVAL;
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1152                         
goto out_free_xive_ipis;
7d348494136c8b4 Cédric Le Goater       2021-03-31  1153                 }
7d348494136c8b4 Cédric Le Goater       2021-03-31  1154  
7dcc37b3eff9737 Cédric Le Goater       2021-03-31 @1155                 
snprintf(xid->name, sizeof(xid->name), "IPI-%d", node);
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1156  
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1157                 ret = 
request_irq(xid->irq, xive_muxed_ipi_action,
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1158                         
          IRQF_PERCPU | IRQF_NO_THREAD, xid->name, NULL);
243e25112d06b34 Benjamin Herrenschmidt 2017-04-05  1159  
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1160                 
WARN(ret < 0, "Failed to request IPI %d: %d\n", xid->irq, ret);
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1161         }
7d348494136c8b4 Cédric Le Goater       2021-03-31  1162  
7d348494136c8b4 Cédric Le Goater       2021-03-31  1163         return ret;
7d348494136c8b4 Cédric Le Goater       2021-03-31  1164  
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1165  out_free_xive_ipis:
7dcc37b3eff9737 Cédric Le Goater       2021-03-31  1166         
kfree(xive_ipis);
7d348494136c8b4 Cédric Le Goater       2021-03-31  1167  out_free_domain:
7d348494136c8b4 Cédric Le Goater       2021-03-31  1168         
irq_domain_remove(ipi_domain);
7d348494136c8b4 Cédric Le Goater       2021-03-31  1169  out_free_fwnode:
7d348494136c8b4 Cédric Le Goater       2021-03-31  1170         
irq_domain_free_fwnode(fwnode);
7d348494136c8b4 Cédric Le Goater       2021-03-31  1171  out:
7d348494136c8b4 Cédric Le Goater       2021-03-31  1172         return ret;
243e25112d06b34 Benjamin Herrenschmidt 2017-04-05  1173  }
243e25112d06b34 Benjamin Herrenschmidt 2017-04-05  1174  

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/[email protected]
_______________________________________________
kbuild mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to