From: Christoph Hellwig <hch@infradead.org>
To: Atish Patra <atish.patra@wdc.com>
Cc: linux-kernel@vger.kernel.org, Albert Ou <aou@eecs.berkeley.edu>,
Anup Patel <anup@brainfault.org>,
Palmer Dabbelt <palmer@sifive.com>,
Johan Hovold <johan@kernel.org>,
hch@infradead.org, Paul Walmsley <paul.walmsley@sifive.com>,
linux-riscv@lists.infradead.org
Subject: Re: [v6 PATCH] RISC-V: Remove unsupported isa string info print
Date: Tue, 1 Oct 2019 00:02:36 -0700 [thread overview]
Message-ID: <20191001070236.GA7622@infradead.org> (raw)
In-Reply-To: <20191001002318.7515-1-atish.patra@wdc.com>
On Mon, Sep 30, 2019 at 05:23:18PM -0700, Atish Patra wrote:
> /proc/cpuinfo should just print all the isa string as an information
> instead of determining what is supported or not. ELF hwcap can be
> used by the userspace to figure out that.
>
> Simplify the isa string printing by removing the unsupported isa string
> print and all related code.
>
> The relevant discussion can be found at
> http://lists.infradead.org/pipermail/linux-riscv/2019-September/006702.html
This looks good, but can you also rename the orig_isa argument to isa
now that we never modify it?
> /*
> * Linux doesn't support rv32e or rv128i, and we only support booting
> * kernels on harts with the same ISA that the kernel is compiled for.
> */
> #if defined(CONFIG_32BIT)
> - if (strncmp(isa, "rv32i", 5) != 0)
> + if (strncmp(orig_isa, "rv32i", 5) != 0)
> return;
> #elif defined(CONFIG_64BIT)
> - if (strncmp(isa, "rv64i", 5) != 0)
> + if (strncmp(orig_isa, "rv64i", 5) != 0)
> return;
> #endif
And I don't think having these checks here makes much sense. If we want
to check this at all we should do it somewhere in the boot process.
next prev parent reply other threads:[~2019-10-01 7:02 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-10-01 0:23 [v6 PATCH] RISC-V: Remove unsupported isa string info print Atish Patra
2019-10-01 7:02 ` Christoph Hellwig [this message]
2019-10-01 8:22 ` Atish Patra
2019-10-01 10:10 ` hch
2019-10-02 1:53 ` Alan Kao
2019-10-02 6:28 ` Atish Patra
2019-10-07 16:58 ` hch
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20191001070236.GA7622@infradead.org \
--to=hch@infradead.org \
--cc=anup@brainfault.org \
--cc=aou@eecs.berkeley.edu \
--cc=atish.patra@wdc.com \
--cc=johan@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-riscv@lists.infradead.org \
--cc=palmer@sifive.com \
--cc=paul.walmsley@sifive.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox