Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752802AbbHCGVx (ORCPT ); Mon, 3 Aug 2015 02:21:53 -0400 Received: from mail.linux-iscsi.org ([67.23.28.174]:36731 "EHLO linux-iscsi.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750801AbbHCGVv (ORCPT ); Mon, 3 Aug 2015 02:21:51 -0400 Message-ID: <1438582907.16598.92.camel@haakon3.risingtidesystems.com> Subject: Re: [PATCH v3] target: Drop iSCSI use of mutex around max_cmd_sn increment From: "Nicholas A. Bellinger" To: Spencer Baugh Cc: "Elliott, Robert (Server Storage)" , Spencer Baugh , Sagi Grimberg , Christoph Hellwig , Bart Van Assche , Alexei Potashnik , Andy Grover , Christophe Vu-Brugier , Roland Dreier , Joern Engel , Andy Shevchenko , James Bottomley , Evgenii Lepikhin , Hannes Reinecke , Al Viro , "open list:TARGET SUBSYSTEM" , "open list:TARGET SUBSYSTEM" , open list , Joern Engel Date: Sun, 02 Aug 2015 23:21:47 -0700 In-Reply-To: <87egjyfsmb.fsf@ponos.purestorage.com> References: <1437602898-15229-2-git-send-email-sbaugh@catern.com> <94D0CD8314A33A4D9D801C0FE68B40295AA03CD1@G9W0745.americas.hpqcorp.net> <87r3nyg1km.fsf@ponos.purestorage.com> <87egjyfsmb.fsf@ponos.purestorage.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.4.4-1 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1626 Lines: 40 On Thu, 2015-07-23 at 14:53 -0700, Spencer Baugh wrote: > From: Roland Dreier > > In a performance profile, taking a mutex in iscsit_increment_maxcmdsn() > shows up very high. However taking a mutex around "sess->max_cmd_sn += 1" > seems pretty silly: we're not serializing against other contexts in > any useful way. > > I did a quick audit and there don't appear to be any other places that > use max_cmd_sn within the mutex more than once, so this lock can't be > providing any useful serialization. > > v2: Get correct values for logging > v3: Fix whitespace damage > > Signed-off-by: Roland Dreier > Signed-off-by: Spencer Baugh > --- > drivers/target/iscsi/iscsi_target.c | 18 +++++++++--------- > drivers/target/iscsi/iscsi_target_configfs.c | 6 ++++-- > drivers/target/iscsi/iscsi_target_device.c | 7 ++----- > drivers/target/iscsi/iscsi_target_login.c | 2 +- > drivers/target/iscsi/iscsi_target_nego.c | 9 +++------ > drivers/target/iscsi/iscsi_target_tmr.c | 2 +- > drivers/target/iscsi/iscsi_target_util.c | 7 ++++--- > include/target/iscsi/iscsi_target_core.h | 2 +- > 8 files changed, 25 insertions(+), 28 deletions(-) > A nice optimization for iscsi-target + ib_isert on this patch. Applied to target-pending/for-next. Thanks Roland & Co. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/