Re: [PATCH v3 0/3] Add RISC-V 32 NOMMU support

From: Conor Dooley
Date: Tue Mar 14 2023 - 15:16:55 EST


On Tue, Mar 14, 2023 at 02:35:39PM -0400, Jesse Taube wrote:
>
>
> On 3/7/23 23:11, Damien Le Moal wrote:
> > On 3/8/23 12:46, Jesse Taube wrote:
> > >
> > >
> > > On 3/7/23 22:42, Damien Le Moal wrote:
> > > > On 3/8/23 12:23, Randy Dunlap wrote:
> > > > > > > OK, I don't know how it happened. I cannot reproduce it now.
> > > > > > > The failing .config files has CONFIG_MMU is not set (for RV32I), which
> > > > > > > appears to be impossible.
> > > > > > These patches add `CONFIG_MMU is not set` (for RV32I).
> > > > > > But no worries it seems to be a non issue  now.
> > > > > >
> > > > > > Your thoughts Damien?
> > > > > >
> > > > >
> > > > > Thanks for reminding me.
> > > > >
> > > > > With these 3 patches applied to linux-next-20230307,
> > > > > I still get this build error.
> > > >
> > > > Does this help ?
> > > >
> > > > diff --git a/drivers/soc/canaan/Kconfig b/drivers/soc/canaan/Kconfig
> > > > index 2527cf5757ec..7796c5f1d109 100644
> > > > --- a/drivers/soc/canaan/Kconfig
> > > > +++ b/drivers/soc/canaan/Kconfig
> > > > @@ -4,7 +4,8 @@ config SOC_K210_SYSCTL
> > > > bool "Canaan Kendryte K210 SoC system controller"
> > > > depends on RISCV && SOC_CANAAN && OF
> > > > default SOC_CANAAN
> > > > - select PM
> > > > - select MFD_SYSCON
> > > > + select COMMON_CLK_K210

Ideally this would be depends on, rather than select, so that we avoid
selecting user visible symbols like that.

> Ok so this has nothing to do with my patch-set actually and will happen on
> 64BIT as well.
> the commit that brought in this bug is:
>
> RISC-V: stop directly selecting drivers for SOC_CANAAN
> 3af577f9826fdddefac42b35fc5eb3912c5b7d85

Ah right, because the select in Kconfig.socs enforced that if the
conditions were correct for the system controller driver to be enabled,
the clock driver would always be present.
In converting the select in kconfig.socs to a default "on location", I
preserved the default behaviour but not the dependency.

> I have tested the patches Damien here they work on 64BIT and 32BIT.
> The change to drivers/clk/Kconfig is not strictly necessary but makes scene.
> I don't think they need to be tested on 32bit so we can omit COMPILE_TEST.
>
> If needed i can submit the patches, which I will author under Damien.

It probably does need fixing to satisfy the randconfigs, submit away!

> As far as I can see there is nothing holding back this set as the issue
> found has no relation to this set.

Yup. You're currently in the queue on patchwork.

Attachment: signature.asc
Description: PGP signature