locking/rwsem: Pass the current atomic count to rwsem_down_read_slowpath()
mainline inclusion from mainline-v5.11-rc1 commit c8fe8b05 category: bugfix bugzilla: https://gitee.com/openeuler/kernel/issues/I7A0N9 CVE: NA Reference: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=c8fe8b0564388f41147326f31e4587171aacccd4 -------------------------------- The atomic count value right after reader count increment can be useful to determine the rwsem state at trylock time. So the count value is passed down to rwsem_down_read_slowpath() to be used when appropriate. Signed-off-by: NWaiman Long <longman@redhat.com> Signed-off-by: NPeter Zijlstra (Intel) <peterz@infradead.org> Reviewed-by: NDavidlohr Bueso <dbueso@suse.de> Link: https://lkml.kernel.org/r/20201121041416.12285-2-longman@redhat.com Conflicts: kernel/locking/rwsem.c [yyl: No functional changed.] Signed-off-by: NYang Yingliang <yangyingliang@huawei.com> (cherry picked from commit 6f54c87c)
Showing
想要评论请 注册 或 登录