[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250107145051.GA23315@noisy.programming.kicks-ass.net>
Date: Tue, 7 Jan 2025 15:50:51 +0100
From: Peter Zijlstra <peterz@...radead.org>
To: Kumar Kartikeya Dwivedi <memxor@...il.com>
Cc: bpf@...r.kernel.org, linux-kernel@...r.kernel.org,
Barret Rhoden <brho@...gle.com>,
Linus Torvalds <torvalds@...ux-foundation.org>,
Waiman Long <llong@...hat.com>, Alexei Starovoitov <ast@...nel.org>,
Andrii Nakryiko <andrii@...nel.org>,
Daniel Borkmann <daniel@...earbox.net>,
Martin KaFai Lau <martin.lau@...nel.org>,
Eduard Zingerman <eddyz87@...il.com>,
"Paul E. McKenney" <paulmck@...nel.org>, Tejun Heo <tj@...nel.org>,
Josh Don <joshdon@...gle.com>, Dohyun Kim <dohyunkim@...gle.com>,
kernel-team@...a.com
Subject: Re: [PATCH bpf-next v1 07/22] rqspinlock: Add support for timeouts
On Tue, Jan 07, 2025 at 05:59:49AM -0800, Kumar Kartikeya Dwivedi wrote:
> +struct rqspinlock_timeout {
> + u64 timeout_end;
> + u64 duration;
> + u16 spin;
> +};
> +#define RES_CHECK_TIMEOUT(ts, ret) \
> + ({ \
> + if (!((ts).spin++ & 0xffff)) \
Per the above spin is a u16, this mask is pointless.
> + (ret) = check_timeout(&(ts)); \
> + (ret); \
> + })
Powered by blists - more mailing lists