From mboxrd@z Thu Jan 1 00:00:00 1970 From: Scott Wood Date: Fri, 22 Jan 2016 14:05:44 -0600 Subject: [U-Boot] [Patch V2 3/3] armv8/fsl-layerscape: fdt: add fixup for fman In-Reply-To: <1453464475-21801-3-git-send-email-Qianyu.Gong@nxp.com> References: <1453464475-21801-1-git-send-email-Qianyu.Gong@nxp.com> <1453464475-21801-3-git-send-email-Qianyu.Gong@nxp.com> Message-ID: <1453493144.19133.90.camel@buserror.net> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On Fri, 2016-01-22 at 20:07 +0800, Gong Qianyu wrote: > Add fdt fixup for Fman clock and inserting Fman ucode blob > into the device tree. > > Signed-off-by: Gong Qianyu > --- > V2: > - Removed the duplicated function. > > arch/arm/cpu/armv8/fsl-layerscape/fdt.c | 14 ++++++++++++++ > 1 file changed, 14 insertions(+) > > diff --git a/arch/arm/cpu/armv8/fsl-layerscape/fdt.c > b/arch/arm/cpu/armv8/fsl-layerscape/fdt.c > index eafdd71..8a6b694 100644 > --- a/arch/arm/cpu/armv8/fsl-layerscape/fdt.c > +++ b/arch/arm/cpu/armv8/fsl-layerscape/fdt.c > @@ -8,12 +8,16 @@ > #include > #include > #include > +#include > #ifdef CONFIG_FSL_LSCH3 > #include > #endif > #ifdef CONFIG_FSL_ESDHC > #include > #endif > +#ifdef CONFIG_SYS_DPAA_FMAN > +#include > +#endif > #ifdef CONFIG_MP > #include > #endif > @@ -181,6 +185,10 @@ static void fdt_fixup_smmu(void *blob) > > void ft_cpu_setup(void *blob, bd_t *bd) > { > + struct sys_info sysinfo; > + > + get_sys_info(&sysinfo); > + > #ifdef CONFIG_MP > ft_fixup_cpu(blob); > #endif > @@ -201,4 +209,10 @@ void ft_cpu_setup(void *blob, bd_t *bd) > #ifdef CONFIG_FSL_LSCH3 > fdt_fixup_smmu(blob); > #endif > + > +#ifdef CONFIG_SYS_DPAA_FMAN > + do_fixup_by_compat_u32(blob, "fsl,fman", > + "clock-frequency", sysinfo.freq_fman[0], 1); > + fdt_fixup_fman_firmware(blob); > +#endif > } There is no clock-frequency in the fman binding. A clocks property is used instead (which does not require a fixup). -Scott