linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/2] PM / devfreq: imx-bus: Remove imx_bus_get_dev_status
@ 2021-05-19  7:05 ` Dong Aisheng
  2021-05-19  7:05   ` [PATCH 2/2] devfreq: imx8m-ddrc: de-select DEVFREQ_GOV_SIMPLE_ONDEMAND Dong Aisheng
  2021-05-20  2:51   ` [PATCH 1/2] PM / devfreq: imx-bus: Remove imx_bus_get_dev_status Chanwoo Choi
  0 siblings, 2 replies; 5+ messages in thread
From: Dong Aisheng @ 2021-05-19  7:05 UTC (permalink / raw)
  To: linux-pm
  Cc: linux-arm-kernel, dongas86, linux-imx, cw00.choi, myungjoo.ham,
	kyungmin.park, shawnguo, kernel, abel.vesa, Dong Aisheng

Current driver actually does not support simple ondemand governor
as it's unable to provide device load information. So removing
the unnecessary callback to avoid confusing.
Right now the driver is using userspace governor by default.

polling_ms was also dropped as it's not needed for non-ondemand
governor.

Cc: Chanwoo Choi <cw00.choi@samsung.com>
Signed-off-by: Dong Aisheng <aisheng.dong@nxp.com>
---
 drivers/devfreq/imx-bus.c | 14 --------------
 1 file changed, 14 deletions(-)

diff --git a/drivers/devfreq/imx-bus.c b/drivers/devfreq/imx-bus.c
index 3fc3fd77492d..f3f6e25053ed 100644
--- a/drivers/devfreq/imx-bus.c
+++ b/drivers/devfreq/imx-bus.c
@@ -45,18 +45,6 @@ static int imx_bus_get_cur_freq(struct device *dev, unsigned long *freq)
 	return 0;
 }
 
-static int imx_bus_get_dev_status(struct device *dev,
-		struct devfreq_dev_status *stat)
-{
-	struct imx_bus *priv = dev_get_drvdata(dev);
-
-	stat->busy_time = 0;
-	stat->total_time = 0;
-	stat->current_frequency = clk_get_rate(priv->clk);
-
-	return 0;
-}
-
 static void imx_bus_exit(struct device *dev)
 {
 	struct imx_bus *priv = dev_get_drvdata(dev);
@@ -129,9 +117,7 @@ static int imx_bus_probe(struct platform_device *pdev)
 		return ret;
 	}
 
-	priv->profile.polling_ms = 1000;
 	priv->profile.target = imx_bus_target;
-	priv->profile.get_dev_status = imx_bus_get_dev_status;
 	priv->profile.exit = imx_bus_exit;
 	priv->profile.get_cur_freq = imx_bus_get_cur_freq;
 	priv->profile.initial_freq = clk_get_rate(priv->clk);
-- 
2.25.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* [PATCH 2/2] devfreq: imx8m-ddrc: de-select DEVFREQ_GOV_SIMPLE_ONDEMAND
  2021-05-19  7:05 ` [PATCH 1/2] PM / devfreq: imx-bus: Remove imx_bus_get_dev_status Dong Aisheng
@ 2021-05-19  7:05   ` Dong Aisheng
  2021-05-20  3:10     ` Chanwoo Choi
  2021-05-20  2:51   ` [PATCH 1/2] PM / devfreq: imx-bus: Remove imx_bus_get_dev_status Chanwoo Choi
  1 sibling, 1 reply; 5+ messages in thread
From: Dong Aisheng @ 2021-05-19  7:05 UTC (permalink / raw)
  To: linux-pm
  Cc: linux-arm-kernel, dongas86, linux-imx, cw00.choi, myungjoo.ham,
	kyungmin.park, shawnguo, kernel, abel.vesa, Dong Aisheng

The driver can't support simple ondemand governor due to missing
.get_dev_status() capability.

Cc: Chanwoo Choi <cw00.choi@samsung.com>
Signed-off-by: Dong Aisheng <aisheng.dong@nxp.com>
---
 drivers/devfreq/Kconfig | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/devfreq/Kconfig b/drivers/devfreq/Kconfig
index 20373a893b44..e87d01c0b76a 100644
--- a/drivers/devfreq/Kconfig
+++ b/drivers/devfreq/Kconfig
@@ -103,7 +103,6 @@ config ARM_IMX8M_DDRC_DEVFREQ
 	tristate "i.MX8M DDRC DEVFREQ Driver"
 	depends on (ARCH_MXC && HAVE_ARM_SMCCC) || \
 		(COMPILE_TEST && HAVE_ARM_SMCCC)
-	select DEVFREQ_GOV_SIMPLE_ONDEMAND
 	select DEVFREQ_GOV_USERSPACE
 	help
 	  This adds the DEVFREQ driver for the i.MX8M DDR Controller. It allows
-- 
2.25.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* Re: [PATCH 1/2] PM / devfreq: imx-bus: Remove imx_bus_get_dev_status
  2021-05-19  7:05 ` [PATCH 1/2] PM / devfreq: imx-bus: Remove imx_bus_get_dev_status Dong Aisheng
  2021-05-19  7:05   ` [PATCH 2/2] devfreq: imx8m-ddrc: de-select DEVFREQ_GOV_SIMPLE_ONDEMAND Dong Aisheng
@ 2021-05-20  2:51   ` Chanwoo Choi
  1 sibling, 0 replies; 5+ messages in thread
