[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <d456062c-d5d4-be8a-d960-1a1d43f63456@huawei.com>
Date: Sat, 11 Sep 2021 10:59:11 +0800
From: Xiaoming Ni <nixiaoming@...wei.com>
To: Thomas Gleixner <tglx@...utronix.de>,
LKML <linux-kernel@...r.kernel.org>
CC: Peter Zijlstra <peterz@...radead.org>,
Ingo Molnar <mingo@...nel.org>,
Juri Lelli <juri.lelli@...hat.com>,
Steven Rostedt <rostedt@...dmis.org>,
Daniel Bristot de Oliveira <bristot@...hat.com>,
Will Deacon <will@...nel.org>,
Waiman Long <longman@...hat.com>,
Boqun Feng <boqun.feng@...il.com>,
Sebastian Andrzej Siewior <bigeasy@...utronix.de>,
Davidlohr Bueso <dave@...olabs.net>,
Mike Galbraith <efault@....de>
Subject: Re: [patch V5 34/72] locking/rwlock: Provide RT variant
On 2021/8/16 5:28, Thomas Gleixner wrote:
> From: Thomas Gleixner <tglx@...utronix.de>
>
> Similar to rw_semaphores on RT the rwlock substitution is not writer fair
> because it's not feasible to have a writer inherit it's priority to
> multiple readers. Readers blocked on a writer follow the normal rules of
> priority inheritance. Like RT spinlocks RT rwlocks are state preserving
> across the slow lock operations (contended case).
>
> Signed-off-by: Thomas Gleixner <tglx@...utronix.de>
> ---
> V5: Add missing might_sleep() and fix lockdep init (Sebastian)
> ---
> include/linux/rwlock_rt.h | 140 ++++++++++++++++++++++++++++++++++++++++
> include/linux/rwlock_types.h | 49 ++++++++++----
> include/linux/spinlock_rt.h | 2
> kernel/Kconfig.locks | 2
> kernel/locking/spinlock.c | 7 ++
> kernel/locking/spinlock_debug.c | 5 +
> kernel/locking/spinlock_rt.c | 131 +++++++++++++++++++++++++++++++++++++
> 7 files changed, 323 insertions(+), 13 deletions(-)
> create mode 100644 include/linux/rwlock_rt.h
> ---
.....
> +
> +int __sched rt_rwlock_is_contended(rwlock_t *rwlock)
> +{
> + return rw_base_is_contended(&rwlock->rwbase);
> +}
> +EXPORT_SYMBOL(rt_rwlock_is_contended);
> +
rt_rwlock_is_conted() exported but not declared in the header file?
Is this a special design or a mistake?
Thanks
Xiaoming Ni
Powered by blists - more mailing lists