Re: [PATCH v3 2/5] locking/rwsem: Limit # of null owner retries for handoff writer

From: Waiman Long
Date: Tue Oct 25 2022 - 21:44:28 EST


On 10/25/22 16:14, Peter Zijlstra wrote:
On Tue, Oct 25, 2022 at 03:55:09PM -0400, Waiman Long wrote:

That is quite a number of changes spread over many different functions. That
is the kind of changes that may make it harder to backport to stable
releases.
Yeah; don't care. it's the right thing to do. It also doesn't need to be
reverted since it's a sane and good property for lock-ops to have.

I am sorry to confuse you. What I am saying is the original patch 2 of the series, not what you have proposed. I am fine about disabling preemption while running in the core rwsem code.

As a counter proposal, I will suggest modifying patch 2 to disable preemption for the reader rwsem code as the writer code already have preemption disabled in the most critical parts. Then I add another patch to complete the writer side conversion for symmetry. Are you OK with that?

Cheers,
Longman