[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190823224404.GG18880@lenoir>
Date: Sat, 24 Aug 2019 00:44:05 +0200
From: Frederic Weisbecker <frederic@...nel.org>
To: Thomas Gleixner <tglx@...utronix.de>
Cc: LKML <linux-kernel@...r.kernel.org>,
Oleg Nesterov <oleg@...hat.com>,
Ingo Molnar <mingo@...nel.org>,
Peter Zijlstra <peterz@...radead.org>,
John Stultz <john.stultz@...aro.org>,
Anna-Maria Behnsen <anna-maria@...utronix.de>,
Christoph Hellwig <hch@....de>
Subject: Re: [patch V2 26/38] posix-cpu-timers: Make expiry checks array based
On Wed, Aug 21, 2019 at 09:09:13PM +0200, Thomas Gleixner wrote:
> The expiry cache is an array indexed by clock ids. The new sample functions
> allow to retrieve a corresponding array of samples.
>
> Convert the fastpath expiry checks to make use of the new sample functions
> and do the comparisons on the sample and the expiry array.
>
> Make the check for the expiry array being zero array based as well.
>
> Signed-off-by: Thomas Gleixner <tglx@...utronix.de>
Reviewed-by: Frederic Weisbecker <frederic@...nel.org>
Just a few boring neats:
> /**
> - * task_cputime_expired - Compare two task_cputime entities.
> + * task_cputimers_expired - Compare two task_cputime entities.
s/task_cputime/clock arrays ?
> *
> - * @sample: The task_cputime structure to be checked for expiration.
> - * @expires: Expiration times, against which @sample will be checked.
> + * @samples: Array of current samples for the CPUCLOCK clocks
> + * @expiries: Array of expiry values for the CPUCLOCK clocks
> *
> - * Checks @sample against @expires to see if any field of @sample has expired.
> - * Returns true if any field of the former is greater than the corresponding
> - * field of the latter if the latter field is set. Otherwise returns false.
> + * Returns true if any mmember of @samples is greater than the corresponding
s/mmember/member
> + * member of @expiries if that member is non zero. False otherwise
> */
> -static inline int task_cputime_expired(const struct task_cputime *sample,
> - const struct task_cputime *expires)
> +static inline bool task_cputimers_expired(const u64 *sample, const u64 *expiries)
s/sample/samples to agree with above documented parameters.
Thanks.
Powered by blists - more mailing lists