Received: by 2002:a25:d7c1:0:0:0:0:0 with SMTP id o184csp1279758ybg; Fri, 18 Oct 2019 15:07:52 -0700 (PDT) X-Google-Smtp-Source: APXvYqzO2n5rOEfmKUHc8xN8ce6J64V1M2y89r2JN1wT3zjUq7DP77ZGIXpU3x5ZUAaWXt7g1fOA X-Received: by 2002:a17:907:3301:: with SMTP id ym1mr11171737ejb.106.1571436472075; Fri, 18 Oct 2019 15:07:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1571436472; cv=none; d=google.com; s=arc-20160816; b=As7LK91pXGe0ztQFylJGk6CoDBLqDUdmw/V+rTEQIB0O68027PXkr2ER4HlgpEtnE9 Rk1gdgxURfuYCYWcxWn1LhbCRg1U6gjjh0MWtbIBCumU2+4OWiI8vy1eq4DpZK6IMp5H 2C7WzOdt45KD67ojplzodofCnZo1maHkywojR+o3Z+I0JAeBC4qbfefr+mauFvOcpGqL YiRAUTBKPMLs4fff+viY7jRmKv5XwBORN+EjtD4KsiVf4AdM2ZF+7p9nVk+PMjQWahov OTZiIHJgqGzVaMFyE1kNthdL93NWNAtyfgZRX6Q2RQC0skSUD6XBj7aUgepFr5TMK0MK MDmw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=/7ydX64Y3MlgTFOaeZ9aq7MX2phJVP+JprNKSr3R4gU=; b=g1LyuV0x82WjDSz+tjH1gZj2+JQM9RzLdBV8veymNZyHPgj2MCacQeuOYvfZF9VFZj mlflt62D6WFI+/aNnRHoFo+o/JKg1XZBZ+f75khOGtgbF1EM5TN23G+Pep8gksaKLfYp Xfp3nm+MDeDxXmAcQq6GvsMA4pjOeaRail61dH3cuPYWwpgahICeCGupsJzAToTuDri8 DuufDQGIxOZFg82CMSc2m350t4Ok8qzYzsV2X2SyckQC6llghsjH/HMZJlZ2W8H7uWtF dGw+Fy+n+qgajPRM8+e0gFf+LhbAUBjNx/oO+FrH3Jx3Zx+Y1xSDWmKlDFFJ8ETRjX8w YJ1g== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=O+cZ35+G; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id v9si4138763eju.434.2019.10.18.15.07.19; Fri, 18 Oct 2019 15:07: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=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=O+cZ35+G; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2440721AbfJQRhu (ORCPT + 99 others); Thu, 17 Oct 2019 13:37:50 -0400 Received: from bombadil.infradead.org ([198.137.202.133]:34604 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2436664AbfJQRhu (ORCPT ); Thu, 17 Oct 2019 13:37:50 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type:Content-ID:Content-Description:Resent-Date:Resent-From :Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help: List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=/7ydX64Y3MlgTFOaeZ9aq7MX2phJVP+JprNKSr3R4gU=; b=O+cZ35+GZ2xotfju+597+zIktS czhU26S06c6jEKG2CkJee8+LEreW/9nJMoBDxq6UN201hBc/Kcdu1mPcghb/tNSTt01dXqipZ2/gF o13wLwkqU8PVmEcbYuXBksZnMkvphWZdVUrwmP2DlfTRQhTxa3BajLD3Qll7CUxlWK6GqUxLvaTra DjpEdglwCc4hdKfioYsqdm8L68NLFBebhGR2Nm7EDo+J5fPo/MVLNOqKI7GWKoKA2uxf6PnP+oMrp tJlA3v66UAs2KKTw0VDej6x912jqX/pMawdsy9YMVFh2ljtRjt6LdxhSMtDq+wW0t0Ye5dM4qqO5K jjK9LDIg==; Received: from [2001:4bb8:18c:d7b:c70:4a89:bc61:3] (helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.92.3 #3 (Red Hat Linux)) id 1iL9ie-0007FU-3C; Thu, 17 Oct 2019 17:37:48 +0000 From: Christoph Hellwig To: Palmer Dabbelt , Paul Walmsley Cc: Damien Le Moal , linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH 01/15] riscv: cleanup Date: Thu, 17 Oct 2019 19:37:29 +0200 Message-Id: <20191017173743.5430-2-hch@lst.de> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20191017173743.5430-1-hch@lst.de> References: <20191017173743.5430-1-hch@lst.de> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Remove various not required ifdefs and externs. Signed-off-by: Christoph Hellwig --- arch/riscv/include/asm/bug.h | 16 +++------------- 1 file changed, 3 insertions(+), 13 deletions(-) diff --git a/arch/riscv/include/asm/bug.h b/arch/riscv/include/asm/bug.h index 07ceee8b1747..75604fec1b1b 100644 --- a/arch/riscv/include/asm/bug.h +++ b/arch/riscv/include/asm/bug.h @@ -12,7 +12,6 @@ #include -#ifdef CONFIG_GENERIC_BUG #define __INSN_LENGTH_MASK _UL(0x3) #define __INSN_LENGTH_32 _UL(0x3) #define __COMPRESSED_INSN_MASK _UL(0xffff) @@ -20,7 +19,6 @@ #define __BUG_INSN_32 _UL(0x00100073) /* ebreak */ #define __BUG_INSN_16 _UL(0x9002) /* c.ebreak */ -#ifndef __ASSEMBLY__ typedef u32 bug_insn_t; #ifdef CONFIG_GENERIC_BUG_RELATIVE_POINTERS @@ -43,6 +41,7 @@ typedef u32 bug_insn_t; RISCV_SHORT " %2" #endif +#ifdef CONFIG_GENERIC_BUG #define __BUG_FLAGS(flags) \ do { \ __asm__ __volatile__ ( \ @@ -58,14 +57,10 @@ do { \ "i" (flags), \ "i" (sizeof(struct bug_entry))); \ } while (0) - -#endif /* !__ASSEMBLY__ */ #else /* CONFIG_GENERIC_BUG */ -#ifndef __ASSEMBLY__ #define __BUG_FLAGS(flags) do { \ __asm__ __volatile__ ("ebreak\n"); \ } while (0) -#endif /* !__ASSEMBLY__ */ #endif /* CONFIG_GENERIC_BUG */ #define BUG() do { \ @@ -79,15 +74,10 @@ do { \ #include -#ifndef __ASSEMBLY__ - struct pt_regs; struct task_struct; -extern void die(struct pt_regs *regs, const char *str); -extern void do_trap(struct pt_regs *regs, int signo, int code, - unsigned long addr); - -#endif /* !__ASSEMBLY__ */ +void die(struct pt_regs *regs, const char *str); +void do_trap(struct pt_regs *regs, int signo, int code, unsigned long addr); #endif /* _ASM_RISCV_BUG_H */ -- 2.20.1