Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp8709pxf; Tue, 16 Mar 2021 20:17:54 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyOnYaWzDcsGtMr6TlQUFbkoLbapT95kywdQv7BgV0nZ0dxQTurGSRk6AfoK6gmssdj29fT X-Received: by 2002:aa7:d656:: with SMTP id v22mr39119406edr.119.1615951074240; Tue, 16 Mar 2021 20:17:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1615951074; cv=none; d=google.com; s=arc-20160816; b=e2SaudWeWMJqyexQACPCq0+iP3YObkVm7Ivp+vXngYaApUOEw6RMQhYDpvslfMF/Y6 2WhuK7sTgdFTUsbSyoPrkbWxsIpxH8cq/G8k8Fy4Oz4t12GJEKATwuUXnLXFDWliJF0P HE+JfCFl7WhrLfPiqOo/lBaoYGCdfMFawMU/KlVCRVGkPJOMsnvFUugc9pbWVo9Irxjl yAU0qDi9gGF81V1JiLsBOunxyZ6MA5NnqEhncqqid8IREZqBd6BpEY7JP2vntonwO4Iy V25xyx/5yqiQ8Tm09mkrm8niiGUnLPahoBmx1FVSv7O2any/Onsqir7oHBYOGhSqifmh HhaA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:date:subject:cc:to:from; bh=7OlmHQzzHEVu8EdR/RFLLYGotJR0g8xhx1qIWdGyAOA=; b=Prvdk5reRNgasRVp8G2auXQK4WQnAMKT2JDc3ds50oLWMR+5kDKAwVYHf2XSsmG/kv KBWLyGMMqttN/dXWkg1HiRi5ctydYARwG+ZDpSFLHDTVBVAnKpxuMZqbRL9I33Z/jGI/ mN3qsvJA1RXn18AdCmDRus0p/qAmsI5Jh9FYXNs1cVPZrzBrfFEdYw0nYF0Fwr2xDDRa 0eEVW2OMuP/D6992Ii0jwg675AYhfUjvOCgLi4AUbHcO4qIDGgexyblYCRR/Gdi6YDdk CViKG3uN81v0J8fXvLlcQhCxsaudidcThqRpUu0i5wjcyJ0/uIUSa9llbiOEtWVzfvAN fbJw== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id f3si15286591ejd.252.2021.03.16.20.17.31; Tue, 16 Mar 2021 20:17:54 -0700 (PDT) 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=alibaba.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229905AbhCQDQP (ORCPT + 99 others); Tue, 16 Mar 2021 23:16:15 -0400 Received: from out30-130.freemail.mail.aliyun.com ([115.124.30.130]:59858 "EHLO out30-130.freemail.mail.aliyun.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229491AbhCQDQJ (ORCPT ); Tue, 16 Mar 2021 23:16:09 -0400 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=alimailimapcm10staff010182156082;MF=jiapeng.chong@linux.alibaba.com;NM=1;PH=DS;RN=4;SR=0;TI=SMTPD_---0USCyl7O_1615950962; Received: from j63c13417.sqa.eu95.tbsite.net(mailfrom:jiapeng.chong@linux.alibaba.com fp:SMTPD_---0USCyl7O_1615950962) by smtp.aliyun-inc.com(127.0.0.1); Wed, 17 Mar 2021 11:16:07 +0800 From: Jiapeng Chong To: davem@davemloft.net Cc: sparclinux@vger.kernel.org, linux-kernel@vger.kernel.org, Jiapeng Chong Subject: [PATCH v2] sparc64: replace if (cond) BUG() with BUG_ON() Date: Wed, 17 Mar 2021 11:16:01 +0800 Message-Id: <1615950961-109704-1-git-send-email-jiapeng.chong@linux.alibaba.com> X-Mailer: git-send-email 1.8.3.1 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Fix the following coccicheck warnings: ./arch/sparc/kernel/traps_64.c:419:2-5: WARNING: Use BUG_ON instead of if condition followed by BUG. Reported-by: Abaci Robot Signed-off-by: Jiapeng Chong --- Changes in v2: - Replace BUG with BUG_ON. arch/sparc/kernel/traps_64.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/arch/sparc/kernel/traps_64.c b/arch/sparc/kernel/traps_64.c index a850dcc..78d04b2 100644 --- a/arch/sparc/kernel/traps_64.c +++ b/arch/sparc/kernel/traps_64.c @@ -415,8 +415,7 @@ static void spitfire_clean_and_reenable_l1_caches(void) { unsigned long va; - if (tlb_type != spitfire) - BUG(); + BUG_ON(tlb_type != spitfire); /* Clean 'em. */ for (va = 0; va < (PAGE_SIZE << 1); va += 32) { -- 1.8.3.1