memory: fsl-corenet-cf: Fix handling of platform_get_irq() error
authorKrzysztof Kozlowski <krzk@kernel.org>
Thu, 27 Aug 2020 07:33:15 +0000 (09:33 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 29 Oct 2020 08:03:07 +0000 (09:03 +0100)
commit0137bb476d4a4f811e3c84d8dbbefc12d90196b9
tree2f4c58ecaa67ab0e988e74c681db0e90c13236f4
parent4b2c1ec1c92cbd0cbeb4d9c98db1eb110a10e65a
memory: fsl-corenet-cf: Fix handling of platform_get_irq() error

[ Upstream commit dd85345abca60a8916617e8d75c0f9ce334336dd ]

platform_get_irq() returns -ERRNO on error.  In such case comparison
to 0 would pass the check.

Fixes: 54afbec0d57f ("memory: Freescale CoreNet Coherency Fabric error reporting driver")
Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
Link: https://lore.kernel.org/r/20200827073315.29351-1-krzk@kernel.org
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/memory/fsl-corenet-cf.c