linux-usb.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 01/11] dwc3: meson: fix coccinelle WARNING
@ 2020-08-13  6:25 balbi
  2020-08-13  6:25 ` [PATCH 02/11] dwc3: debug: fix sparse warning balbi
                   ` (9 more replies)
  0 siblings, 10 replies; 15+ messages in thread
From: balbi @ 2020-08-13  6:25 UTC (permalink / raw)
  To: Linux USB; +Cc: Felipe Balbi

From: Felipe Balbi <balbi@kernel.org>

Coccinelle suggests using PTR_ERR_OR_ZERO().

Signed-off-by: Felipe Balbi <balbi@kernel.org>
---
 drivers/usb/dwc3/dwc3-meson-g12a.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/drivers/usb/dwc3/dwc3-meson-g12a.c b/drivers/usb/dwc3/dwc3-meson-g12a.c
index 88b75b5a039c..9c50a8f2929e 100644
--- a/drivers/usb/dwc3/dwc3-meson-g12a.c
+++ b/drivers/usb/dwc3/dwc3-meson-g12a.c
@@ -626,10 +626,7 @@ static int dwc3_meson_gxl_setup_regmaps(struct dwc3_meson_g12a *priv,
 	/* GXL controls the PHY mode in the PHY registers unlike G12A */
 	priv->usb_glue_regmap = devm_regmap_init_mmio(priv->dev, base,
 					&phy_meson_g12a_usb_glue_regmap_conf);
-	if (IS_ERR(priv->usb_glue_regmap))
-		return PTR_ERR(priv->usb_glue_regmap);
-
-	return 0;
+	return PTR_ERR_OR_ZERO(priv->usb_glue_regmap);
 }
 
 static int dwc3_meson_g12a_setup_regmaps(struct dwc3_meson_g12a *priv,
-- 
2.28.0


^ permalink raw reply related	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2020-08-14  6:16 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-08-13  6:25 [PATCH 01/11] dwc3: meson: fix coccinelle WARNING balbi
2020-08-13  6:25 ` [PATCH 02/11] dwc3: debug: fix sparse warning balbi
2020-08-13  6:25 ` [PATCH 03/11] dwc3: meson: fix checkpatch errors and warnings balbi
2020-08-13  6:25 ` [PATCH 04/11] dwc3: ulpi: fix checkpatch warning balbi
2020-08-13  6:25 ` [PATCH 05/11] dwc3: trace: fix checkpatch warnings balbi
2020-08-13  6:25 ` [PATCH 06/11] dwc3: debug: fix checkpatch warning balbi
2020-08-13  6:25 ` [PATCH 07/11] dwc3: core: fix checkpatch warnings balbi
2020-08-13  6:25 ` [PATCH 08/11] dwc3: gadget: " balbi
2020-08-13  6:25 ` [PATCH 09/11] dwc3: ep0: " balbi
2020-08-13  6:25 ` [PATCH 10/11] dwc3: qcom: " balbi
2020-08-13  6:25 ` [PATCH 11/11] dwc3: debugfs: " balbi
2020-08-13 19:14   ` Thinh Nguyen
2020-08-14  5:12     ` Felipe Balbi
2020-08-14  5:36       ` Thinh Nguyen
2020-08-14  6:16         ` Thinh Nguyen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).