diff mbox series

cpufreq: ti-cpufreq: Handle deferred probe with dev_err_probe()

Message ID 20240606065847.3499145-1-primoz.fiser@norik.com (mailing list archive)
State New
Delegated to: viresh kumar
Headers show
Series cpufreq: ti-cpufreq: Handle deferred probe with dev_err_probe() | expand

Commit Message

Primoz Fiser June 6, 2024, 6:58 a.m. UTC
Handle deferred probing gracefully by using dev_err_probe() to not
spam console with unnecessary error messages.

Fixes: f88d152dc739 ("cpufreq: ti: Migrate to dev_pm_opp_set_config()")
Signed-off-by: Primoz Fiser <primoz.fiser@norik.com>
---
 drivers/cpufreq/ti-cpufreq.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Viresh Kumar June 6, 2024, 9 a.m. UTC | #1
On 06-06-24, 08:58, Primoz Fiser wrote:
> Handle deferred probing gracefully by using dev_err_probe() to not
> spam console with unnecessary error messages.
> 
> Fixes: f88d152dc739 ("cpufreq: ti: Migrate to dev_pm_opp_set_config()")
> Signed-off-by: Primoz Fiser <primoz.fiser@norik.com>
> ---
>  drivers/cpufreq/ti-cpufreq.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/cpufreq/ti-cpufreq.c b/drivers/cpufreq/ti-cpufreq.c
> index 714ed53753fa..5af85c4cbad0 100644
> --- a/drivers/cpufreq/ti-cpufreq.c
> +++ b/drivers/cpufreq/ti-cpufreq.c
> @@ -417,7 +417,7 @@ static int ti_cpufreq_probe(struct platform_device *pdev)
>  
>  	ret = dev_pm_opp_set_config(opp_data->cpu_dev, &config);
>  	if (ret < 0) {
> -		dev_err(opp_data->cpu_dev, "Failed to set OPP config\n");
> +		dev_err_probe(opp_data->cpu_dev, ret, "Failed to set OPP config\n");
>  		goto fail_put_node;
>  	}

Applied. Thanks.
diff mbox series

Patch

diff --git a/drivers/cpufreq/ti-cpufreq.c b/drivers/cpufreq/ti-cpufreq.c
index 714ed53753fa..5af85c4cbad0 100644
--- a/drivers/cpufreq/ti-cpufreq.c
+++ b/drivers/cpufreq/ti-cpufreq.c
@@ -417,7 +417,7 @@  static int ti_cpufreq_probe(struct platform_device *pdev)
 
 	ret = dev_pm_opp_set_config(opp_data->cpu_dev, &config);
 	if (ret < 0) {
-		dev_err(opp_data->cpu_dev, "Failed to set OPP config\n");
+		dev_err_probe(opp_data->cpu_dev, ret, "Failed to set OPP config\n");
 		goto fail_put_node;
 	}