From mboxrd@z Thu Jan 1 00:00:00 1970 From: york sun Date: Wed, 30 Nov 2016 17:18:17 +0000 Subject: [U-Boot] [PATCH] powerpc: Retain compatible property for L2 cache References: <20161129031044.26089-1-judge.packham@gmail.com> Message-ID: List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On 11/28/2016 07:10 PM, Chris Packham wrote: > Instead of setting the compatible property to "cache", append the > desired value retaining what may already be set in the current property. > > Signed-off-by: Chris Packham > --- > > arch/powerpc/cpu/mpc85xx/fdt.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/arch/powerpc/cpu/mpc85xx/fdt.c b/arch/powerpc/cpu/mpc85xx/fdt.c > index 047c972ac78e..f31df41836d5 100644 > --- a/arch/powerpc/cpu/mpc85xx/fdt.c > +++ b/arch/powerpc/cpu/mpc85xx/fdt.c > @@ -337,7 +337,8 @@ static inline void ft_fixup_l2cache(void *blob) > fdt_setprop_cell(blob, l2_off, "cache-size", size); > fdt_setprop_cell(blob, l2_off, "cache-sets", num_sets); > fdt_setprop_cell(blob, l2_off, "cache-level", 2); > - fdt_setprop(blob, l2_off, "compatible", "cache", 6); > + if (fdt_node_check_compatible(blob, l2_off, "cache") == 1) > + fdt_appendprop_string(blob, l2_off, "compatible", "cache"); > } > > if (l3_off < 0) { > You drop fdt_setprop, check the compatible "cache" and append it with "cache" again? I thought you wanted compatible = "fsl,t2080-l2-cache-controller", "cache"; York