Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1712677
| From | Christophe JAILLET <christophe.jaillet@wanadoo.fr> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH] EDAC, thunderx: Fix an error handling path in 'thunderx_lmc_probe()' |
| Date | 2017-08-16 07:00 +0200 |
| Message-ID | <ueYAW-2vJ-35@gated-at.bofh.it> (permalink) |
| Organization | linux.* mail to news gateway |
'ret' is known to be 0 at this point.
If 'ioremap()' fails, returns -ENOMEM instead of 0 which means success.
Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
---
drivers/edac/thunderx_edac.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/edac/thunderx_edac.c b/drivers/edac/thunderx_edac.c
index c8e8b9fd4772..00b89f057695 100644
--- a/drivers/edac/thunderx_edac.c
+++ b/drivers/edac/thunderx_edac.c
@@ -779,6 +779,7 @@ static int thunderx_lmc_probe(struct pci_dev *pdev,
if (!l2c_ioaddr) {
dev_err(&pdev->dev, "Cannot map L2C_CTL\n");
+ ret = -ENOMEM;
goto err_free;
}
--
2.11.0
Back to linux.kernel | Previous | Next — Next in thread | Find similar | Unroll thread
[PATCH] EDAC, thunderx: Fix an error handling path in 'thunderx_lmc_probe()' Christophe JAILLET <christophe.jaillet@wanadoo.fr> - 2017-08-16 07:00 +0200 Re: [PATCH] EDAC, thunderx: Fix an error handling path in 'thunderx_lmc_probe()' Borislav Petkov <bp@alien8.de> - 2017-08-18 19:20 +0200
csiph-web