linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] phy/allwinner: phy-sun50i-usb3: Use dev_err_probe()
@ 2025-03-28  9:02 shao.mingyin
  2025-03-28 17:08 ` Krzysztof Kozlowski
  0 siblings, 1 reply; 4+ messages in thread
From: shao.mingyin @ 2025-03-28  9:02 UTC (permalink / raw)
  To: vkoul
  Cc: kishon, wens, jernej.skrabec, samuel, zhang.enpei, linux-phy,
	linux-arm-kernel, linux-sunxi, linux-kernel, yang.yang29,
	xu.xin16, ye.xingchen

From: Zhang Enpei <zhang.enpei@zte.com.cn>

Replace the open-code with dev_err_probe() to simplify the code.

Signed-off-by: Zhang Enpei <zhang.enpei@zte.com.cn>
Signed-off-by: Shao Mingyin <shao.mingyin@zte.com.cn>
---
 drivers/phy/allwinner/phy-sun50i-usb3.c | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)

diff --git a/drivers/phy/allwinner/phy-sun50i-usb3.c b/drivers/phy/allwinner/phy-sun50i-usb3.c
index 363f9a0df503..b03faffc160d 100644
--- a/drivers/phy/allwinner/phy-sun50i-usb3.c
+++ b/drivers/phy/allwinner/phy-sun50i-usb3.c
@@ -141,11 +141,9 @@ static int sun50i_usb3_phy_probe(struct platform_device *pdev)
 		return -ENOMEM;

 	phy->clk = devm_clk_get(dev, NULL);
-	if (IS_ERR(phy->clk)) {
-		if (PTR_ERR(phy->clk) != -EPROBE_DEFER)
-			dev_err(dev, "failed to get phy clock\n");
-		return PTR_ERR(phy->clk);
-	}
+	if (IS_ERR(phy->clk))
+		return dev_err_probe(dev, PTR_ERR(phy->clk),
+				     "failed to get phy clock\n");

 	phy->reset = devm_reset_control_get(dev, NULL);
 	if (IS_ERR(phy->reset)) {
-- 
2.25.1


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

* Re: [PATCH] phy/allwinner: phy-sun50i-usb3: Use dev_err_probe()
  2025-03-28  9:02 shao.mingyin
@ 2025-03-28 17:08 ` Krzysztof Kozlowski
  0 siblings, 0 replies; 4+ messages in thread
From: Krzysztof Kozlowski @ 2025-03-28 17:08 UTC (permalink / raw)
  To: shao.mingyin, vkoul
  Cc: kishon, wens, jernej.skrabec, samuel, zhang.enpei, linux-phy,
	linux-arm-kernel, linux-sunxi, linux-kernel, yang.yang29,
	xu.xin16, ye.xingchen

On 28/03/2025 10:02, shao.mingyin@zte.com.cn wrote:
> From: Zhang Enpei <zhang.enpei@zte.com.cn>
> 
> Replace the open-code with dev_err_probe() to simplify the code.
> 
> Signed-off-by: Zhang Enpei <zhang.enpei@zte.com.cn>
> Signed-off-by: Shao Mingyin <shao.mingyin@zte.com.cn>

Why are you sending patch-by-patch? Organize your work for the same
subsystem into one patchset so we see entire picture at once, not spread
onto 10 separate threads.

Best regards,
Krzysztof


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

* Re: [PATCH] phy/allwinner: phy-sun50i-usb3: Use dev_err_probe()
@ 2025-03-31  2:32 shao.mingyin
  2025-03-31  6:48 ` Vinod Koul
  0 siblings, 1 reply; 4+ messages in thread
From: shao.mingyin @ 2025-03-31  2:32 UTC (permalink / raw)
  To: krzk, vkoul
  Cc: kishon, wens, jernej.skrabec, samuel, zhang.enpei, linux-phy,
	linux-arm-kernel, linux-sunxi, linux-kernel, yang.yang29,
	xu.xin16, ye.xingchen

>On 28/03/2025 10:02, shao.mingyin@zte.com.cn wrote:
>> From: Zhang Enpei <zhang.enpei@zte.com.cn>
>> 
>> Replace the open-code with dev_err_probe() to simplify the code.
>> 
>> Signed-off-by: Zhang Enpei <zhang.enpei@zte.com.cn>
>> Signed-off-by: Shao Mingyin <shao.mingyin@zte.com.cn>
>
>Why are you sending patch-by-patch? Organize your work for the same
>subsystem into one patchset so we see entire picture at once, not spread
>onto 10 separate threads.
>
>Best regards,
>Krzysztof

Dear Krzysztof,
Thank you for the constructive feedback.
We apologize for any inconvenience caused.We will regroup the patches 
targeting the same subsystem into a consolidated series.

Best regards,
Shao Mingyin


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

* Re: [PATCH] phy/allwinner: phy-sun50i-usb3: Use dev_err_probe()
  2025-03-31  2:32 [PATCH] phy/allwinner: phy-sun50i-usb3: Use dev_err_probe() shao.mingyin
@ 2025-03-31  6:48 ` Vinod Koul
  0 siblings, 0 replies; 4+ messages in thread
From: Vinod Koul @ 2025-03-31  6:48 UTC (permalink / raw)
  To: shao.mingyin
  Cc: krzk, kishon, wens, jernej.skrabec, samuel, zhang.enpei,
	linux-phy, linux-arm-kernel, linux-sunxi, linux-kernel,
	yang.yang29, xu.xin16, ye.xingchen

On 31-03-25, 10:32, shao.mingyin@zte.com.cn wrote:
> >On 28/03/2025 10:02, shao.mingyin@zte.com.cn wrote:
> >> From: Zhang Enpei <zhang.enpei@zte.com.cn>
> >> 
> >> Replace the open-code with dev_err_probe() to simplify the code.
> >> 
> >> Signed-off-by: Zhang Enpei <zhang.enpei@zte.com.cn>
> >> Signed-off-by: Shao Mingyin <shao.mingyin@zte.com.cn>
> >
> >Why are you sending patch-by-patch? Organize your work for the same
> >subsystem into one patchset so we see entire picture at once, not spread
> >onto 10 separate threads.
> >
> >Best regards,
> >Krzysztof
> 
> Dear Krzysztof,
> Thank you for the constructive feedback.
> We apologize for any inconvenience caused.We will regroup the patches 
> targeting the same subsystem into a consolidated series.

Nice, while at it, please see the subsystem tagging style. Here it
should be "phy: allwinner: xxxxx"

-- 
~Vinod


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

end of thread, other threads:[~2025-03-31  6:50 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-03-31  2:32 [PATCH] phy/allwinner: phy-sun50i-usb3: Use dev_err_probe() shao.mingyin
2025-03-31  6:48 ` Vinod Koul
  -- strict thread matches above, loose matches on Subject: below --
2025-03-28  9:02 shao.mingyin
2025-03-28 17:08 ` Krzysztof Kozlowski

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).