Re: [PATCH v2] RISC-V: Always compile mm/init.c with cmodel=medany

From: Anup Patel
Date: Mon Mar 25 2019 - 03:02:00 EST


On Mon, Mar 25, 2019 at 12:18 PM Christoph Hellwig <hch@xxxxxxxxxxxxx> wrote:
>
> On Mon, Mar 25, 2019 at 01:25:50PM +0800, Alan Kao wrote:
> > Hi Anup,
> >
> > Sorry for being late to the party. I think one more thing should
> > move together with setup_vm():
>
> Ah, I wonded about that yesterday but wasn't sure. Maybe notrace
> is a little cleaner? Either way we should probably document both
> the mcmodel and notrace assumptions in source comments for the next
> person touching this code.

The setup_vm() should be allowed to call other functions within mm/init.c
so let's go with file-level notrace (just like how it was done) for
kernel/setup.c

I certainly add comments for setup_vm() based on all our findings so far.

Regards,
Anup