.. | .. |
---|
425 | 425 | struct irq_desc *desc; |
---|
426 | 426 | |
---|
427 | 427 | if (i > nr_irqs) |
---|
428 | | - return 0; |
---|
| 428 | + return -EINVAL; |
---|
429 | 429 | |
---|
430 | 430 | /* print header and calculate the width of the first column */ |
---|
431 | 431 | if (i == 0) { |
---|
.. | .. |
---|
433 | 433 | j *= 10; |
---|
434 | 434 | |
---|
435 | 435 | buf += sprintf(buf, "%*s", prec + 8, ""); |
---|
436 | | - for_each_online_cpu(j) |
---|
| 436 | + for_each_possible_cpu(j) |
---|
437 | 437 | buf += sprintf(buf, "CPU%-8d", j); |
---|
438 | 438 | buf += sprintf(buf, "\n"); |
---|
439 | 439 | } |
---|
440 | 440 | |
---|
441 | 441 | desc = irq_to_desc(i); |
---|
442 | 442 | if (!desc) |
---|
443 | | - goto outsparse; |
---|
| 443 | + return -EINVAL; |
---|
444 | 444 | |
---|
445 | 445 | if (desc->kstat_irqs) |
---|
446 | | - for_each_online_cpu(j) |
---|
| 446 | + for_each_possible_cpu(j) |
---|
447 | 447 | any_count |= *per_cpu_ptr(desc->kstat_irqs, j); |
---|
448 | 448 | |
---|
449 | 449 | if ((!desc->action || (desc->action && desc->action == &chained_action)) && !any_count) |
---|
450 | | - goto outsparse; |
---|
| 450 | + return -EINVAL; |
---|
451 | 451 | |
---|
452 | 452 | buf += sprintf(buf, "%*d: ", prec, i); |
---|
453 | | - for_each_online_cpu(j) |
---|
| 453 | + for_each_possible_cpu(j) |
---|
454 | 454 | buf += sprintf(buf, "%10u ", desc->kstat_irqs ? |
---|
455 | 455 | *per_cpu_ptr(desc->kstat_irqs, j) : 0); |
---|
456 | 456 | |
---|
.. | .. |
---|
480 | 480 | } |
---|
481 | 481 | |
---|
482 | 482 | sprintf(buf, "\n"); |
---|
483 | | -outsparse: |
---|
484 | 483 | return 0; |
---|
485 | 484 | } |
---|
486 | 485 | |
---|