Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp19224294ybl; Fri, 3 Jan 2020 19:06:08 -0800 (PST) X-Google-Smtp-Source: APXvYqyNsvg3+5ejqTu9C+JPpJNrczqSJ2HG1TudYZdzdgdwBWpmu45Wu27OPyQdbr2j8rzpba6H X-Received: by 2002:a9d:7410:: with SMTP id n16mr90130800otk.23.1578107168447; Fri, 03 Jan 2020 19:06:08 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1578107168; cv=none; d=google.com; s=arc-20160816; b=bkCkN6+8zZYVkRNPBjS7n88EjxnDLh6+wKGy49TCtt0nEHYKaA21dIjY25JkOlUeef Oljx2zsr0FW2KwlyZubLIiwnmpC+Aq/W6A4sNKCCdQLB1lop+XvGw0Zo/dYW2h7rzSV9 2dfrzXkhzmaKjqBUzJDQn+8qXxOpltuiwCgciEb7HdkFjlQgpEfdfVPcvhY/lLSjwCjo 0V55+v5G0ge2Tx8uzITtFJJ1nfwXS7Ush9O2cBrkpGiqFyfpK1SFkkSLQ8uqMyH9BqWZ 3dFFIcoBWBnyzeSmdL9wrjfXntQ+ehZe/TUTPTx20ZOa5EsTPSQVBBZqpH8OT/J312ye nOZw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=BX71mgvvvVJh9j5iXPwViX8nZ94MAki9yZVDXDO37LU=; b=Y5pXhUnUP+5ZfOOyCMnXV9ldTyGGLtQAsYwfHiYAuWiIS6NwXaSnTAB2UHNMqrzr7+ /uKBNwmvwDgY3TnjIZOV5mAPMN4NTrMbrMAAeGQmeCRJM0uRG0lho1YJebjzxjRpgiJq iJt090QxiLWgPvo4yLp8ScE4jUqxwt9k8BQ+64tLd1lcZVcg+OYTYi2l4uMVrVjYG3Vi Na6cw1PZidn4NYdB3w1vMKXNJYhZBHrEOpoD8m+Nj7zlYw4qHcIzoQpkBZURyTf9tuZw BccCBUfeaTnC94ejYHdcW7NSxbValsq2CQ/sBqMdmQJ3zCL/wukm7kyfkuDAZmdJSBDg Y+jA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@lixom-net.20150623.gappssmtp.com header.s=20150623 header.b=GKihMbDO; 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 v28si31521046ote.55.2020.01.03.19.05.56; Fri, 03 Jan 2020 19:06:08 -0800 (PST) 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=@lixom-net.20150623.gappssmtp.com header.s=20150623 header.b=GKihMbDO; 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 S1727303AbgADDFS (ORCPT + 99 others); Fri, 3 Jan 2020 22:05:18 -0500 Received: from mail-ed1-f65.google.com ([209.85.208.65]:36959 "EHLO mail-ed1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727255AbgADDFR (ORCPT ); Fri, 3 Jan 2020 22:05:17 -0500 Received: by mail-ed1-f65.google.com with SMTP id cy15so43158558edb.4 for ; Fri, 03 Jan 2020 19:05:17 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=lixom-net.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=BX71mgvvvVJh9j5iXPwViX8nZ94MAki9yZVDXDO37LU=; b=GKihMbDOaV19EjeFPkZGhmjTZbw93ryUZdGEcLqWz6jSeSvH12zmcFnClKJ7lNe8wz fTUBYyq76Z1DXbB4ADmyiusb9Nmqg96PcnNxI8BqcVOreHjJL0JR6XGKOOtsm62xszsf CTF399PYOk/Qd4mv2dEgZOZbuGDWHz/2nQ9oUlfdRw2xzsiy5HGXC0JaXSFvRBtoBtx2 wEgjNBoBFTzXbv1eqCDTctJWsd5obGUemdv+NQduZ5biriMG2NRTU/B8Ka8T8ej614BA SqnkTgevuhSBs9FhEFntlRPr9XUpO1+N4gK+UWQO22wkXdwiEpZerdXCwzz+uPTCHIji +49w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=BX71mgvvvVJh9j5iXPwViX8nZ94MAki9yZVDXDO37LU=; b=Y9hBuIMqJ/JcvALpqsBI4GIhrsRJEeVLPhKXiHzIkM6zeiUtXRFsoxgZoZ0+s0xebv /AXZzVEalO4xL3ubFJXnDbpEfj2FEyBo+r6HlL4lxNC5QUSWjlgM3ZDp678oMj6nblqp hl3718g3LZvVdjhKSPk1+iD5/g719vZ1cecjyFBA1qkhuKAHRD0lz0ZOAhbnNstnvrT3 nuglplAxquz63Tq/4BJz66Scr/mFVzjVwAImxJTWdpdfX4AN979caoBM9CM8Lot0Ei+x EyyYuDAGsYjIDLM5ayFjxArgglpO9P5AbjHj8tHfp8J0MTHLzAZzOPeGyejlUh8a6WI3 r3Iw== X-Gm-Message-State: APjAAAVM02TWiyAf05LhsJPjbsFKakKXHJx2L6qXfwhS/rkmxZODrxJg wi+nYN6LkuOnyB7rmMdCxrl82dB/QX3o5FHTrXkifg== X-Received: by 2002:aa7:c389:: with SMTP id k9mr95278721edq.63.1578107116352; Fri, 03 Jan 2020 19:05:16 -0800 (PST) MIME-Version: 1.0 References: <20191218170603.58256-1-olof@lixom.net> In-Reply-To: From: Olof Johansson Date: Fri, 3 Jan 2020 19:05:04 -0800 Message-ID: Subject: Re: [PATCH] riscv: change CSR M/S defines to use "X" for prefix To: Paul Walmsley Cc: Palmer Dabbelt , Albert Ou , Thomas Gleixner , Daniel Lezcano , linux-riscv@lists.infradead.org, Linux Kernel Mailing List , Jason Cooper , Marc Zyngier , Damien Le Moal , Christoph Hellwig Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Jan 3, 2020 at 5:28 PM Paul Walmsley wrote: > > On Wed, 18 Dec 2019, Olof Johansson wrote: > > > Commit a4c3733d32a7 ("riscv: abstract out CSR names for supervisor vs > > machine mode") introduced new non-S/M-specific defines for some of the > > CSRs and fields that differ for when you run the kernel in machine or > > supervisor mode. > > > > One of those was "IRQ_TIMER" (instead of IRQ_S_TIMER/IRQ_M_MTIMER), > > which was generic enough to cause conflicts with other defines in > > drivers. Since it was in csr.h, it ended up getting pulled in through > > fairly generic include files, etc. > > > > I looked at just renaming those, but for consistency I chose to rename all > > M/S symbols to using 'X' instead of 'S'/'M' in the identifiers instead, > > which gives them all less generic names. > > > > This is pretty churny, and I'm sure there'll be opinions on naming, but > > I figured I'd do the busywork of fixing it up instead of just pointing > > out the conflicts. > > > > Fixes: a4c3733d32a7 ("riscv: abstract out CSR names for supervisor vs machine mode") > > Cc: Christoph Hellwig > > Cc: Thomas Gleixner > > Signed-off-by: Olof Johansson > > Thanks for taking a stab at fixing the issue. I queued the following > minimal fix has been queued for v5.5-rc, adding an RV_ prefix to the IRQ_* > macros. It may be that we need to do the same thing to the rest of the > CSRs. But, based on a quick look, I think we should be OK for the moment. > Let us know if you have a different point of view. Sure, this does the job. I'd personally prefer consistent prefixes but that's just bikeshed color preferences -- this is fine. Acked-by: Olof Johansson (Builds are still failing for some configs, but will be fixed if/when you pick up https://lore.kernel.org/linux-riscv/20191217040631.91886-1-olof@lixom.net/) -Olof