Received: by 2002:a05:6a10:af89:0:0:0:0 with SMTP id iu9csp721910pxb; Fri, 14 Jan 2022 15:01:25 -0800 (PST) X-Google-Smtp-Source: ABdhPJzHWw5+srrJk8Qw8uDV8FZuQx52oStgSwFJUeJER5w4yjO8tTJZ7T3PNR3Qi4BRF6JKqDFY X-Received: by 2002:aa7:d546:: with SMTP id u6mr10791358edr.311.1642201285246; Fri, 14 Jan 2022 15:01:25 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1642201285; cv=none; d=google.com; s=arc-20160816; b=zvVt8vAt28LR3oxCbmSrBgJ5aXJ0AOX/3zqBlNrgVV34xdn/lxItwdmnjcmGRpU7Nz i8LHsGDhn0+U3K+ZjjU6AlKCGQZiG8iMmDZmizJl3e5QWKwgrZTq0knxyVzOmR++3wat 97aPZ2GYOzZwJXP9vpNqdj7jfj5qM78mUxQwWLhIVdbFGi/jhC0ChIfsk2Pb66IsJMPW r1KkLuiK+2WKXVMCOHIa2cYlKOyBKUTbi2qAcCG3rCI0Pyu6iX2crWj5LH4ejpRH1o0H fWyOD3H14PRCRW3UbIt8DUHFHynDawvZTyRrpziglkano1GI2d5He+V7QfHKUjaHoUZA cxCg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:sender:dkim-signature; bh=5Tf1y8NPR8awPz4dMppv7tyk5zmNgJO+gD+PDlVaFbU=; b=twtELpHDiwSS/5VddszvizUpGtVx+F7PyEoXnfQivCJrmgRlpfBmAu+bnp+BpoATt2 q4Abhft5n7ozQlN0Y/bn5rtLhQuxcI8h+fkoBi9pD1Lbra08IE6z7hBwT71mDWtn90Sx A7bl+D9U03gXpoRLaSX5S4YLfhBjmlvsEvxQ1Kg558YhMBsrweHFlhArEIZds8MzdG4/ WB9FG44v+0JIdy5r1iW5vAZ2iSlRYOKJG6lUSOBDHHYTQDxZfyHiKLMXTYPM6tIB18MV zUl21MECib3PJiInTPytjnwSzQi7yWwSCHRi/3UsBOQR855+QcwAf7Fo+bPL7HNEmLNR ylxA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=GqaVr+XF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id t2si3341069ejf.487.2022.01.14.15.00.58; Fri, 14 Jan 2022 15:01:25 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=GqaVr+XF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S243968AbiANRo3 (ORCPT + 99 others); Fri, 14 Jan 2022 12:44:29 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39982 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S243936AbiANRoP (ORCPT ); Fri, 14 Jan 2022 12:44:15 -0500 Received: from mail-pj1-x102a.google.com (mail-pj1-x102a.google.com [IPv6:2607:f8b0:4864:20::102a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 51D3EC061401 for ; Fri, 14 Jan 2022 09:44:15 -0800 (PST) Received: by mail-pj1-x102a.google.com with SMTP id n16-20020a17090a091000b001b46196d572so875380pjn.5 for ; Fri, 14 Jan 2022 09:44:15 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=5Tf1y8NPR8awPz4dMppv7tyk5zmNgJO+gD+PDlVaFbU=; b=GqaVr+XFcNjvPXq229ojhvvTmtPiHYVcrAnWb0O/RJ6Uix8SEUIyG5U8bq/HXusseL BA2h+dlVGvTK8qidZiB+I+I4qtOuRF37fvVk8jmO4zBV9AWd5psuWkvly7NWRpK6NS5l 4IHwKlMfq9VOvdSQ3mY2BWxS7TPkeE+yp4419FWKpoLgQyXFYT2TMYITpMxHCHvE4OE7 HDILMnGA/FLRZzyE7brIYZwptfH9r/ni97Fq+GJVgEXRpr3nQaDVQ3jrnQFAyH8W+yAO R4E7TL5GsJ+pdTYsslQSpn0pzwWLjmdO+3vpbye6j6WWMUDKRX2u1v+3+cPYHOvvpTex yTrw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:sender:date:from:to:cc:subject:message-id :references:mime-version:content-disposition:in-reply-to; bh=5Tf1y8NPR8awPz4dMppv7tyk5zmNgJO+gD+PDlVaFbU=; b=qhTcGfF2sPX/YYlrP2O+CzchS8IbPEdo3Tuu8zizkqxKQhUTrL3AdIyqddPH0XpyMF C6wJoB9KhI0cUTWPjPXpss6cMHQtW4uvcCNSVs42OmPGuEMKRQtaAsfv8hvcDIE+hSHX /f/yW8eUMtbwTxBA/ceAN3FCtWwIQiaoISV5IvlFdOY7+7cIFx1xfijl7TWTfUWyMoX3 h+Y/Yy2Pa5jMm1WnwwqZTcxHMfmamfzTHol3A6S5+TFP+j3nUhcea7J5rGsonre3ymIq kEpNmfoowEqtyULH8kvHm7D01gXnEb1N/8aZVg8dniNAXY41jFVx6DKyX+uFenbt1DLS rqJw== X-Gm-Message-State: AOAM532caSf3qec977B9i1uSuaG4Qh1ZP9X/uuQHLDpAcol10x8NzDye rqM/A5keBT1ZMN+E/M45lMg= X-Received: by 2002:a17:90b:4f8d:: with SMTP id qe13mr21147321pjb.178.1642182254689; Fri, 14 Jan 2022 09:44:14 -0800 (PST) Received: from localhost (2603-800c-1a02-1bae-e24f-43ff-fee6-449f.res6.spectrum.com. [2603:800c:1a02:1bae:e24f:43ff:fee6:449f]) by smtp.gmail.com with ESMTPSA id s5sm6140342pfe.117.2022.01.14.09.44.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 14 Jan 2022 09:44:13 -0800 (PST) Sender: Tejun Heo Date: Fri, 14 Jan 2022 07:44:12 -1000 From: Tejun Heo To: Imran Khan Cc: gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v3 2/2] kernfs: Reduce contention around global per-fs kernfs_rwsem. Message-ID: References: <20220113104259.1584491-1-imran.f.khan@oracle.com> <20220113104259.1584491-3-imran.f.khan@oracle.com> <84861be0-519a-233d-9c6c-482f12e33328@oracle.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <84861be0-519a-233d-9c6c-482f12e33328@oracle.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hello, On Sat, Jan 15, 2022 at 04:08:10AM +1100, Imran Khan wrote: > I have made changes inline with your suggestion to synchronize > addition/removal through hashed locks but so far I am not using tokens. > I am currently testing these changes (so far no issues seen). Before > floating next version for review I wanted to understand the reason > behind need of tokens. Could you please elaborate a bit about what needs > / may have to be recorded in tokens. Just one example will do. It would > help me consolidate the next version of this change without overlooking > something. Oh, just sth to carry what needs to be done to unlock. If you didn't need them and returning pointers to the locks was enough, that's fine too but if double locking was necessary for e.g. removals, encapsulating it in a struct may be neater. Thanks. -- tejun