Re: [PATCH V2] firmware: imx: Move i.MX SCU soc driver into imx firmware folder
From: Arnd Bergmann
Date: Thu Jun 25 2020 - 11:15:53 EST
On Thu, Jun 25, 2020 at 2:54 PM Anson Huang <anson.huang@xxxxxxx> wrote:
> > Subject: Re: [PATCH V2] firmware: imx: Move i.MX SCU soc driver into imx firmware folder
> > On Thu, Jun 25, 2020 at 2:27 AM Anson Huang <Anson.Huang@xxxxxxx>
> > wrote:
> > This makes separate loadable modules out of the driver when
> > CONFIG_IMX_SCU=m, including the badly named misc.ko and rm.ko modules
> > that might conflict with other modules of the same name (module names are a
> > global namespace for modprobe).
> >
> > The way to make this a single module from four files is
> >
> > obj-$(CONFIG_IMX_SCU) += imx-scu-mod.o
> > imx-scu-mod-y := imx-scu.o misc.o imx-scu-irq.o rm.o imx-scu-soc.o
>
> I haven't considered the support for loadable module of i.MX SCU firmware yet,
> plan to have another patch to do it, so do you think it is good to add the loadable
> module support together in this patch?
No, I wouldn't do that yet. It was just that adding the EXPORT_SYMBOL()
made it look like you were trying loadable module support already, and that
would not have been a good idea without changing the way it gets linked.
If you just remove the EXPORT_SYMBOL from this patch, it should be
fine, you can do the rest when you actually need the driver itself to be
loadable, and that in turn requires all drivers depending on it to
be loadable modules first.
Arnd