summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorGeert Uytterhoeven <geert+renesas@glider.be>2019-10-16 16:30:03 +0200
committerDaniel Lezcano <daniel.lezcano@linaro.org>2019-10-18 07:55:16 +0200
commit7693de9f7aa4e2993fbd7094863304be6a4bbe16 (patch)
tree8288e157dab1323a6a4b3a433f0c247478a46777 /include
parent41d49e7939de5ec532d86494185b2ca2e99c848a (diff)
clocksource/drivers/sh_mtu2: Do not loop using platform_get_irq_by_name()
As platform_get_irq_by_name() now prints an error when the interrupt does not exist, looping over possibly non-existing interrupts causes the printing of scary messages like: sh_mtu2 fcff0000.timer: IRQ tgi1a not found sh_mtu2 fcff0000.timer: IRQ tgi2a not found Fix this by using the platform_irq_count() helper, to avoid touching non-existent interrupts. Limit the returned number of interrupts to the maximum number of channels currently supported by the driver in a future-proof way, i.e. using ARRAY_SIZE() instead of a hardcoded number. Fixes: 7723f4c5ecdb8d83 ("driver core: platform: Add an error message to platform_get_irq*()") Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org> Link: https://lore.kernel.org/r/20191016143003.28561-1-geert+renesas@glider.be
Diffstat (limited to 'include')
0 files changed, 0 insertions, 0 deletions