Received: by 2002:a05:7412:d1aa:b0:fc:a2b0:25d7 with SMTP id ba42csp1473904rdb; Tue, 30 Jan 2024 22:27:53 -0800 (PST) X-Google-Smtp-Source: AGHT+IFk6RihW2OdUw3rXgdHdKdFiaOMO8CrTDHtZJFBdRtsx2UYussM22/t26wuvn7QJ4Cc2Lfo X-Received: by 2002:a05:620a:4149:b0:785:3e5e:906a with SMTP id k9-20020a05620a414900b007853e5e906amr203848qko.60.1706682473318; Tue, 30 Jan 2024 22:27:53 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706682473; cv=pass; d=google.com; s=arc-20160816; b=ObUN+4KcgbQyW6Nlq3wrR311avmNU0Makld55y0joy8ArCl5SUlRxQIam0zvaypUI+ wyBlQK9y9tcpLoDdhWl9h/EFGWscOtjfDGwPIbxL8/HRoN2oSJi0W7PxexYMNzNMhFqi ItuRNOHB6HOKBtClvN+rka0U0eu/RcIHO6X3VQX1e6uqAd/sGJoVOSruQkcTCrWw5y8g na74NWQxlLPmAnhWgaw8Oy70fNx+BS402STDQ4kUTrg1CtnYWV4zEhCFJLJ+WX7KLi44 OXKl+szw4xhxj60WA0Is3Hpyd7kXggj7jVn7TRvE6219GfVYZhU2s4kzz70i2JVMa4qX eWsA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=user-agent:in-reply-to:content-disposition:mime-version :list-unsubscribe:list-subscribe:list-id:precedence:references :message-id:subject:cc:to:from:date; bh=bST86C1JrsS0xSzjYSBT2rQOSPmwNfUqZGcJ/iSiVV0=; fh=po16Kwgm6RWE7weesR/qAHN37zr8Wp3oXMqNKWb1RVc=; b=k56EWoTuMtM5g4q0dUQksgdmBbEsJi14yk7cH4rk0ahWTbxsWN+SzdYdeh15UPEpGj xHuh1qhi+mzvNLrSCrgXEgDFPtmkWExqnX4scW7/tif/muzXDSG54Ak+ptXZWLZauMxb GwReqp2eDHnDkDPFILv7+ekU+9lgkeNc5s6RdnF3cMy5nRmFlcJLw33yIxFCNj0SBSI3 Os/BZJBqgiVBc2tIHEEkQq2VdgsMknoUxvRYZ4LOH2lonzE9jMD2asUdE0slJlusZuQT +F6VQK/lh7z+Ik+FoAkz+OulZAiNy2iPxKWTYKoxQav9xoZeqTjMg3IkxFohxNHTbY6G 3eTQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=lst.de); spf=pass (google.com: domain of linux-kernel+bounces-45827-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-45827-linux.lists.archive=gmail.com@vger.kernel.org" X-Forwarded-Encrypted: i=1; AJvYcCUhSIqae9s6QKVgs0GIsFGKrpViGYWIoDSnupIo2hVcQjmeFJPcgo0Rop4Ca2O1b7L2WVe9XD0oCtOYMD6qx81G16kIKQ5dZtG6qRpJBg== Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id wg4-20020a05620a568400b007840a4bdc83si3209433qkn.318.2024.01.30.22.27.53 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 30 Jan 2024 22:27:53 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-45827-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=lst.de); spf=pass (google.com: domain of linux-kernel+bounces-45827-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-45827-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 1886E1C209AF for ; Wed, 31 Jan 2024 06:27:53 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id C0F0A3EA83; Wed, 31 Jan 2024 06:27:46 +0000 (UTC) Received: from verein.lst.de (verein.lst.de [213.95.11.211]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D96553EA68 for ; Wed, 31 Jan 2024 06:27:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=213.95.11.211 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706682466; cv=none; b=DXBNGZoeQPNU1D0EHrwlrg1Ur3IKoeiPQvLnDI81suMvIqxGtrWQrshfNkwvUNeuvVQfBfvFs6IaFFdBskdg039KV2QWaA1sQo60p3BDO+Ko30t8N3S80v2CRifhLcpnTs9+Wq8zYd++MO0Fy8UUkBFlQHCME4zkMBqedRWVfJg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706682466; c=relaxed/simple; bh=5a6kabL1Imum/t71C6ufR+TowFQ0vw8KXkpbEbavqO8=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=GltBeKLctJUxko8d303ig4bbo9P4ysDvm0OelyQjIk3vg/pMLpvxqWcQMgm4iEGUyDF2Kh8O9AQJoan/S/iT/8Af3dVsZeHF/RaX30CaAzgS5W0QMmoJ320LWsWz2l2y8d4pSuwJ+7ujHlh1LYX446QcuUkmju0j2hMotYgge2w= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=lst.de; spf=pass smtp.mailfrom=lst.de; arc=none smtp.client-ip=213.95.11.211 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=lst.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=lst.de Received: by verein.lst.de (Postfix, from userid 2407) id CEFDA68B05; Wed, 31 Jan 2024 07:27:41 +0100 (CET) Date: Wed, 31 Jan 2024 07:27:41 +0100 From: Christoph Hellwig To: Daniel Wagner Cc: James Smart , Keith Busch , Christoph Hellwig , Hannes Reinecke , linux-nvme@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v4 06/12] nvmet-fc: hold reference on hostport match Message-ID: <20240131062741.GE16225@lst.de> References: <20240130094938.1575-1-dwagner@suse.de> <20240130094938.1575-7-dwagner@suse.de> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20240130094938.1575-7-dwagner@suse.de> User-Agent: Mutt/1.5.17 (2007-11-01) On Tue, Jan 30, 2024 at 10:49:32AM +0100, Daniel Wagner wrote: > The hostport data structure is shared between the association, this why > we keep track of the users via a refcount. So we should not decrement > the refcount on a match and free the hostport several times. > > Reported by KASAN. > > Reviewed-by: Hannes Reinecke > Signed-off-by: Daniel Wagner Looks good: Reviewed-by: Christoph Hellwig