Zero and negative number is not a valid IRQ for in-kernel code and the irq_of_parse_and_map() function returns zero on error. So this check for valid IRQs should only accept values > 0.
Cc: stable@vger.kernel.org Fixes: 44dab88e7cc9 ("spi: add spi_ppc4xx driver") Signed-off-by: Ma Ke make24@iscas.ac.cn
Changes in v2:
- added Cc stable line;
- added Fixes line.
The Cc stable seems clearly disproportionate here.
I wonder a bit about such a feedback (according to a commit from 2009-09-23).
Greg Kroah-Hartman configured a patch email bot in other ways.
Another example: Re: [PATCH] usb: typec: ucsi: Fix NULL pointer dereference in ucsi_displayport_vdm() https://lore.kernel.org/linux-usb/2024072333-popcorn-detached-f399@gregkh/
Regards, Markus