mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH v1 1/1] PM/devfreq: Remove unneeded casting for HZ_PER_KHZ
@ 2026-01-14  9:31 Andy Shevchenko
  2026-01-14  9:46 ` zhenglifeng (A)
       [not found] ` <CGME20260114093125epcas1p17c29852c6b5b066057b60c9a7795be77@epcms1p5>
  0 siblings, 2 replies; 4+ messages in thread
From: Andy Shevchenko @ 2026-01-14  9:31 UTC (permalink / raw)
  To: Chanwoo Choi, Lifeng Zheng, linux-pm, linux-kernel
  Cc: MyungJoo Ham, Kyungmin Park, Andy Shevchenko

HZ_PER_KHZ is defined as UL (unsigned long), no need to repeat that.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
 drivers/devfreq/devfreq.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/devfreq/devfreq.c b/drivers/devfreq/devfreq.c
index 00979f2e0e27..51eb67fba44b 100644
--- a/drivers/devfreq/devfreq.c
+++ b/drivers/devfreq/devfreq.c
@@ -146,10 +146,9 @@ void devfreq_get_freq_range(struct devfreq *devfreq,
 					     DEV_PM_QOS_MIN_FREQUENCY);
 	qos_max_freq = dev_pm_qos_read_value(devfreq->dev.parent,
 					     DEV_PM_QOS_MAX_FREQUENCY);
-	*min_freq = max(*min_freq, (unsigned long)HZ_PER_KHZ * qos_min_freq);
+	*min_freq = max(*min_freq, HZ_PER_KHZ * qos_min_freq);
 	if (qos_max_freq != PM_QOS_MAX_FREQUENCY_DEFAULT_VALUE)
-		*max_freq = min(*max_freq,
-				(unsigned long)HZ_PER_KHZ * qos_max_freq);
+		*max_freq = min(*max_freq, HZ_PER_KHZ * qos_max_freq);
 
 	/* Apply constraints from OPP interface */
 	*max_freq = clamp(*max_freq, devfreq->scaling_min_freq, devfreq->scaling_max_freq);
-- 
2.50.1


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

end of thread, other threads:[~2026-02-04  2:45 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-01-14  9:31 [PATCH v1 1/1] PM/devfreq: Remove unneeded casting for HZ_PER_KHZ Andy Shevchenko
2026-01-14  9:46 ` zhenglifeng (A)
     [not found] ` <CGME20260114093125epcas1p17c29852c6b5b066057b60c9a7795be77@epcms1p5>
2026-01-20  9:32   ` MyungJoo Ham
2026-02-04  2:45     ` Andy Shevchenko

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®