lkml.org 
[lkml]   [2019]   [May]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRE: [PATCH V2 1/2] soc: imx: Add SCU SoC info driver support
Date
Hi, Leonard

> -----Original Message-----
> From: Leonard Crestez
> Sent: Wednesday, May 15, 2019 6:05 PM
> To: Anson Huang <anson.huang@nxp.com>
> Cc: catalin.marinas@arm.com; will.deacon@arm.com;
> shawnguo@kernel.org; s.hauer@pengutronix.de; kernel@pengutronix.de;
> festevam@gmail.com; agross@kernel.org; maxime.ripard@bootlin.com;
> olof@lixom.net; horms+renesas@verge.net.au;
> jagan@amarulasolutions.com; bjorn.andersson@linaro.org;
> marc.w.gonzalez@free.fr; dinguyen@kernel.org;
> enric.balletbo@collabora.com; l.stach@pengutronix.de; Abel Vesa
> <abel.vesa@nxp.com>; robh@kernel.org; linux-arm-
> kernel@lists.infradead.org; linux-kernel@vger.kernel.org; dl-linux-imx
> <linux-imx@nxp.com>; Aisheng Dong <aisheng.dong@nxp.com>
> Subject: Re: [PATCH V2 1/2] soc: imx: Add SCU SoC info driver support
>
> On 15.05.2019 11:32, Anson Huang wrote:
> > Add i.MX SCU SoC info driver to support i.MX8QXP SoC, introduce driver
> > dependency into Kconfig as CONFIG_IMX_SCU must be selected to support
> > i.MX SCU SoC driver, also need to use platform driver model to make
> > sure IMX_SCU driver is probed before i.MX SCU SoC driver.
> >
> > With this patch, SoC info can be read from sysfs:
>
> > + id = of_match_node(imx_scu_soc_match, root);
> > + if (!id) {
> > + of_node_put(root);
> > + return -ENODEV;
> > + }
>
> Perhaps this check should be moved from imx_scu_soc_probe to
> imx_scu_soc_init? As far as I can tell this "probe" function will be attempted
> on all SOCs (even non-imx). Better to check if we're on a SCU-based soc early
> and avoid temporary allocations.

Make sense, I will move this check block into imx_scu_soc_init() function and
ONLY register platform driver when check passed.

>
> > +module_init(imx_scu_soc_init);
> > +module_exit(imx_scu_soc_exit);
>
> Please don't make this a module

OK, will fix it in V3.

Thanks,
Anson.

>
> --
> Regards,
> Leonard
\
 
 \ /
  Last update: 2019-05-15 14:06    [W:0.040 / U:16.364 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site