diff mbox series

i3c/master: simplify the return expression of i3c_hci_remove()

Message ID 20220505021954.54524-1-chi.minghao@zte.com.cn (mailing list archive)
State Accepted
Headers show
Series i3c/master: simplify the return expression of i3c_hci_remove() | expand

Commit Message

CGEL May 5, 2022, 2:19 a.m. UTC
From: Minghao Chi <chi.minghao@zte.com.cn>

Simplify the return expression.

Reported-by: Zeal Robot <zealci@zte.com.cn>
Signed-off-by: Minghao Chi <chi.minghao@zte.com.cn>
---
 drivers/i3c/master/mipi-i3c-hci/core.c | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

Comments

Alexandre Belloni May 17, 2022, 8:36 p.m. UTC | #1
From: Alexandre Belloni <alexandre.belloni@bootlin.com>

On Thu, 5 May 2022 02:19:54 +0000, cgel.zte@gmail.com wrote:
> From: Minghao Chi <chi.minghao@zte.com.cn>
> 
> Simplify the return expression.
> 
> 

Applied, thanks!

[1/1] i3c/master: simplify the return expression of i3c_hci_remove()
      commit: c157a606e7525409208a51bd6663d6da3757d69e

Best regards,
diff mbox series

Patch

diff --git a/drivers/i3c/master/mipi-i3c-hci/core.c b/drivers/i3c/master/mipi-i3c-hci/core.c
index 8c01123dc4ed..6aef5ce43cc1 100644
--- a/drivers/i3c/master/mipi-i3c-hci/core.c
+++ b/drivers/i3c/master/mipi-i3c-hci/core.c
@@ -768,13 +768,8 @@  static int i3c_hci_probe(struct platform_device *pdev)
 static int i3c_hci_remove(struct platform_device *pdev)
 {
 	struct i3c_hci *hci = platform_get_drvdata(pdev);
-	int ret;
 
-	ret = i3c_master_unregister(&hci->master);
-	if (ret)
-		return ret;
-
-	return 0;
+	return i3c_master_unregister(&hci->master);
 }
 
 static const __maybe_unused struct of_device_id i3c_hci_of_match[] = {