Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp2253641rwd; Tue, 13 Jun 2023 23:33:36 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7GnYY2ov+BhYHP82bRyRTj9gIM9kzoq5XHuVkZuWHdRwULFGFgiirfMinZ6S4L3SYKfkN2 X-Received: by 2002:a17:907:94ca:b0:973:ad8f:ef9b with SMTP id dn10-20020a17090794ca00b00973ad8fef9bmr14306530ejc.5.1686724415807; Tue, 13 Jun 2023 23:33:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686724415; cv=none; d=google.com; s=arc-20160816; b=j5nv36U1RmUHyiGpA42/TZWzVIOtNmsQ59QJnxPeEonaOor63sFKDXSX0U9+lbH5bJ MWHqmGeodoDUGSKI+gCXCG+bEHokJca8LmpogHtzaxNuSyCyG/thrJ+Oj+BMxEzobQI/ 962Gw10Nlql9txxYjktwPPmQJFU6OKi8r/4nxtBGY9z7+YnB4B2Ef4OTeM6+G524ACq+ 4J9oJ/en7UwPX6X7f3b3yXy9+4TCPg/bW/cAU1xU4JomeIMhu+E6BDVMfJq77mtZ6e+N gSQXr+y0L8WJuOxK8zSQoSFkZimCIsH+qiHr6S8+6N11nwKV61LHD7eF5x6tb5mg4Oro h+3A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:message-id:user-agent :references:in-reply-to:subject:cc:to:from:date:mime-version :dkim-signature; bh=0tIIYbNhvYGqcKYQ6uZEPjIYPd7Beormj8SX1/5Jw9I=; b=wFKrCT35T0oS2IcCCOADYohYSuGHsU7RdafYlBqvRvNHLi45XS5wtZ0GAsh27q27/2 lJvlT5/w3w1e9M5NKMzJIOpJN3j+kE4KRXcoCzqj3R2sHMYfDXiQ18wAPs+Gzhb2ev3R H/pOa2hBN27i0aGiBM8oGCQVtlx1VytCHnv47c9AgCCzH9N8xSWT2koahH6B4T9yAk4d 6fgwGH8YsCkSVMH4ZGKB0kRXYjPHilLDjK3jljlNDMth2qyCPaTlgVLNmZ2hKtjJtF63 eXWa6KRvUW49Xbdr8tvUBteX5o71xSgwvnv1E9ajKR/8D7UvdRqSOyuHu34ZJokZ4c8s mUsA== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (bad version) header.i=@208.org header.s=dkim header.b=NbQNkOjN; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id i7-20020aa7c9c7000000b00514b2a9ce5csi7899106edt.11.2023.06.13.23.33.10; Tue, 13 Jun 2023 23:33:35 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=neutral (bad version) header.i=@208.org header.s=dkim header.b=NbQNkOjN; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S243149AbjFNGaK (ORCPT + 99 others); Wed, 14 Jun 2023 02:30:10 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42810 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S243148AbjFNG3f (ORCPT ); Wed, 14 Jun 2023 02:29:35 -0400 Received: from mail.208.org (unknown [183.242.55.162]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 178121FDD for ; Tue, 13 Jun 2023 23:29:27 -0700 (PDT) Received: from mail.208.org (email.208.org [127.0.0.1]) by mail.208.org (Postfix) with ESMTP id 4QgwW86gX5zBR9Zh for ; Wed, 14 Jun 2023 14:29:24 +0800 (CST) Authentication-Results: mail.208.org (amavisd-new); dkim=pass reason="pass (just generated, assumed good)" header.d=208.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=208.org; h= content-transfer-encoding:content-type:message-id:user-agent :references:in-reply-to:subject:to:from:date:mime-version; s= dkim; t=1686724164; x=1689316165; bh=klrFd4m/LXdoMGxRTnZu0esLRgA FT+1tJ+pjxp3tsB0=; b=NbQNkOjN3Hq7r4uDFUsqSI0dVzvCb0dk9hFctJvCWeI VXqOfnKaqGYIGG9xNCXNZ79dQ42LreK1K+PhVYD3u/hvME+RJ7yd0P0FzlzA+xPt fzn39gnuhe+hXIaF+/usVbkaT1WIDc1Bi9XDZLyg7pVvn0BLayxd2cw1IWmVZsEj crIhkkzGgSMonolTPg9qxR4+7zMTsRSdKhqL32i/9xI4Gwz/reWxWzk4W/cHK4uq izPgoW6ICqgL+P6uA+dpIGaIUpLhFahe72fCB/nKxtTsmZWu/VF8K8p8wb1+EDVf NMK6eAgG7BzeXQTSRnM4yxGvup86iKecCEmY7KU5ZhA== X-Virus-Scanned: amavisd-new at mail.208.org Received: from mail.208.org ([127.0.0.1]) by mail.208.org (mail.208.org [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id kSEH0qrAKzEz for ; Wed, 14 Jun 2023 14:29:24 +0800 (CST) Received: from localhost (email.208.org [127.0.0.1]) by mail.208.org (Postfix) with ESMTPSA id 4QgwW83Nz8zBQgpC; Wed, 14 Jun 2023 14:29:24 +0800 (CST) MIME-Version: 1.0 Date: Wed, 14 Jun 2023 14:29:24 +0800 From: xuanzhenggang001@208suo.com To: davem@davemloft.net, dsahern@kernel.org, tglx@linutronix.de, mingo@redhat.com, bp@alien8.de, dave.hansen@linux.intel.com Cc: x86@kernel.org, hpa@zytor.com, bpf@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] bpf: Remove unneeded variable In-Reply-To: References: <20230610124403.36396-1-denghuilong@cdjrlc.com> User-Agent: Roundcube Webmail Message-ID: X-Sender: xuanzhenggang001@208suo.com Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-0.9 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,RDNS_NONE,SPF_HELO_FAIL,SPF_PASS,T_SCC_BODY_TEXT_LINE, URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Fix the following coccicheck warning: arch/x86/net/bpf_jit_comp32.c:1274:5-8: Unneeded variable: "cnt". Signed-off-by: Zhenggang Xuan --- arch/x86/net/bpf_jit_comp32.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/arch/x86/net/bpf_jit_comp32.c b/arch/x86/net/bpf_jit_comp32.c index 429a89c5468b..bc71329ac5ed 100644 --- a/arch/x86/net/bpf_jit_comp32.c +++ b/arch/x86/net/bpf_jit_comp32.c @@ -1271,7 +1271,6 @@ static void emit_epilogue(u8 **pprog, u32 stack_depth) static int emit_jmp_edx(u8 **pprog, u8 *ip) { u8 *prog = *pprog; - int cnt = 0; #ifdef CONFIG_RETPOLINE EMIT1_off32(0xE9, (u8 *)__x86_indirect_thunk_edx - (ip + 5)); @@ -1280,7 +1279,7 @@ static int emit_jmp_edx(u8 **pprog, u8 *ip) #endif *pprog = prog; - return cnt; + return 0; } /*