Received: by 2002:a05:6a10:a841:0:0:0:0 with SMTP id d1csp4373504pxy; Tue, 27 Apr 2021 03:36:55 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyitJoEj8QF9Pm1fQt9ElmrDDCkyFuTVBeINDQqEXNN/3m4Jb+7qCbod/nDnKjKKuREozxW X-Received: by 2002:a17:90b:347:: with SMTP id fh7mr4039961pjb.183.1619519815464; Tue, 27 Apr 2021 03:36:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1619519815; cv=none; d=google.com; s=arc-20160816; b=WcARY9ESvrxaOcCqvam4L1zqdn80uM/0XiDV113xPmChv8O3b+5BpqeTTjIIU995JC a3gX7i/F/dfyqgchM9whi/JGhXRXgu6Q08MaOcHd+QXzHYJ0C15FRJ5mgX/SyfEN6i60 7kUrBp4kb8LWijpcFcFlS5zkAQaC4NBxyuAIdIKuvy81zXsBPxIhZyk3PozfsmjqZ67O 69IMuhi+S2rlfQMnO/9d5R6PaVIRxZq9i2/9M31jBnAvrdAiM1BxdT7xbpxhKl7PEW8N HNjDopvRMLGEx4yzpN2APn1uQJM5QI7ymeMp9gHUb+UwYIGWa0m5q/hPEO0BFvptPVnW vEHw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:date:subject:cc:to:from; bh=V4/WxYeZ95D0zmGL6j3wh4rl5nmrOsHEfDA6TudbOXY=; b=tKLdOagp2Bx8AD+BPfo3ohv42Lji0ZgsKOTvDEb+dN9XhRXu5UbHNzmvQ/A5U4MphU xXKjBS0QrczTaT179uBylvVEHyvvO3FtBN/BYycfiZf6sQBLKv0vBioni/Dk9envtdKC CcW54rbbbk3DUWCmnz3Mb1T3N7stvw8/kmkyqztjJmYuqmYFDMTO1iZ1blh1wj7TqNGG bxFds5ueAHjhfoiBbgqvmXnYJ0KtxL1HDqZ3WZ5tZqFB08NIZ0vU4P7dx/rUpAldG6qj 6ZJI2wvqbYO2uGKSKw++zpNy2vHWQJqSymsyAs85xb/5EVFTVaL0fAL4I2yxWeL4c14o eZ5Q== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id y128si3065218pfb.155.2021.04.27.03.36.43; Tue, 27 Apr 2021 03:36:55 -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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235443AbhD0Kfi (ORCPT + 99 others); Tue, 27 Apr 2021 06:35:38 -0400 Received: from out30-132.freemail.mail.aliyun.com ([115.124.30.132]:60266 "EHLO out30-132.freemail.mail.aliyun.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238407AbhD0KdO (ORCPT ); Tue, 27 Apr 2021 06:33:14 -0400 X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R191e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=e01e04420;MF=jiapeng.chong@linux.alibaba.com;NM=1;PH=DS;RN=7;SR=0;TI=SMTPD_---0UWzqAtW_1619519543; Received: from j63c13417.sqa.eu95.tbsite.net(mailfrom:jiapeng.chong@linux.alibaba.com fp:SMTPD_---0UWzqAtW_1619519543) by smtp.aliyun-inc.com(127.0.0.1); Tue, 27 Apr 2021 18:32:29 +0800 From: Jiapeng Chong To: kgraul@linux.ibm.com Cc: davem@davemloft.net, kuba@kernel.org, linux-s390@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, Jiapeng Chong Subject: [PATCH] net/smc: Remove redundant assignment to rc Date: Tue, 27 Apr 2021 18:32:22 +0800 Message-Id: <1619519542-62846-1-git-send-email-jiapeng.chong@linux.alibaba.com> X-Mailer: git-send-email 1.8.3.1 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Variable rc is set to zero 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. Cleans up the following clang-analyzer warning: net/smc/af_smc.c:1079:3: warning: Value stored to 'rc' is never read [clang-analyzer-deadcode.DeadStores]. Reported-by: Abaci Robot Signed-off-by: Jiapeng Chong --- net/smc/af_smc.c | 1 - 1 file changed, 1 deletion(-) diff --git a/net/smc/af_smc.c b/net/smc/af_smc.c index 47340b3..be3e80b 100644 --- a/net/smc/af_smc.c +++ b/net/smc/af_smc.c @@ -1076,7 +1076,6 @@ static int smc_connect(struct socket *sock, struct sockaddr *addr, rc = -EISCONN; goto out; case SMC_INIT: - rc = 0; break; } -- 1.8.3.1