Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp1909328yba; Mon, 15 Apr 2019 00:31:08 -0700 (PDT) X-Google-Smtp-Source: APXvYqzb0WQHG75Wjvt/9ql7uRylWh8GkQfq8vvtWNAz1lBVmgtdEVoTQXfCVTG60mxAUnVnWbtM X-Received: by 2002:a17:902:2f43:: with SMTP id s61mr51793359plb.181.1555313468793; Mon, 15 Apr 2019 00:31:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1555313468; cv=none; d=google.com; s=arc-20160816; b=uwDNdqcnQ0NC/bqUEIs+UxSKPtrbDP6VFISzlxjivcUCs25W1YdwjUO35Vy3p9HZQL l2eeo6864G167Vyt84yFcW4XqSwcApXtgxsAU+cG7eTQWqRjJFyzEh0IMCkvi+SQIdq5 H8QmnxQYh4VW+qsFawf1iGH2lEehj+yp+k8QjsN4P2Bp/XKGl8GPuzXFAaWb1j0GpcYu hYYUSi7Mg5Kyio2KHbm1sCLdIM38uhdInO+J98vSPll4umz8UEIO1mNT2amWc/WFchaz va0BMgMFzISSiA44Qc+uEylau+nxFjoR41q4EdJNuKsrGMkKgnTZfvAdwa17iEAzKisx t8DQ== 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=ivIVXuZ5JKkuM5ppYwTsuuwYicPT88VzrKEjWRVhs2s=; b=JSt6yfQEIk3LtzCJLkP0lCmLas8LrtMuYLDzApbBxKtBh/jwGGqhpRzTsXS2VMaz8s bv2J2p7rx3H2EpRE0MHhdBDtPp1Uh8Ig0P+uSlOBBRwcp/vDjseORFRBFWih5wXw+A6i uE7nYaJX3VQVEtvlpvXDwX5e3x6Sha0rX0U3mwLKw/QGVu5YcuLJpIh7pGk5cXZzo8O/ CgNcQtbr8Fzb9S0m7KHJ/21URnrJb7Cu52omS6ef3oeHxeM7BWGaL9JZ8jNtJKQoGwTC L9AGhk31Do1MiKjUbwY9E469540vO56cVufWOFdrEOnVovH1IHlcJV6sEhHdR2UilluR HcXw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@brainfault-org.20150623.gappssmtp.com header.s=20150623 header.b=e9tZMp82; 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 g1si35415879pgd.269.2019.04.15.00.30.52; Mon, 15 Apr 2019 00:31:08 -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=@brainfault-org.20150623.gappssmtp.com header.s=20150623 header.b=e9tZMp82; 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 S1727041AbfDOH3p (ORCPT + 99 others); Mon, 15 Apr 2019 03:29:45 -0400 Received: from mail-wm1-f68.google.com ([209.85.128.68]:36785 "EHLO mail-wm1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726046AbfDOH3o (ORCPT ); Mon, 15 Apr 2019 03:29:44 -0400 Received: by mail-wm1-f68.google.com with SMTP id h18so18918258wml.1 for ; Mon, 15 Apr 2019 00:29:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=brainfault-org.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=ivIVXuZ5JKkuM5ppYwTsuuwYicPT88VzrKEjWRVhs2s=; b=e9tZMp825I78uwxh6o9KBmyQB4Ndl0aUXW2SYVr90HonLdnlv8VVuEEP3H9Srj7oxU bBTGxgvps20X5brAYRwvDMRIVUq8j8maXtnGrm19+fXQ+USOYVPQFw3n0Ix4TWcSCTGE AMuqHwNkT8zXGAyUcKmLQeBVe4PUGGhKHJX2bpZIJTE6WZ6xs9n9jPr93niAXNkiOAi6 QNWj+2FFWw3M5jKt03p04i3CCdpsz6krAgSmZ0vZYMIulw9PNPkCZtb+HaxMAJRCHcGE YEqA5nuCK2ILUxZfbez4P9wZmSWwNVDhzlKAmthQlalPXVTNOQtOs3OQZNf0t3CnTE1N CGSw== 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=ivIVXuZ5JKkuM5ppYwTsuuwYicPT88VzrKEjWRVhs2s=; b=AKck0qKnrCAlUSxSdJQCb1+uryratr+hXHo5dCPcV/FK4ZrzlGVl5Wsxwbp9/abVlA Z+nko0J6rB2rT/OfI7Xgl8VLLffs9RGAfBHdx67KtE/ibcTbRp7VSNmUNUECnZDIIPdE pYilv6YDpAdY1NStHE9o4HGUXXajDIRnB1fQ2ghie0SVau9dOuszR924jjriFoN/HiWK 2K09z72d7wAhdrjpUWkjXYAHRDIh9z7l3f+/xA0g1wTIzewPKUWycVXaKFkTHHt7UWZG 3xWRkIEO36z/ZRqh9/neOOWj6RdPLYmTyzZHytX96Gyq8DQeDSf/BIen9zChI/z9dVHp nnqg== X-Gm-Message-State: APjAAAUWpHEO2dtZ0bAKlu6q/N2w0QsHVBgNVpPqWJ1E2jnlri3x8DOu wgQCYaovl4PnuLZzglFbnTzNPstHToFkMnutl8q5GQ== X-Received: by 2002:a1c:1f08:: with SMTP id f8mr19209628wmf.97.1555313382718; Mon, 15 Apr 2019 00:29:42 -0700 (PDT) MIME-Version: 1.0 References: <20190413153807.116227-1-anup.patel@wdc.com> <20190413153807.116227-2-anup.patel@wdc.com> <20190415054949.GA9279@infradead.org> In-Reply-To: <20190415054949.GA9279@infradead.org> From: Anup Patel Date: Mon, 15 Apr 2019 12:59:31 +0530 Message-ID: Subject: Re: [PATCH v2 1/3] RISC-V: Add separate asm/encoding.h for spec related defines To: Christoph Hellwig Cc: Anup Patel , Albert Ou , Palmer Dabbelt , "linux-kernel@vger.kernel.org" , Atish Patra , Paul Walmsley , "linux-riscv@lists.infradead.org" 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 Mon, Apr 15, 2019 at 11:19 AM Christoph Hellwig wrote: > > On Sat, Apr 13, 2019 at 03:38:35PM +0000, Anup Patel wrote: > > It's better to have all RISC-V spec related defines in one place > > so this patch adds separate asm/encoding.h for such defines which > > can be included in assembly as well as C code. > > As per the discussion of version 1 on Saturday I disagree with this > move. There is both a philosophical and a practical reason for that: > > a) in RISC-V CSR access is really nicely split out into a separate > number space, just accessed through a few special instructions. > It has no overlap with the rest of instruction encoding > b) is pulled into just about every file build in the kernel > though , and > > So even if you want to later add a new for instruction > encoding details later, I'd rather prefer to keep CSR access separate > from it. Sure, no problem. I will add asm/encoding.h for instructions later. Regards, Anup