Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp55802imm; Thu, 30 Aug 2018 15:37:26 -0700 (PDT) X-Google-Smtp-Source: ANB0VdaTEZoG6/HkIwBpLEz9OLtDmS41yHL5c1pRrursbvzwiG2BAk1jNwHjItJwUUlNIDXxttgF X-Received: by 2002:a63:b812:: with SMTP id p18-v6mr11568543pge.156.1535668646435; Thu, 30 Aug 2018 15:37:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1535668646; cv=none; d=google.com; s=arc-20160816; b=agaeRGP2CYWKsuxBq+dE0+wHx/+s15r9GNNi3F54HcQg5c33pSRE+ZUrFub/sfI0Hk OKt6jIlD2V0En/Bblfll5ULp72YZ0PYxQr9k6S0PDfKCOHaqcguIz4HjLSvG0WXhwRh/ mT9nkA3AxAYBGWUuyw/DRFONPQ0jxxeJQIK0yz3+PpbTVeCJzBjVyggkUlhF6sTsV9WM oplxCKQpMNHbaVfClvBsIdKfj4xxb9fBL1krGemEuTGAm4vsuK+iviWi4wslEt5zgaTc zVx2M1sOS/nFd/hHW+2b17MO6bTAJzNkL+10FVZ/Btcq7l7zhP/CYPW5kzmSzjUaRKge sdkQ== 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=0CoPjnGDX1qnLOkJ5zdzj0Bi0tX3W2cV1jd68oHh3Lw=; b=PGImej4K2Tp8s+CU08Dcj95gGRXN1v6VZQe5f4eSvPFKbUmfk0LRqt5uWDVxGtmaTk 5jin1xQV1MnQkieKUBs33KRqNQl9GIhZE6hzpd/JMXRTtpfNyYthFDity118qNwEJ3DU cBBhXn9uKmzgZzmJyORCuHiSjEe0VNXilU4ipiybUbsC/zDhCcEGz2m7MIju/yswIb3f znfLWMM7N9UbuSjabOu6e7lb3UyWWQZMxO9TIDwq0JnNJg/gnwy7XJSj4N1/EZvV4PcZ eLJSeu9gTGGrO0QkrosnY1V4/WJUlRfnp8FPoM46BdF7QSl550CSUVN2HiBEOSRjRcCX hNSA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=lMVYhxaU; 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 h12-v6si7617759pll.416.2018.08.30.15.37.11; Thu, 30 Aug 2018 15:37:26 -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=lMVYhxaU; 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 S1727788AbeHaCkT (ORCPT + 99 others); Thu, 30 Aug 2018 22:40:19 -0400 Received: from mail-lf1-f65.google.com ([209.85.167.65]:45690 "EHLO mail-lf1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727258AbeHaCkS (ORCPT ); Thu, 30 Aug 2018 22:40:18 -0400 Received: by mail-lf1-f65.google.com with SMTP id r4-v6so8461832lff.12 for ; Thu, 30 Aug 2018 15:35:53 -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=0CoPjnGDX1qnLOkJ5zdzj0Bi0tX3W2cV1jd68oHh3Lw=; b=lMVYhxaUI+0ocJq6Pq6HeZ1dFOGE2SNOUpbtjlT79zBNq8uhYqBwbPPI2LI+0UvyC4 9S5AbYmNn0+A5iy0UG11Ho57MVSpclhZwnS1ZJEQoNK/Y/eEm8fSTj5FiDemkYUJtU6D 2iny680XttaafN4Q5skSdxfwGZq0byV0aiP+LgxGjiNccWqjfCVtHm0Mv7gweSJEinW+ LwHmP6aE65gYxGCuUc68OMvPYtPTg8CtuWt10XWjWZfMcAaBTAAn/gZubf8eXLpgtdYR kzkLPhpOxQ9gtkCNcuXBwvY0+NXVx3MugMcZlFG4ruZxByaBX4Fjplynmtxf4AdiXh9U GcCg== 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=0CoPjnGDX1qnLOkJ5zdzj0Bi0tX3W2cV1jd68oHh3Lw=; b=drfj7juOsfKuQe5SJ9q0bx7TodhW9sb/k4ziOWLmEnElvTKyFVvOUqKdDUGmRG6rhp TbW7rDpO7ygQTMBlKpMbJq/3T0Jccr0Hw+wdw9v3vTy2oJb8AMaSuH6uniPKQgDi0yox cZXS5tLLnl7jC5K6oKAKdUfFun11RkTR9AZII1MWyGACJ4/QgfFR1X9Bz8KdSxmXHfcJ qnvIxoVWI+B31J0mu3bIe6zCpPPPWB8JweimYhYHV/2Z+5BUA+OHJh/Vnyi/9Oniaxzy 0bcPT6GT8WPwSNUFxV1TkE9UME8Yxo1JUFXgeZFBL8gP/0aTN5RHub0+131qXvW4FtPH 40iw== X-Gm-Message-State: APzg51DMF4k48TMXo/6he3vraBMuSeKHeZk+k4CX96rOSU63VgiaAlxT yRCGtC7yDmiUi5c4BHyFtyozaZk/1yc= X-Received: by 2002:a19:1388:: with SMTP id 8-v6mr9073506lft.12.1535668552575; Thu, 30 Aug 2018 15:35:52 -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.51 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 30 Aug 2018 15:35:51 -0700 (PDT) From: Igor Stoppa X-Google-Original-From: Igor Stoppa To: linux-kernel@vger.kernel.org Cc: igor.stoppa@gmail.com, Igor Stoppa , zijun_hu , Tejun Heo , Christoph Lameter , Dennis Zhou Subject: [PATCH 20/23] mm: percpu: remove unnecessary unlikely() Date: Fri, 31 Aug 2018 01:34:26 +0300 Message-Id: <20180830223429.30051-21-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: zijun_hu Cc: Tejun Heo Cc: Christoph Lameter Cc: Dennis Zhou --- mm/percpu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/percpu.c b/mm/percpu.c index a749d4d96e3e..f5c2796fe63e 100644 --- a/mm/percpu.c +++ b/mm/percpu.c @@ -2588,7 +2588,7 @@ int __init pcpu_page_first_chunk(size_t reserved_size, BUG_ON(ai->nr_groups != 1); upa = ai->alloc_size/ai->unit_size; nr_g0_units = roundup(num_possible_cpus(), upa); - if (unlikely(WARN_ON(ai->groups[0].nr_units != nr_g0_units))) { + if (WARN_ON(ai->groups[0].nr_units != nr_g0_units)) { pcpu_free_alloc_info(ai); return -EINVAL; } -- 2.17.1