Received: by 2002:a05:6358:1087:b0:cb:c9d3:cd90 with SMTP id j7csp4207608rwi; Mon, 17 Oct 2022 03:07:49 -0700 (PDT) X-Google-Smtp-Source: AMsMyM7IkKNMGUd8KOWVMqBG0vnADOqdZrofoG/RkiqIda9z2dQ+Vd5WoOtM/bNLEGCnl582gXOn X-Received: by 2002:a05:6402:2074:b0:458:ad26:d5c2 with SMTP id bd20-20020a056402207400b00458ad26d5c2mr9911732edb.332.1666001269688; Mon, 17 Oct 2022 03:07:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666001269; cv=none; d=google.com; s=arc-20160816; b=vSxl9y68wJKHGDBwey31EB/wqybYN45DrOyxBuZvkpC84GE8wJ6OxahMID+/aRwxkb YcF/ChcVI9FwOaCYrc6UXWTxIC9LZvAzhgTNNC7ROM9uwpCBV8rjuZSM2vcoaNs8ov8B 7+O1PKnfISX3QVetJItQ9C5OmfJeeYKe0JN+CNopgqXk9oucs1LZNbR9KaC+rnKXprjS GOV+/whM1GvX3ylB19LFnkDdzsFaa6di6XPxT1JZ/W8bno9X8cWWc2BpdpM6S/PWL7S0 JUE7u0meqRfdjZfqu33ckdqVtUmU6DHwYqwGvgA8CAZp0QfQZ5YI9q18zwMPU0CLl1ra +v4w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=9Dzojg+mTK9LQagAswcL3BxA0xvojE4AhZkQz6Vsz3Y=; b=yakQsPooTXvBH9/OMgJVBfpufyxh1wlq7TEfAC5XNNcB8lNDBG+N8T9V7Cq7DrNvDb 2GjW6tMH43l4Ig4Y4qn+zq+qDEAF/gTip1M2j9lntAYbXQ5umn8OoRDT5AfOL2VnUWJS sKMA+yX9M0ulIGTFj97D80kblJH+CFSkcNio8i1SxTBp75mOIgMpzHdU5SDMOdAhQYO/ DmXNbAgnU7O9KT4DJdRTLhbRFmt8j/UQbtMLbDKSCfP2taItYOpUa6jN3o4ipjW5ahox AkJC0/z3R3dqtcVEaN3weJxWJ3klhetZa1gNdfukab6fwzhVD/ptucGVNiI5hSEFVdVD xhDA== ARC-Authentication-Results: i=1; mx.google.com; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id e10-20020a170906504a00b0078210c21ecesi7587577ejk.304.2022.10.17.03.07.23; Mon, 17 Oct 2022 03:07:49 -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; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231246AbiJQJgM (ORCPT + 99 others); Mon, 17 Oct 2022 05:36:12 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58024 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231354AbiJQJgB (ORCPT ); Mon, 17 Oct 2022 05:36:01 -0400 Received: from out30-43.freemail.mail.aliyun.com (out30-43.freemail.mail.aliyun.com [115.124.30.43]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DDFC81C401; Mon, 17 Oct 2022 02:35:58 -0700 (PDT) X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R151e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=ay29a033018045176;MF=jiapeng.chong@linux.alibaba.com;NM=1;PH=DS;RN=10;SR=0;TI=SMTPD_---0VSLqolQ_1665999342; Received: from localhost(mailfrom:jiapeng.chong@linux.alibaba.com fp:SMTPD_---0VSLqolQ_1665999342) by smtp.aliyun-inc.com; Mon, 17 Oct 2022 17:35:49 +0800 From: Jiapeng Chong To: davem@davemloft.net Cc: yoshfuji@linux-ipv6.org, dsahern@kernel.org, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, Jiapeng Chong , Abaci Robot Subject: [PATCH] net: ip6_gre: Remove the unused function ip6gre_tnl_addr_conflict() Date: Mon, 17 Oct 2022 17:35:40 +0800 Message-Id: <20221017093540.26806-1-jiapeng.chong@linux.alibaba.com> X-Mailer: git-send-email 2.20.1.7.g153144c MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-9.9 required=5.0 tests=BAYES_00, ENV_AND_HDR_SPF_MATCH,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2, SPF_HELO_NONE,SPF_PASS,UNPARSEABLE_RELAY,USER_IN_DEF_SPF_WL autolearn=ham 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 The function ip6gre_tnl_addr_conflict() is defined in the ip6_gre.c file, but not called elsewhere, so delete this unused function. net/ipv6/ip6_gre.c:887:20: warning: unused function 'ip6gre_tnl_addr_conflict'. Link: https://bugzilla.openanolis.cn/show_bug.cgi?id=2419 Reported-by: Abaci Robot Signed-off-by: Jiapeng Chong --- net/ipv6/ip6_gre.c | 20 -------------------- 1 file changed, 20 deletions(-) diff --git a/net/ipv6/ip6_gre.c b/net/ipv6/ip6_gre.c index 48b4ff0294f6..02b1b54165e8 100644 --- a/net/ipv6/ip6_gre.c +++ b/net/ipv6/ip6_gre.c @@ -870,26 +870,6 @@ static inline int ip6gre_xmit_ipv6(struct sk_buff *skb, struct net_device *dev) return 0; } -/** - * ip6gre_tnl_addr_conflict - compare packet addresses to tunnel's own - * @t: the outgoing tunnel device - * @hdr: IPv6 header from the incoming packet - * - * Description: - * Avoid trivial tunneling loop by checking that tunnel exit-point - * doesn't match source of incoming packet. - * - * Return: - * 1 if conflict, - * 0 else - **/ - -static inline bool ip6gre_tnl_addr_conflict(const struct ip6_tnl *t, - const struct ipv6hdr *hdr) -{ - return ipv6_addr_equal(&t->parms.raddr, &hdr->saddr); -} - static int ip6gre_xmit_other(struct sk_buff *skb, struct net_device *dev) { struct ip6_tnl *t = netdev_priv(dev); -- 2.20.1.7.g153144c