* [PATCH] i2c: gxp: fix an error code in probe
@ 2023-02-27 10:06 Dan Carpenter
2023-02-27 15:30 ` Hawkins, Nick
2023-03-03 20:02 ` Wolfram Sang
0 siblings, 2 replies; 3+ messages in thread
From: Dan Carpenter @ 2023-02-27 10:06 UTC (permalink / raw)
To: Nick Hawkins; +Cc: Joel Stanley, Wolfram Sang, linux-i2c, kernel-janitors
This is passing IS_ERR() instead of PTR_ERR() so instead of an error
code it prints and returns the number 1.
Fixes: 4a55ed6f89f5 ("i2c: Add GXP SoC I2C Controller")
Signed-off-by: Dan Carpenter <error27@gmail.com>
---
drivers/i2c/busses/i2c-gxp.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/i2c/busses/i2c-gxp.c b/drivers/i2c/busses/i2c-gxp.c
index da4c8e5a8039..e2a322813074 100644
--- a/drivers/i2c/busses/i2c-gxp.c
+++ b/drivers/i2c/busses/i2c-gxp.c
@@ -525,7 +525,7 @@ static int gxp_i2c_probe(struct platform_device *pdev)
i2cg_map = syscon_regmap_lookup_by_phandle(pdev->dev.of_node,
"hpe,sysreg");
if (IS_ERR(i2cg_map)) {
- return dev_err_probe(&pdev->dev, IS_ERR(i2cg_map),
+ return dev_err_probe(&pdev->dev, PTR_ERR(i2cg_map),
"failed to map i2cg_handle\n");
}
--
2.39.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] i2c: gxp: fix an error code in probe
2023-02-27 10:06 [PATCH] i2c: gxp: fix an error code in probe Dan Carpenter
@ 2023-02-27 15:30 ` Hawkins, Nick
2023-03-03 20:02 ` Wolfram Sang
1 sibling, 0 replies; 3+ messages in thread
From: Hawkins, Nick @ 2023-02-27 15:30 UTC (permalink / raw)
To: Dan Carpenter
Cc: Joel Stanley, Wolfram Sang, linux-i2c@vger.kernel.org,
kernel-janitors@vger.kernel.org
> This is passing IS_ERR() instead of PTR_ERR() so instead of an error
> code it prints and returns the number 1.
> Fixes: 4a55ed6f89f5 ("i2c: Add GXP SoC I2C Controller")
> Signed-off-by: Dan Carpenter <error27@gmail.com <mailto:error27@gmail.com>>
Looks good to me.
Reviewed-by: Nick Hawkins <nick.hawkins@hpe.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] i2c: gxp: fix an error code in probe
2023-02-27 10:06 [PATCH] i2c: gxp: fix an error code in probe Dan Carpenter
2023-02-27 15:30 ` Hawkins, Nick
@ 2023-03-03 20:02 ` Wolfram Sang
1 sibling, 0 replies; 3+ messages in thread
From: Wolfram Sang @ 2023-03-03 20:02 UTC (permalink / raw)
To: Dan Carpenter; +Cc: Nick Hawkins, Joel Stanley, linux-i2c, kernel-janitors
[-- Attachment #1: Type: text/plain, Size: 332 bytes --]
On Mon, Feb 27, 2023 at 01:06:33PM +0300, Dan Carpenter wrote:
> This is passing IS_ERR() instead of PTR_ERR() so instead of an error
> code it prints and returns the number 1.
>
> Fixes: 4a55ed6f89f5 ("i2c: Add GXP SoC I2C Controller")
> Signed-off-by: Dan Carpenter <error27@gmail.com>
Applied to for-current, thanks!
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2023-03-03 20:03 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-02-27 10:06 [PATCH] i2c: gxp: fix an error code in probe Dan Carpenter
2023-02-27 15:30 ` Hawkins, Nick
2023-03-03 20:02 ` Wolfram Sang
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox