From: Anup Patel <anup@brainfault.org>
To: Christoph Hellwig <hch@infradead.org>
Cc: Palmer Dabbelt <palmer@sifive.com>,
Anup Patel <anup.patel@wdc.com>,
"linux-kernel@vger.kernel.org List"
<linux-kernel@vger.kernel.org>, Atish Patra <atish.patra@wdc.com>,
Albert Ou <aou@eecs.berkeley.edu>,
Paul Walmsley <paul.walmsley@sifive.com>,
linux-riscv@lists.infradead.org
Subject: Re: [PATCH 5/5] RISC-V: Implement compile-time fixed mappings
Date: Sat, 19 Jan 2019 16:14:48 +0530 [thread overview]
Message-ID: <CAAhSdy3skp+8qJcVhen7GN4EuF0aQoAyQtxoV2ZOv54vW9Fsew@mail.gmail.com> (raw)
In-Reply-To: <20190115134746.GF13216@infradead.org>
On Tue, Jan 15, 2019 at 7:17 PM Christoph Hellwig <hch@infradead.org> wrote:
>
> On Mon, Jan 07, 2019 at 09:40:47PM +0530, Anup Patel wrote:
> > From: Anup Patel <anup.patel@wdc.com>
> >
> > This patch implements compile-time virtual to physical
> > mappings. These compile-time fixed mappings can be used
> > by earlycon, ACPI, and early ioremap for creating fixed
> > mappings when FIX_EARLYCON_MEM=y.
> >
> > To start with, we have enabled compile-time fixed
> > mappings for earlycon.
> >
> > Signed-off-by: Anup Patel <anup.patel@wdc.com>
> > ---
> > arch/riscv/Kconfig | 3 ++
> > arch/riscv/include/asm/fixmap.h | 52 +++++++++++++++++++++++++++++++++
> > arch/riscv/mm/init.c | 32 ++++++++++++++++++++
> > 3 files changed, 87 insertions(+)
> > create mode 100644 arch/riscv/include/asm/fixmap.h
> >
> > diff --git a/arch/riscv/Kconfig b/arch/riscv/Kconfig
> > index e0d7d61779a6..66094aba9a59 100644
> > --- a/arch/riscv/Kconfig
> > +++ b/arch/riscv/Kconfig
> > @@ -86,6 +86,9 @@ config GENERIC_CSUM
> > config GENERIC_HWEIGHT
> > def_bool y
> >
> > +config FIX_EARLYCON_MEM
> > + def_bool y
> > +
>
> Can you please throw in a prep patch to move FIX_EARLYCON_MEM to
> drivers/tty/serial/Kconfig and only select it from the architectures
> that use it?
>
> > + * fixmap.h: compile-time virtual memory allocation
>
> No need to mention the header name.
>
> > + */
> > +
> > +#ifndef _ASM_RISCV_FIXMAP_H
> > +#define _ASM_RISCV_FIXMAP_H
> > +
> > +#ifndef __ASSEMBLY__
>
> As far as I can tell we never include this header from assembly files,
> so this ifdef should not be needed.
Okay, will drop #ifndef
>
> > +/*
> > + * Here we define all the compile-time 'special' virtual
> > + * addresses. The point is to have a constant address at
> > + * compile time, but to set the physical address only
> > + * in the boot process.
> > + *
> > + * These 'compile-time allocated' memory buffers are
> > + * page-sized. Use set_fixmap(idx,phys) to associate
> > + * physical memory with fixmap indices.
> > + */
>
> Please use up the available 80 chars per line for comments.
Sure, will do.
Regards,
Anup
_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv
next prev parent reply other threads:[~2019-01-19 10:45 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-01-07 16:10 [PATCH 0/5] Fixmap support and MM cleanups Anup Patel
2019-01-07 16:10 ` [PATCH 1/5] RISC-V: Move free_initrd_mem() to kernel/setup.c Anup Patel
2019-01-15 13:43 ` Christoph Hellwig
2019-01-19 10:34 ` Anup Patel
2019-01-07 16:10 ` [PATCH 2/5] RISC-V: Setup init_mm before parse_early_param() Anup Patel
2019-01-15 13:44 ` Christoph Hellwig
2019-01-19 10:42 ` Anup Patel
2019-01-07 16:10 ` [PATCH 3/5] RISC-V: Move setup_bootmem() to mm/init.c Anup Patel
2019-01-15 13:44 ` Christoph Hellwig
2019-01-19 10:43 ` Anup Patel
2019-01-07 16:10 ` [PATCH 4/5] RISC-V: Move setup_vm() " Anup Patel
2019-01-15 13:45 ` Christoph Hellwig
2019-01-07 16:10 ` [PATCH 5/5] RISC-V: Implement compile-time fixed mappings Anup Patel
2019-01-15 13:47 ` Christoph Hellwig
2019-01-19 10:44 ` Anup Patel [this message]
2019-01-19 11:44 ` Anup Patel
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=CAAhSdy3skp+8qJcVhen7GN4EuF0aQoAyQtxoV2ZOv54vW9Fsew@mail.gmail.com \
--to=anup@brainfault.org \
--cc=anup.patel@wdc.com \
--cc=aou@eecs.berkeley.edu \
--cc=atish.patra@wdc.com \
--cc=hch@infradead.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;
as well as URLs for NNTP newsgroup(s).