* [PATCH] cpuidle: Drop unnecessary type cast in cpuidle_poll_time()
@ 2019-12-11 10:30 Rafael J. Wysocki
2019-12-11 10:33 ` Zhang, Rui
2019-12-11 15:32 ` Daniel Lezcano
0 siblings, 2 replies; 4+ messages in thread
From: Rafael J. Wysocki @ 2019-12-11 10:30 UTC (permalink / raw)
To: Linux PM; +Cc: LKML, Daniel Lezcano
From: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
The data type of the target_residency_ns field in struct cpuidle_state
is u64, so it does not need to be cast into u64.
Get read of the unnecessary type cast.
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
---
On top of the linux-next branch of linux-pm.git from today.
---
drivers/cpuidle/cpuidle.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Index: linux-pm/drivers/cpuidle/cpuidle.c
===================================================================
--- linux-pm.orig/drivers/cpuidle/cpuidle.c
+++ linux-pm/drivers/cpuidle/cpuidle.c
@@ -381,7 +381,7 @@ u64 cpuidle_poll_time(struct cpuidle_dri
if (dev->states_usage[i].disable)
continue;
- limit_ns = (u64)drv->states[i].target_residency_ns;
+ limit_ns = drv->states[i].target_residency_ns;
break;
}
^ permalink raw reply [flat|nested] 4+ messages in thread
* RE: [PATCH] cpuidle: Drop unnecessary type cast in cpuidle_poll_time()
2019-12-11 10:30 [PATCH] cpuidle: Drop unnecessary type cast in cpuidle_poll_time() Rafael J. Wysocki
@ 2019-12-11 10:33 ` Zhang, Rui
2019-12-11 10:35 ` Rafael J. Wysocki
2019-12-11 15:32 ` Daniel Lezcano
1 sibling, 1 reply; 4+ messages in thread
From: Zhang, Rui @ 2019-12-11 10:33 UTC (permalink / raw)
To: Rafael J. Wysocki, Linux PM; +Cc: LKML, Daniel Lezcano
> -----Original Message-----
> From: linux-pm-owner@vger.kernel.org [mailto:linux-pm-
> owner@vger.kernel.org] On Behalf Of Rafael J. Wysocki
> Sent: Wednesday, December 11, 2019 6:31 PM
> To: Linux PM <linux-pm@vger.kernel.org>
> Cc: LKML <linux-kernel@vger.kernel.org>; Daniel Lezcano
> <daniel.lezcano@linaro.org>
> Subject: [PATCH] cpuidle: Drop unnecessary type cast in cpuidle_poll_time()
>
> From: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
>
> The data type of the target_residency_ns field in struct cpuidle_state is u64,
> so it does not need to be cast into u64.
>
> Get read of the unnecessary type cast.
s/read/rid
thanks,
rui
>
> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
> ---
>
> On top of the linux-next branch of linux-pm.git from today.
>
> ---
> drivers/cpuidle/cpuidle.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> Index: linux-pm/drivers/cpuidle/cpuidle.c
> ==============================================================
> =====
> --- linux-pm.orig/drivers/cpuidle/cpuidle.c
> +++ linux-pm/drivers/cpuidle/cpuidle.c
> @@ -381,7 +381,7 @@ u64 cpuidle_poll_time(struct cpuidle_dri
> if (dev->states_usage[i].disable)
> continue;
>
> - limit_ns = (u64)drv->states[i].target_residency_ns;
> + limit_ns = drv->states[i].target_residency_ns;
> break;
> }
>
>
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] cpuidle: Drop unnecessary type cast in cpuidle_poll_time()
2019-12-11 10:33 ` Zhang, Rui
@ 2019-12-11 10:35 ` Rafael J. Wysocki
0 siblings, 0 replies; 4+ messages in thread
From: Rafael J. Wysocki @ 2019-12-11 10:35 UTC (permalink / raw)
To: Zhang, Rui; +Cc: Rafael J. Wysocki, Linux PM, LKML, Daniel Lezcano
On Wed, Dec 11, 2019 at 11:33 AM Zhang, Rui <rui.zhang@intel.com> wrote:
>
>
> > -----Original Message-----
> > From: linux-pm-owner@vger.kernel.org [mailto:linux-pm-
> > owner@vger.kernel.org] On Behalf Of Rafael J. Wysocki
> > Sent: Wednesday, December 11, 2019 6:31 PM
> > To: Linux PM <linux-pm@vger.kernel.org>
> > Cc: LKML <linux-kernel@vger.kernel.org>; Daniel Lezcano
> > <daniel.lezcano@linaro.org>
> > Subject: [PATCH] cpuidle: Drop unnecessary type cast in cpuidle_poll_time()
> >
> > From: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
> >
> > The data type of the target_residency_ns field in struct cpuidle_state is u64,
> > so it does not need to be cast into u64.
> >
> > Get read of the unnecessary type cast.
>
> s/read/rid
Indeed, thanks!
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] cpuidle: Drop unnecessary type cast in cpuidle_poll_time()
2019-12-11 10:30 [PATCH] cpuidle: Drop unnecessary type cast in cpuidle_poll_time() Rafael J. Wysocki
2019-12-11 10:33 ` Zhang, Rui
@ 2019-12-11 15:32 ` Daniel Lezcano
1 sibling, 0 replies; 4+ messages in thread
From: Daniel Lezcano @ 2019-12-11 15:32 UTC (permalink / raw)
To: Rafael J. Wysocki, Linux PM; +Cc: LKML
On 11/12/2019 11:30, Rafael J. Wysocki wrote:
> From: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
>
> The data type of the target_residency_ns field in struct cpuidle_state
> is u64, so it does not need to be cast into u64.
>
> Get read of the unnecessary type cast.
>
> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Acked-by: Daniel Lezcano <daniel.lezcano@linaro.org>
--
<http://www.linaro.org/> Linaro.org │ Open source software for ARM SoCs
Follow Linaro: <http://www.facebook.com/pages/Linaro> Facebook |
<http://twitter.com/#!/linaroorg> Twitter |
<http://www.linaro.org/linaro-blog/> Blog
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2019-12-11 15:32 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-12-11 10:30 [PATCH] cpuidle: Drop unnecessary type cast in cpuidle_poll_time() Rafael J. Wysocki
2019-12-11 10:33 ` Zhang, Rui
2019-12-11 10:35 ` Rafael J. Wysocki
2019-12-11 15:32 ` Daniel Lezcano
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).