Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp56559imm; Thu, 30 Aug 2018 15:38:52 -0700 (PDT) X-Google-Smtp-Source: ANB0VdbNqCcP0Lxf4ycS9BhZyD4J+V4sgpV0SL/5zsSa6K1nZqyQgq4V5QJpc9879MjGmfAI6DbH X-Received: by 2002:a17:902:b03:: with SMTP id 3-v6mr12138020plq.277.1535668732767; Thu, 30 Aug 2018 15:38:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1535668732; cv=none; d=google.com; s=arc-20160816; b=Sjkvx/ILd/6GOMAo2a0L44UlrsO82yhV8hyx1T03YeE3h5DX9yva5UTWTpKYywt8N5 GKY96WMwFAbkjPbtqLHjlonmIVBBNWWVyalfBxLgYPFC4DWK+0wJaTZjJWa/qfAV4JS+ SVRzdct4ai+7BaGG66BIP8lVIsUFN1YtRmbjjnVQYQYciLjnOkMomqmjsToK+YvVfex4 GG5octJb8VjS5WRwnMgYeUciceY6FN41lngO72VpoburfgQN39U+xg0vKBjSxmDMxoVf Tes31hr4ciM2+A79bbzWRc1OhZxFLBr7kNofGu53HekXHQbBrLOezO7y+WZd0i9iHGVx 4Thw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=ad/qa269HNpm8MVJTVwUlQl2wkw5HCg3jKISnC9C3BM=; b=sLqXTZc4NICzkKR+WlDCeWXGzn4f7AQxPMw0tOg28XbE7oRXV8V1xGmBK5iawLrKbI SkzMvHXkR4K0wRT0vWi1LGSN+rXrLxK4nHU3yLqROs0N3KEok3zqOtECl3mYvZpKKslN oz4zsZ8e0+TPfH2lqpjoGdahZ4ut29SuNhSBO7QMjPTnYCxWpfc1z9OUBOahon/fialA WNYr61BrDvC57SRcncU2jFGy/ezWHVRxZ5T+kXWcnLiKtSrROx0s2pbWLc20u2yeNsTu IWQQqeLutLRmIdf6mHeQymtiySms9tf4iPQD3I8cTH2m1/h3yU33pTssxYMiwOuVe1zX PICA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=gd2Ezfdh; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l2-v6si7987667pfb.69.2018.08.30.15.38.38; Thu, 30 Aug 2018 15:38:52 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=gd2Ezfdh; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727826AbeHaCk1 (ORCPT + 99 others); Thu, 30 Aug 2018 22:40:27 -0400 Received: from mail-lf1-f65.google.com ([209.85.167.65]:41618 "EHLO mail-lf1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727235AbeHaCk0 (ORCPT ); Thu, 30 Aug 2018 22:40:26 -0400 Received: by mail-lf1-f65.google.com with SMTP id l26-v6so8467623lfc.8 for ; Thu, 30 Aug 2018 15:36:01 -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=ad/qa269HNpm8MVJTVwUlQl2wkw5HCg3jKISnC9C3BM=; b=gd2Ezfdh2gsdpaNkN7ssXItLtEtVxsZgxz1kIQZowSH3IeRRTwmP+l6/RkVtdZspcv kSHa7LIvjeBZpO9GSXWIMKM5vhOdb7vsTapIVCRCkXz0Fnilwp2A1TxtpVV34TMdAMhK 4uWa7nrEAs8YkWkkHBeG4Y+WGUPLL1alrbOdRS+7jE6s70Itce/m61M2wdJqTdIV9mN6 83DCCXBDWjKtyM5WLLL+O9P0PeFqwQ+XKHnKS+WOWWco4AyCoSKs1QAILBV9swvDmHNt FerrWuR7n24jpAnKYGkQPx4v9HgRUrwTiDlvTiJD9pOBjWVIZRWDBBup1R38mS7il7LU KOHw== 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=ad/qa269HNpm8MVJTVwUlQl2wkw5HCg3jKISnC9C3BM=; b=Lm8xasQlE+QGM68UsBdVPczgS/X9ejq7V/bS6AnK5FwAwYIoAMz13IMTuEZMah09qc qzCrxjgPBNygxKg24U91CKfEAJAccxvGn8SuWlBKoUKi8gy78rbePpNNTiIe+xxs+/de HrRMIIg1mUNBP1ghoa0QJt/1TgNDWrkmKJdMB80bbpueiJSySG0g0/GLwc8uRN1Uplwx vjB/e3E/tlfLqtO7tmbNQ1jI01hpS1dhpA+VmN0s3HAYg/nUbrIajV/1EcAt0lep1l3h fV96i9FiQD1FTvhxo/Loh9SuYTGwU3Psh1pUu81eK1q++eLVQaLZGpVkXOWsYLKtki23 Hd2A== X-Gm-Message-State: APzg51DANWyXHlCGxPDfdprIfLkwiaahPaSTxYyz38P8EYuX5bEmHyat wa73EyOIoo1KK4akpYBIAl1ciINNyn8= X-Received: by 2002:a19:944d:: with SMTP id w74-v6mr8485818lfd.10.1535668560502; Thu, 30 Aug 2018 15:36:00 -0700 (PDT) Received: from Mort.jumbo.freeair (91-159-62-202.elisa-laajakaista.fi. [91.159.62.202]) by smtp.gmail.com with ESMTPSA id u28-v6sm1455376ljd.61.2018.08.30.15.35.59 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 30 Aug 2018 15:35:59 -0700 (PDT) From: Igor Stoppa X-Google-Original-From: Igor Stoppa To: linux-kernel@vger.kernel.org Cc: igor.stoppa@gmail.com, Igor Stoppa , Arseny Solokha , Benjamin Herrenschmidt , Paul Mackerras , Michael Ellerman Subject: [PATCH 22/23] powerpc: remove unnecessary unlikely() Date: Fri, 31 Aug 2018 01:34:28 +0300 Message-Id: <20180830223429.30051-23-igor.stoppa@huawei.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20180830223429.30051-1-igor.stoppa@huawei.com> References: <20180830223429.30051-1-igor.stoppa@huawei.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org WARN_ON() already contains an unlikely(), so it's not necessary to wrap it into another. Signed-off-by: Igor Stoppa Cc: Arseny Solokha Cc: Benjamin Herrenschmidt Cc: Paul Mackerras Cc: Michael Ellerman --- arch/powerpc/mm/tlb_nohash.c | 2 +- arch/powerpc/sysdev/xive/common.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/powerpc/mm/tlb_nohash.c b/arch/powerpc/mm/tlb_nohash.c index 15fe5f0c8665..46f5d8c972fb 100644 --- a/arch/powerpc/mm/tlb_nohash.c +++ b/arch/powerpc/mm/tlb_nohash.c @@ -302,7 +302,7 @@ void __flush_tlb_page(struct mm_struct *mm, unsigned long vmaddr, * This function as well as __local_flush_tlb_page() must only be called * for user contexts. */ - if (unlikely(WARN_ON(!mm))) + if (WARN_ON(!mm)) return; preempt_disable(); diff --git a/arch/powerpc/sysdev/xive/common.c b/arch/powerpc/sysdev/xive/common.c index 959a2a62f233..7dde46b38979 100644 --- a/arch/powerpc/sysdev/xive/common.c +++ b/arch/powerpc/sysdev/xive/common.c @@ -442,7 +442,7 @@ static void xive_dec_target_count(int cpu) struct xive_cpu *xc = per_cpu(xive_cpu, cpu); struct xive_q *q = &xc->queue[xive_irq_priority]; - if (unlikely(WARN_ON(cpu < 0 || !xc))) { + if (WARN_ON(cpu < 0 || !xc)) { pr_err("%s: cpu=%d xc=%p\n", __func__, cpu, xc); return; } -- 2.17.1