This patch is to fix the following compile warning:
  pci-s32cc-ep.c:504:21: warning: the comparison will always evaluate as 'true' 
for the address of 'msi_irq' will never be NULL [-Waddress]

The reason it that, the variable pp->msi_irq is always true, since it is a
array, so change to use pp->msi_irq[0], which is the real used irq for s32g
pci driver, to fix the above warning.

Signed-off-by: Zhantao Tang <zhantao.t...@windriver.com>
---
 drivers/pci/controller/dwc/pci-s32cc-ep.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/pci/controller/dwc/pci-s32cc-ep.c 
b/drivers/pci/controller/dwc/pci-s32cc-ep.c
index 37f649ce83e1..7ddf12e64682 100644
--- a/drivers/pci/controller/dwc/pci-s32cc-ep.c
+++ b/drivers/pci/controller/dwc/pci-s32cc-ep.c
@@ -501,7 +501,7 @@ static int s32cc_pcie_config_ep(struct s32cc_pcie *s32cc_pp,
                if (ret)
                        dev_err(dev, "Unable to setup MSI domain for EP\n");
 
-               if (pp->msi_irq)
+               if (pp->msi_irq[0])
                        irq_set_chained_handler_and_data(pp->msi_irq[0],
                                                         dw_ep_chained_msi_isr,
                                                         pp);
-- 
2.34.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#14127): 
https://lists.yoctoproject.org/g/linux-yocto/message/14127
Mute This Topic: https://lists.yoctoproject.org/mt/107119573/21656
Group Owner: linux-yocto+ow...@lists.yoctoproject.org
Unsubscribe: https://lists.yoctoproject.org/g/linux-yocto/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to