From patchwork Mon Oct 12 20:24:49 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gregory Rose X-Patchwork-Id: 1381134 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=openvswitch.org (client-ip=140.211.166.138; helo=whitealder.osuosl.org; envelope-from=ovs-dev-bounces@openvswitch.org; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20161025 header.b=UlSTy6qF; dkim-atps=neutral Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4C99Cn3NDsz9sTL for ; Tue, 13 Oct 2020 07:25:25 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id E865186C19; Mon, 12 Oct 2020 20:25:23 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 5GsPf7wKdLz6; Mon, 12 Oct 2020 20:25:20 +0000 (UTC) Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [140.211.9.56]) by whitealder.osuosl.org (Postfix) with ESMTP id 9C27B86BD6; Mon, 12 Oct 2020 20:25:20 +0000 (UTC) Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id 3745DC1AD8; Mon, 12 Oct 2020 20:25:20 +0000 (UTC) X-Original-To: dev@openvswitch.org Delivered-To: ovs-dev@lists.linuxfoundation.org Received: from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133]) by lists.linuxfoundation.org (Postfix) with ESMTP id 74BF7C0893 for ; Mon, 12 Oct 2020 20:25:18 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id 6246B878D7 for ; Mon, 12 Oct 2020 20:25:18 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from hemlock.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id HPWJxVcbubMU for ; Mon, 12 Oct 2020 20:25:18 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-pg1-f194.google.com (mail-pg1-f194.google.com [209.85.215.194]) by hemlock.osuosl.org (Postfix) with ESMTPS id F078F878C1 for ; Mon, 12 Oct 2020 20:25:17 +0000 (UTC) Received: by mail-pg1-f194.google.com with SMTP id o3so5495635pgr.11 for ; Mon, 12 Oct 2020 13:25:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=zxokFfbwGFrjoasyQvAf1En2ciKBcPVZnAqJXLd49XU=; b=UlSTy6qFf5AATn9HJjP1OPduPdSSKfSHe/9fYMk9yqtftFbsrNUkfW1E4+QWTJ35Qr SJKl6oJIZEmFV+GKyZztZmI+5zuY1YMXtGdvMuBDwe/jl2/hKvwsJiueLkpESRUmOIUf 6N1GqXaeBdLxHy4qBCzVJLo+lq/tVJB6Jl4niY/wAyZbHS3LpdgF1T3kaiKf0Gy0TDCF dTKos+ulVl3l0yHMEfTq2CbJjmm8VT0S5JtWNY09b7YZDDZMR12rdbjoWN4Na6n1Kkwk VwGv7a7wlKqMXh71PlnRHaLyT6aZi4Su4UtbcEaMlVZub0PUm8yf4qUpGbcnPB3Ry/7F EfeA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=zxokFfbwGFrjoasyQvAf1En2ciKBcPVZnAqJXLd49XU=; b=qOBI1cxbzfOh2iEq4QRz6MDOEooZ4bw/mG78zErlSopbSBjMT+dQ6EsD9Jw2EMhyqq 3zL4Kr1AL8u6BDmh2zy+U2RoI0kf4daMtgssvf4vIdMrR9zVySLNz38rLEafpYQpl0I6 zN0U6TOwYu+ZopYSyHpzEK6gPCIQm3FNl+6DQH13qBOlyg3QaZJuvFspXRNO4RlN31no 1hoW//BeGKFAzvzEe6BvqtwwKTwb2XTFwc2AgnRsnMOQdqOykE9LFuS4dWD4x3VmeoPq nZXosYFtz9ZzZH/eBMNz6kTy/vZ2hpZdGcmc9Qj76YIazyd8aTiTjtzwAddjQ+4xIBGA drMA== X-Gm-Message-State: AOAM532GsP7dOLbKnbyNpEFj0hHvle3axa5ve0l+8tfL8WR8yh7uSbwW 1GtEHItPbwzqKoAF+NAQk6S1E3NspA/BTA== X-Google-Smtp-Source: ABdhPJzdkoIM0EMq6FZ1zbWnwrnq9L6TyoEYdMpFH0Mk+bEm4fTg71zfYQS423R/HbGtnG7D76g6dQ== X-Received: by 2002:a62:5f02:0:b029:13c:1611:6536 with SMTP id t2-20020a625f020000b029013c16116536mr24031414pfb.8.1602534317332; Mon, 12 Oct 2020 13:25:17 -0700 (PDT) Received: from VMware-box.domain (97-115-80-55.ptld.qwest.net. [97.115.80.55]) by smtp.googlemail.com with ESMTPSA id w135sm11384421pfc.103.2020.10.12.13.25.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 12 Oct 2020 13:25:16 -0700 (PDT) From: Greg Rose To: dev@openvswitch.org Date: Mon, 12 Oct 2020 13:24:49 -0700 Message-Id: <20201012202511.21000-3-gvrose8192@gmail.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20201012202511.21000-1-gvrose8192@gmail.com> References: <20201012202511.21000-1-gvrose8192@gmail.com> Cc: Enrico Weigelt Subject: [ovs-dev] [PATCH V4 02/24] datapath: drop unneeded likely() call around IS_ERR() X-BeenThere: ovs-dev@openvswitch.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: ovs-dev-bounces@openvswitch.org Sender: "dev" From: Enrico Weigelt Upstream commit: commit b90f5aa4d6268e81dd1fd51e5ef89d2892bf040d Author: Enrico Weigelt Date: Wed Jun 5 23:06:40 2019 +0200 net: openvswitch: drop unneeded likely() call around IS_ERR() IS_ERR() already calls unlikely(), so this extra likely() call around the !IS_ERR() is not needed. Signed-off-by: Enrico Weigelt Signed-off-by: David S. Miller Cc: Enrico Weigelt Signed-off-by: Greg Rose --- datapath/datapath.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/datapath/datapath.c b/datapath/datapath.c index d604bfd36..4c485c88a 100644 --- a/datapath/datapath.c +++ b/datapath/datapath.c @@ -1402,7 +1402,7 @@ static int ovs_flow_cmd_del(struct sk_buff *skb, struct genl_info *info) &flow->id, info, false, ufid_flags); if (likely(reply)) { - if (likely(!IS_ERR(reply))) { + if (!IS_ERR(reply)) { rcu_read_lock(); /*To keep RCU checker happy. */ err = ovs_flow_cmd_fill_info(flow, ovs_header->dp_ifindex, reply, info->snd_portid,