Received: by 2002:ab2:710b:0:b0:1ef:a325:1205 with SMTP id z11csp899948lql; Tue, 12 Mar 2024 00:58:20 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVmOUAau52laVSboAS53Q6XwI/f+NPKRmUgULip5jZue74ALtdpxdaF7Tt0BFhmYlrI8oej5Yr9BZLB9xGvAteMjoiwqYG5WwCGmIomPw== X-Google-Smtp-Source: AGHT+IEbERFwQHXuhaLIGaLhmadS9mhVWE1tISTWgJCR64gnzsmdKDnstaM/qMHXyZv52RxXRYdt X-Received: by 2002:a05:6a20:734e:b0:1a1:86ac:fa3f with SMTP id v14-20020a056a20734e00b001a186acfa3fmr7653679pzc.6.1710230299950; Tue, 12 Mar 2024 00:58:19 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1710230299; cv=pass; d=google.com; s=arc-20160816; b=a42bM/cwpITm3OfA26GS0EAijshj0zbBjBdv4Ao30BAB8D7R8ECxon6MG3L3kozBwa JazGYLgoz7oJo1gSSbrtKF/Y6iCb5ELyCyWzzUWwbaQcYAj3Ehx4M9XxBUYQ/Q/uYADd jl9LIGiFNe7y5DWSl2qVjpfnMT4F5XbpYon9ExYDf77w1+f1x2yob71/EM6A38cTScBL 9BFJO/ErSDXgA31qBsTjkJy7VR17cxc5TTWfIt++jG7L/gdqsUY16pRFh5v6dwS6tM7l qa50f4fuDHgN0uYSF4jlMcWi6ztnJ62NINAupkWvHL5AZ8fB0HXMWJWywYVz3WBe+BOQ N9SQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=8BQPpG+3m3zlQjCedXL4TLxfC44XScnWSwe0bfqb+Ss=; fh=HLo0AAMo83BV5zY+dvYCpl8RaUhI1YKkvmKdzHKqObY=; b=TnmdRUzmltUsKjmTC2FNDK/5Hqv+PSKgi8j4ySLwcM/A4zl+7E+bDFGLxYdDy7nyER l7ezRjT7OlcldD1RtitVv/D47ImU8V/ijgj9fM7EtG/tnyGzO6+7w2pSngRj+FZRZlPm eE8EOvWOJbw9QMVFZqkS2G3x1pAKvV5P/zWwGLegaNPWOSQ9TgG3rvo1/C44PzrwMgO8 SJFwCnFvIiY85sUsOmrPUf83R0OLljRC0TnNR+8YxXAXdsbKfVBut2tWsVDallWjkqxs ketvOFRPI5BHbvV+I8EmBXGBivBt7qa33ti9p43RzzOxOrSlnxppJ6JlxDQch3EX2rZk qtRg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=O6AIzRjj; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-99930-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-99930-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id u6-20020a170902bf4600b001dd63e221cfsi6242296pls.651.2024.03.12.00.58.19 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 12 Mar 2024 00:58:19 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-99930-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=O6AIzRjj; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-99930-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-99930-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=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 sv.mirrors.kernel.org (Postfix) with ESMTPS id 60D662817EC for ; Tue, 12 Mar 2024 07:57:42 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 4C8576997C; Tue, 12 Mar 2024 07:57:36 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="O6AIzRjj" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 74E26B657; Tue, 12 Mar 2024 07:57:35 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710230255; cv=none; b=Ji2lNjrOuLj2rb4OY5/Sy3hzgrfPzH58ajT5Bv3b+YG/eNrN6ct1kOJTELwm0lZM8umnYCTgUMbqMCjgsi7ySq9DNKbamPGt+NaeFKax5DcSgaz3RkU2oEc+HVsOw6KC+CoPf2KIBycSJfcnL0rCG3+dELUoNSORzhbUYEuKFLw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710230255; c=relaxed/simple; bh=VG3pR068UJKv/7BHxkzXJWO/gG7U9/48TQUtXnKKh4w=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=da0hAO2gBvwI2GBZPRIBbYWGXWhwa4ixUeNbZHKOSpFrVQwXEh1PTDgTW/HbPGYVJmCnR2GGG1N3pgJuMlRW+R/3xJiXm3oLjiTlPb7OW3zkwIkFRiCecPQo33aSjqgzzlL0PRSQL8q34KKwCHQnXGvJ2l7hTkCZJqiLKVNU6ss= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=O6AIzRjj; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 48329C433C7; Tue, 12 Mar 2024 07:57:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1710230254; bh=VG3pR068UJKv/7BHxkzXJWO/gG7U9/48TQUtXnKKh4w=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=O6AIzRjjYU9p2QdasGPWZZG7sFgY57p92Rp4xQhMxfvo9XvYQfFW+qrvMvQr/U0Qy OymTnmlEuAlvYqzBltq+aC8sFvuCuTfwhKna2ljxQq90sqzx7pULbG+qdsf0vnOuCf WGitSaCK/f/h+pTFXCvrLqd2XW9FuktDaX8f37JlXeQTMSWsnXX7MaztYH6VUUF40F 27ljsJAT72yNi2cAufQkMYKUm5FFOc45i6N9duf0WwydrTiky6r3MeHB8eMXlA9bMU ZuzeJBtpYxZUkN5pyOI41GlDJTqDtyNcbAYjegkwWL63rQQxz5I7RTlfl6YNB0TzTN 7Kw5ICwHKgnLQ== Date: Tue, 12 Mar 2024 09:57:30 +0200 From: Leon Romanovsky To: linke li Cc: bmt@zurich.ibm.com, jgg@ziepe.ca, linux-kernel@vger.kernel.org, linux-rdma@vger.kernel.org Subject: Re: [PATCH] RDMA/siw: Reuse value read using READ_ONCE instead of re-reading it Message-ID: <20240312075730.GN12921@unreal> References: 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: On Tue, Mar 12, 2024 at 09:30:53AM +0800, linke li wrote: > Thank you for your reasonal reply. That makes sense. But you may still > consider to make it better, like this patch, to read the flag only one > time. It will avoid some potential risks. However, it depends on > maintainer's choice. Maintainer doesn't see any potential risks and value is read only once anyway. Thanks > > Linke > Thanks > >