hc
2024-05-10 748e4f3d702def1a4bff191e0cf93b6a05340f01
kernel/arch/sparc/kernel/sun4d_irq.c
....@@ -335,12 +335,12 @@
335335
336336 irq = real_irq;
337337 while (bus) {
338
- if (!strcmp(bus->name, "sbi")) {
338
+ if (of_node_name_eq(bus, "sbi")) {
339339 bus_connection = "io-unit";
340340 break;
341341 }
342342
343
- if (!strcmp(bus->name, "bootbus")) {
343
+ if (of_node_name_eq(bus, "bootbus")) {
344344 bus_connection = "cpu-unit";
345345 break;
346346 }
....@@ -360,16 +360,16 @@
360360 * If Bus nodes parent is not io-unit/cpu-unit or the io-unit/cpu-unit
361361 * lacks a "board#" property, something is very wrong.
362362 */
363
- if (!bus->parent || strcmp(bus->parent->name, bus_connection)) {
364
- printk(KERN_ERR "%s: Error, parent is not %s.\n",
365
- bus->full_name, bus_connection);
363
+ if (!of_node_name_eq(bus->parent, bus_connection)) {
364
+ printk(KERN_ERR "%pOF: Error, parent is not %s.\n",
365
+ bus, bus_connection);
366366 goto err_out;
367367 }
368368 board_parent = bus->parent;
369369 board = of_getintprop_default(board_parent, "board#", -1);
370370 if (board == -1) {
371
- printk(KERN_ERR "%s: Error, lacks board# property.\n",
372
- board_parent->full_name);
371
+ printk(KERN_ERR "%pOF: Error, lacks board# property.\n",
372
+ board_parent);
373373 goto err_out;
374374 }
375375