From: Chanwoo Choi @ 2021-05-20  2:51 UTC (permalink / raw)
  To: Dong Aisheng, linux-pm
  Cc: linux-arm-kernel, dongas86, linux-imx, myungjoo.ham,
	kyungmin.park, shawnguo, kernel, abel.vesa

On 5/19/21 4:05 PM, Dong Aisheng wrote:
> Current driver actually does not support simple ondemand governor
> as it's unable to provide device load information. So removing
> the unnecessary callback to avoid confusing.
> Right now the driver is using userspace governor by default.
> 
> polling_ms was also dropped as it's not needed for non-ondemand
> governor.
> 
> Cc: Chanwoo Choi <cw00.choi@samsung.com>
> Signed-off-by: Dong Aisheng <aisheng.dong@nxp.com>
> ---
>  drivers/devfreq/imx-bus.c | 14 --------------
>  1 file changed, 14 deletions(-)
> 
> diff --git a/drivers/devfreq/imx-bus.c b/drivers/devfreq/imx-bus.c
> index 3fc3fd77492d..f3f6e25053ed 100644
> --- a/drivers/devfreq/imx-bus.c
> +++ b/drivers/devfreq/imx-bus.c
> @@ -45,18 +45,6 @@ static int imx_bus_get_cur_freq(struct device *dev, unsigned long *freq)
>  	return 0;
>  }
>  
> -static int imx_bus_get_dev_status(struct device *dev,
> -		struct devfreq_dev_status *stat)
> -{
> -	struct imx_bus *priv = dev_get_drvdata(dev);
> -
> -	stat->busy_time = 0;
> -	stat->total_time = 0;
> -	stat->current_frequency = clk_get_rate(priv->clk);
> -
> -	return 0;
> -}
> -
>  static void imx_bus_exit(struct device *dev)
>  {
>  	struct imx_bus *priv = dev_get_drvdata(dev);
> @@ -129,9 +117,7 @@ static int imx_bus_probe(struct platform_device *pdev)
>  		return ret;
>  	}
>  
> -	priv->profile.polling_ms = 1000;
>  	priv->profile.target = imx_bus_target;
> -	priv->profile.get_dev_status = imx_bus_get_dev_status;
>  	priv->profile.exit = imx_bus_exit;
>  	priv->profile.get_cur_freq = imx_bus_get_cur_freq;
>  	priv->profile.initial_freq = clk_get_rate(priv->clk);
> 

Applied it. Thanks.

