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


> -----Original Message-----
> From: Daniel Baluta [mailto:daniel.baluta@gmail.com]
> Sent: Wednesday, May 15, 2019 7:47 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; Leonard Crestez
> <leonard.crestez@nxp.com>; 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>
> Subject: Re: [PATCH V2 1/2] soc: imx: Add SCU SoC info driver support
>
> Hi Anson,
>
> Since you are going to send a new version for this please consider my
> comment inline.
>
> <snip>
>
> > +static u32 imx8qxp_soc_revision(void) {
> > + struct imx_sc_msg_misc_get_soc_id msg;
> > + struct imx_sc_rpc_msg *hdr = &msg.hdr;
> > + u32 rev = 0;
>
> No need to initialize this here.
>
> > + int ret;
> > +
> > + hdr->ver = IMX_SC_RPC_VERSION;
> > + hdr->svc = IMX_SC_RPC_SVC_MISC;
> > + hdr->func = IMX_SC_MISC_FUNC_GET_CONTROL;
> > + hdr->size = 3;
> > +
> > + msg.data.send.control = IMX_SC_C_ID;
> > + msg.data.send.resource = IMX_SC_R_SYSTEM;
> > +
> > + ret = imx_scu_call_rpc(soc_ipc_handle, &msg, true);
> > + if (ret) {
> > + dev_err(&imx_scu_soc_pdev->dev,
> > + "get soc info failed, ret %d\n", ret);
> > + /* return 0 means getting revision failed */
>
> Just return 0 here. No need for rev.

OK, thanks.

Anson.

> > + return rev;
> > + }
> > +
\
 
 \ /
  Last update: 2019-05-15 13:57    [W:0.045 / U:2.824 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site