From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751228AbeEKAki (ORCPT ); Thu, 10 May 2018 20:40:38 -0400 Received: from mx2.suse.de ([195.135.220.15]:37335 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750751AbeEKAkh (ORCPT ); Thu, 10 May 2018 20:40:37 -0400 From: NeilBrown To: Oleg Drokin , Andreas Dilger , James Simmons Date: Fri, 11 May 2018 10:37:14 +1000 Subject: RFC: [PATCH 0/6] lustre: Improve locking in lu_object.s Cc: Linux Kernel Mailing List , Lustre Development List Message-ID: <152599874625.19824.11344372150811845854.stgit@noble> User-Agent: StGit/0.17.1-dirty MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This is a followup to the patches that James recently posted which addressed some locking issues in lu_object.c. I said at the time that I thought the locking could be improved further. Here is the result of that thought. The lu_keys_guard lock is now gone, replaced by a spin lock, an rwsem, and some lockless code. The lu_context_exit() function, which appears to have been a performance problem at one point, is now completely lockless. This is an RFC at this stage: I haven't included Greg on the email and don't expect this to go upstream without some review - and maybe even some testing. Thanks, NeilBrown --- NeilBrown (6): staging: lustre: make key_set_version an atomic_t staging: lustre: use an rwsem instead of lu_key_initing_cnt. staging: lustre: remove locking from lu_context_exit() staging: lustre: use wait_event_var() in lu_context_key_degister() staging: lustre: remove lock from key register/degister staging: lustre: rename lu_keys_guard to lu_context_remembered_guard drivers/staging/lustre/lustre/include/lu_object.h | 1 drivers/staging/lustre/lustre/obdclass/lu_object.c | 187 ++++++++------------ 2 files changed, 78 insertions(+), 110 deletions(-) -- Signature