lkml.org 
[lkml]   [2023]   [Aug]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH net-next 1/2] net: stmmac: dwmac-starfive: improve error handling during probe
On Sun, 27 Aug 2023 at 15:59, Russell King (Oracle)
<linux@armlinux.org.uk> wrote:
> On Sun, Aug 27, 2023 at 09:41:49PM +0800, Jisheng Zhang wrote:
> > After stmmac_probe_config_dt() succeeds, when error happens later,
> > stmmac_remove_config_dt() needs to be called for proper error handling.
>
> Have you thought about converting to use devm_stmmac_probe_config_dt()
> which will call stmmac_remove_config_dt() if the probe fails or when
> the device is unbound?

+1. Using devm_stmmac_probe_config_dt() seems like a better solution.

> --
> RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
> FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!

\
 
 \ /
  Last update: 2023-08-27 19:37    [W:2.921 / U:0.072 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site