lkml.org 
[lkml]   [2021]   [Jul]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCHv1 3/3] net: stmmac: dwmac-meson8b: Add reset controller for ethernet phy
> @@ -465,6 +478,13 @@ static int meson8b_dwmac_probe(struct platform_device *pdev)
> goto err_remove_config_dt;
> }
>
> + dwmac->eth_reset = devm_reset_control_get_exclusive(dwmac->dev, "ethreset");
> + if (IS_ERR_OR_NULL(dwmac->eth_reset)) {
> + dev_err(dwmac->dev, "Failed to get Ethernet reset\n");
> + ret = PTR_ERR(dwmac->eth_reset);
> + goto err_remove_config_dt;
> + }
> +

Hi Anand

Since this is a new property, you need to handle it not being in the
DT blob. You probably need to use
devm_reset_control_get_optinal_exclusive()

Andrew

\
 
 \ /
  Last update: 2021-07-29 22:22    [W:2.219 / U:0.128 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site