Received: by 2002:a05:6a10:a852:0:0:0:0 with SMTP id d18csp1603297pxy; Thu, 6 May 2021 11:12:51 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz07sSh/SFz5zFxzGk8EsDmZkjlYY7HLxk10PH+Us2FXRRs8qyjoqM/hBlfOyPe3VOmEdMH X-Received: by 2002:a17:90b:194:: with SMTP id t20mr6148010pjs.83.1620324771017; Thu, 06 May 2021 11:12:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1620324771; cv=none; d=google.com; s=arc-20160816; b=0dxvnYo5OB04Rv2t1fBMmbyBti/IUbtfzrgHDp/p/1s0sB6NxQxLTNz6kfmPSZceNS l4x7w+uwb1mAb1blLysazw7wQ9lXGrlnS55D+GmSkrd1UABbTobfueYKA03ZCnrQtbtl RpSuPDyr/gOXL2SNleywxaxvGbPMzAordW+t+sEHyz+YQ8dCE2toHs1USvqXKz1AKcA3 JixMFgXJErtOn9+SkNnp7/X1RegqRYecUpXDtd2nPgcKi4vrYgH/dWHtovrhD82lJQBv tBUF5c1GOBiNw6SErAdNoWLCRVj3TR4Sqef3ox+DropKa8ngl6Gq9V/W+49PMk8q8v6G SYuQ== 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:dkim-signature; bh=DFmbax4y9IzWoN/+ll3PqZArDK71jo3wwCexRT9IW9g=; b=qOmvMWf2OzA1UuYIE8BkdN5rugFCDhocByMMmpjII/DUr/ZGiZzKNTE4Muhc9MJ4UG AwDvIZTf2aUhJ2CE5VOQr5C/Jyo9K8Y3nlT7S+36hb+REsb6RSlgBgENkl8DNiPQV30+ mHqc42hNWa9kTurI1o7RxHz8HFvZpBC0OSAOS02vFThFDqq6pnOyXf/qbUtYkoU+tWjm mYeD5pvIdahZl0FQS0SziR17v9uefHKIgWqOXYc44r1dG/xSN8mpI3Fsv9PaSYO00rd3 MiBIM31DfsHKfDYvJMdf27z2jdItXj24yc9TZcPnhm198djuNCUpaPsilIg7HzQku9jm HI/Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=N8F9gJR4; 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 y1si3832224pfe.228.2021.05.06.11.12.37; Thu, 06 May 2021 11:12:51 -0700 (PDT) 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=@kernel.org header.s=k20201202 header.b=N8F9gJR4; 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 S234819AbhEFLfa (ORCPT + 99 others); Thu, 6 May 2021 07:35:30 -0400 Received: from mail.kernel.org ([198.145.29.99]:41602 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234603AbhEFLf2 (ORCPT ); Thu, 6 May 2021 07:35:28 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id A241E61157; Thu, 6 May 2021 11:34:29 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1620300870; bh=8/cRQsRVgB8StZWU9Xp8Xr8DXDhLO/Z29n+TRUw5MM8=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=N8F9gJR4X/sfeZY6WomvCBM0VWYm8O4yGQw3tvVP74DVD98XCOTx36h+nprSmXrQT 5Kl5evgRcsp1qP3hpvD4WPEvBIaey4PkCQy9V7vU728w7v5OEvDsIXUQojOC7LECzl 67Uu05lft0nRp4ycSd4H05pQQfYtKKq/jNVX9wQrTScltBoGJ3aD96jWjizoN6MVhE ruawG2onLNW9xnvJ+1az9K5tRLXB7t4aeRw97fYn77mbu5CV0W3epRjt/iez83rIQo BDHVbOA9FFTZYrQg+evX4poLXZiseOTsGCmvnRkF0hXvlDfx52cWXzY8oygGAGc1LH YgSWyHy7uFniA== Date: Thu, 6 May 2021 14:34:26 +0300 From: Leon Romanovsky To: Yang Li Cc: bvanassche@acm.org, dledford@redhat.com, jgg@ziepe.ca, nathan@kernel.org, ndesaulniers@google.com, linux-rdma@vger.kernel.org, target-devel@vger.kernel.org, linux-kernel@vger.kernel.org, clang-built-linux@googlegroups.com Subject: Re: [PATCH] ib_srpt: Remove redundant assignment to ret Message-ID: References: <1620296105-121964-1-git-send-email-yang.lee@linux.alibaba.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1620296105-121964-1-git-send-email-yang.lee@linux.alibaba.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, May 06, 2021 at 06:15:05PM +0800, Yang Li wrote: > Variable 'ret' is set to -ENOMEM but this value is never read as it is > overwritten with a new value later on, hence it is a redundant > assignment and can be removed > > In 'commit b79fafac70fc ("target: make queue_tm_rsp() return void")' > srpt_queue_response() has been changed to return void, so after "goto > out", there is no need to return ret. > > Clean up the following clang-analyzer warning: > > drivers/infiniband/ulp/srpt/ib_srpt.c:2860:3: warning: Value stored to > 'ret' is never read [clang-analyzer-deadcode.DeadStores] > > Reported-by: Abaci Robot > Signed-off-by: Yang Li > --- > drivers/infiniband/ulp/srpt/ib_srpt.c | 1 - > 1 file changed, 1 deletion(-) > Fixes: b99f8e4d7bcd ("IB/srpt: convert to the generic RDMA READ/WRITE API") Thanks, Reviewed-by: Leon Romanovsky