drivers: pci: fix irq handling in pci-msm-msi.c
Here is the original reference :
From: Andrew Chant [email protected] Date: Wed, 20 Feb 2019 15:47:00 -0800 Subject: [PATCH] drivers: pci: fix irq handling in pci-msm-msi.c
Originally got this warning: drivers/pci/host/pci-msm-msi.c:507:41: error: incompatible function pointer types passing 'void (*)(struct irq_desc )' to parameter of type 'irq_flow_handler_t' (aka '_Bool ()(struct irq_desc *)') [-Werror,-Wincompatible-function-pointer-types] irq_set_chained_handler_and_data(irq, msi_handler, msi); ^~~~~~~~~~~
Warning is legit, irq_flow_handler_t has type bool. you can see from a common irq_flow_handler_t, handle_level_irq in kernel/irq/chip.c, that the return value should be true if it handled the irq, and false if otherwise.
From kernel/irq/irqdesc.c:
- generic_handle_irq - Invoke the handler for a particular irq ...
- returns:
-
negative on error -
0 when the interrupt handler was not called -
1 when the interrupt handler was called
Bug: 124912098 Change-Id: Ib5deb99c1edfca7b9ce8c68a02b6119000afde11