-- 
Best Regards,
Chanwoo Choi
Samsung Electronics

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* Re: [PATCH 2/2] devfreq: imx8m-ddrc: de-select DEVFREQ_GOV_SIMPLE_ONDEMAND
  2021-05-19  7:05   ` [PATCH 2/2] devfreq: imx8m-ddrc: de-select DEVFREQ_GOV_SIMPLE_ONDEMAND Dong Aisheng
@ 2021-05-20  3:10     ` Chanwoo Choi
  2021-05-21  3:04       ` Aisheng Dong
  0 siblings, 1 reply; 5+ messages in thread
From: Chanwoo Choi @ 2021-05-20  3:10 UTC (permalink / raw)
  To: Dong Aisheng, linux-pm
  Cc: linux-arm-kernel, dongas86, linux-imx, myungjoo.ham,
	kyungmin.park, shawnguo, kernel, abel.vesa

On 5/19/21 4:05 PM, Dong Aisheng wrote:
> The driver can't support simple ondemand governor due to missing
> .get_dev_status() capability.
> 
> Cc: Chanwoo Choi <cw00.choi@samsung.com>
> Signed-off-by: Dong Aisheng <aisheng.dong@nxp.com>
> ---
>  drivers/devfreq/Kconfig | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/drivers/devfreq/Kconfig b/drivers/devfreq/Kconfig
> index 20373a893b44..e87d01c0b76a 100644
> --- a/drivers/devfreq/Kconfig
> +++ b/drivers/devfreq/Kconfig
> @@ -103,7 +103,6 @@ config ARM_IMX8M_DDRC_DEVFREQ
>  	tristate "i.MX8M DDRC DEVFREQ Driver"
>  	depends on (ARCH_MXC && HAVE_ARM_SMCCC) || \
>  		(COMPILE_TEST && HAVE_ARM_SMCCC)
> -	select DEVFREQ_GOV_SIMPLE_ONDEMAND
>  	select DEVFREQ_GOV_USERSPACE
>  	help
>  	  This adds the DEVFREQ driver for the i.MX8M DDR Controller. It allows
> 

Looks good to me. But, How about changing the patch title as following?
- PM / devfreq: imx8m-ddrc: Remove DEVFREQ_GOV_SIMPLE_ONDEMAND dependency


-- 
Best Regards,
Chanwoo Choi
Samsung Electronics

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* RE: [PATCH 2/2] devfreq: imx8m-ddrc: de-select DEVFREQ_GOV_SIMPLE_ONDEMAND
  2021-05-20  3:10     ` Chanwoo Choi
@ 2021-05-21  3:04       ` Aisheng Dong
  0 siblings, 0 replies; 5+ messages in thread
From: Aisheng Dong @ 2021-05-21  3:04 UTC (permalink / raw)
  To: Chanwoo Choi, linux-pm
  Cc: linux-arm-kernel, dongas86, dl-linux-imx, myungjoo.ham,
	kyungmin.park, shawnguo, kernel, Abel Vesa

> From: Chanwoo Choi <cw00.choi@samsung.com>
> Sent: Thursday, May 20, 2021 11:10 AM
> 
> On 5/19/21 4:05 PM, Dong Aisheng wrote:
> > The driver can't support simple ondemand governor due to missing
> > .get_dev_status() capability.
> >
> > Cc: Chanwoo Choi <cw00.choi@samsung.com>
> > Signed-off-by: Dong Aisheng <aisheng.dong@nxp.com>
> > ---
> >  drivers/devfreq/Kconfig | 1 -
> >  1 file changed, 1 deletion(-)
> >
> > diff --git a/drivers/devfreq/Kconfig b/drivers/devfreq/Kconfig index
> > 20373a893b44..e87d01c0b76a 100644
> > --- a/drivers/devfreq/Kconfig
> > +++ b/drivers/devfreq/Kconfig
> > @@ -103,7 +103,6 @@ config ARM_IMX8M_DDRC_DEVFREQ
> >  	tristate "i.MX8M DDRC DEVFREQ Driver"
> >  	depends on (ARCH_MXC && HAVE_ARM_SMCCC) || \
> >  		(COMPILE_TEST && HAVE_ARM_SMCCC)
> > -	select DEVFREQ_GOV_SIMPLE_ONDEMAND
> >  	select DEVFREQ_GOV_USERSPACE
> >  	help
> >  	  This adds the DEVFREQ driver for the i.MX8M DDR Controller. It
> > allows
> >
> 
> Looks good to me. But, How about changing the patch title as following?
> - PM / devfreq: imx8m-ddrc: Remove DEVFREQ_GOV_SIMPLE_ONDEMAND
> dependency

Yes, good suggestion. Thanks
I will resend v2.

Regards
Aisheng

> 
> 
> --
> Best Regards,
> Chanwoo Choi
> Samsung Electronics
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

end of thread, other threads:[~2021-05-21  3:23 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <CGME20210519070646epcas1p278827601f2ce81e96e088f8fcac31d32@epcas1p2.samsung.com>
2021-05-19  7:05 ` [PATCH 1/2] PM / devfreq: imx-bus: Remove imx_bus_get_dev_status Dong Aisheng
2021-05-19  7:05   ` [PATCH 2/2] devfreq: imx8m-ddrc: de-select DEVFREQ_GOV_SIMPLE_ONDEMAND Dong Aisheng
2021-05-20  3:10     ` Chanwoo Choi
2021-05-21  3:04       ` Aisheng Dong
2021-05-20  2:51   ` [PATCH 1/2] PM / devfreq: imx-bus: Remove imx_bus_get_dev_status Chanwoo Choi

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