Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp4638527pxu; Thu, 10 Dec 2020 01:27:11 -0800 (PST) X-Google-Smtp-Source: ABdhPJxcVp/QVnyfCfvb7FQCVJQs+QP1z1PupWT5WRd44DMzPRVW3fcPNhj777TIJYWretkOC2iU X-Received: by 2002:a50:f404:: with SMTP id r4mr5854694edm.62.1607592431482; Thu, 10 Dec 2020 01:27:11 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1607592431; cv=none; d=google.com; s=arc-20160816; b=MRZvsIa5CK/BNJxUJFOyRgL7+Le8WHfTlmCJXRvLNgyoB+FlyOZxqeNc78tI5rGJhs JEpNlpB11rgdsO1X112oHWKG5OL2CWmHXmO77QFu5JYeWHrSDJzQb8gk9dXjPsXuDCcU XWkqzCB8KWgfjPnqFvsbb7VUYERgskMAkETWWBJ3TYDSzeNO9J4o73iS17G1afyT1UyE xx+JjwJhnFOXi6cWjedTeUDGC5tNyebotLZfl30To5fUt79eWdcRl9oOlVK8ZsxV3PY9 jJHbeKaiTIPM8EbPIcWgsPVb75U01LVmdFehU7hWUK7JNPYzzXi2/ZcLp0YtNq+Q7Eva mZ4g== 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=r6lp+Pd4hidB7FApVq1A+9XwHVpp98S1slrRe/+RTec=; b=gEpwD+fYeG1e1MmeLrdi5iarA9vB6sjxTuNLqSH3PeFg7jAdxtM9HFwSn3Yp7KnIIu k2PsVQwT880LlMlQfd5MC30/HozASQtNDz0/2WSal+Qv40TJR8jg9EY0FoHY1JMmRLyY hc76/O9ORJz3PXQo9cu+iO30Mr5290r0Ybgid/EFC8gaW8ZQPfeIrK122LNtgJbjoR5X SkaI8LPOBmDTL2V02XjvwKkg2XV3yZYXn37CfLXP4fHxGHuBw5VeAUpYrMiQcXx6HBhI D7G+8fKZG1uKoWEKooHcQiqJqTu+sudixP9hZMzHDq5y65H84Kr178ANid9ZDe402rZL BxZA== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id g16si2634188ejf.689.2020.12.10.01.26.49; Thu, 10 Dec 2020 01:27:11 -0800 (PST) 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731643AbgLJJY3 (ORCPT + 99 others); Thu, 10 Dec 2020 04:24:29 -0500 Received: from s2.neomailbox.net ([5.148.176.60]:18647 "EHLO s2.neomailbox.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728273AbgLJJYV (ORCPT ); Thu, 10 Dec 2020 04:24:21 -0500 From: Antonio Quartulli To: Jakub Kicinski , netdev@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Antonio Quartulli Subject: [PATCH] vxlan: avoid double unlikely() notation when using IS_ERR() Date: Thu, 10 Dec 2020 09:55:49 +0100 Message-Id: <20201210085549.22846-1-a@unstable.cc> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The definition of IS_ERR() already applies the unlikely() notation when checking the error status of the passed pointer. For this reason there is no need to have the same notation outside of IS_ERR() itself. Clean up code by removing redundant notation. Signed-off-by: Antonio Quartulli --- drivers/net/vxlan.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/vxlan.c b/drivers/net/vxlan.c index e1e44d68ac4b..a8ad710629e6 100644 --- a/drivers/net/vxlan.c +++ b/drivers/net/vxlan.c @@ -2477,7 +2477,7 @@ static struct dst_entry *vxlan6_get_route(struct vxlan_dev *vxlan, ndst = ipv6_stub->ipv6_dst_lookup_flow(vxlan->net, sock6->sock->sk, &fl6, NULL); - if (unlikely(IS_ERR(ndst))) { + if (IS_ERR(ndst)) { netdev_dbg(dev, "no route to %pI6\n", daddr); return ERR_PTR(-ENETUNREACH); } -- 2.29.2