On 08/03/2017 07:15 PM, Bjorn Helgaas wrote:
of_irq_get() may return a negative error number as well as 0 on failure,
while the driver only checks for 0, blithely continuing with the call to
irq_set_chained_handler_and_data() -- that function expects *unsigned int*
so should probably do nothing when a large IRQ number resulting from a
conversion of a negative error number is passed to it. The driver then
probes successfully while being only partly functional...
Check for 'irq <= 0' instead and propagate the negative error number to
the probe method -- that will allow the deferred probing as well...
Fixes: d3c68e0a7e34 ("PCI: faraday: Add Faraday Technology FTPCI100 PCI Host Bridge driver")
Signed-off-by: Sergei Shtylyov <sergei.shtylyov@xxxxxxxxxxxxxxxxxx>
Applied with Linus' reviewed-by to pci/host-faraday for v4.14, thanks!
Thanks! But why only to 4.14?
Standard practice. We're currently in the v4.13 cycle, and the merge
window is closed, so the only changes we add for v4.13 are (1) fixes
for something we merged during the v4.13 merge window, or (2) critical
fixes that can't wait for v4.14.
OK, I thought the original Linus' commit was a bit more recent, like 4.13...
If we want something backported to stable kernels, we can add a tag
for that. That might apply in this case? Your patch is a fix for
d3c68e0a7e34 ("PCI: faraday: Add Faraday Technology FTPCI100 PCI Host
Bridge driver"), which appeared in v4.12,
If not in 4.11...
so we might want to tag it for any v4.12 or v4.13 stable kernels.
I think the -stable people look at the Fixes: tag now...
Bjorn
MBR, Sergei