> From: feste...@gmail.com
> Date: Tue, 19 Jul 2016 14:32:17 -0300
> Subject: Re: [U-Boot] [v2 1/1] wandboard: fix dtb file names.
> To: adamdusk...@outlook.com
> CC: u-boot@lists.denx.de; sba...@denx.de
> 
> On Tue, Jul 19, 2016 at 2:23 PM, Adam Duskett <adamdusk...@outlook.com> wrote:
> > With the previous suggestion from Wolfgang Denk, this patch removes
> > the findfdt function from wandboard.h and instead replaces it with
> > some simple logic in wandboard.c.
> >
> > The new function "set_fdtfile" is called in board_late_init.  This
> > function simply finds the length of the dtb file name, allocates
> > enough space for that string, and sets the fdtfile name to that string.
> >
> > This results in slightly shorter / faster script code as well.
> >
> > Dear Adam Duskett,
> >
> > In message <blu436-smtp46bcb8c63151cd3166fbd1b9...@phx.gbl> you wrote:
> >> With the release of kernel 4.1.15 for the imx6 line of processors,
> >> wandboard now uses imx6q-wandboard-revc1.dtb and 
> >> imx6dl-wandboard-revc1.dtb.
> >> This patch fixes the naming convention to work with kernel 4.1.15
> >>
> >> Signed-off-by: Adam Duskett <adamdusk...@outlook.com>
> >> ---
> >> include/configs/wandboard.h | 4 ++--
> >> 1 file changed, 2 insertions(+), 2 deletions(-)
> >>
> >> diff --git a/include/configs/wandboard.h b/include/configs/wandboard.h
> >> index 99f5c0c..d41b600 100644
> >> --- a/include/configs/wandboard.h
> >> +++ b/include/configs/wandboard.h
> >> @@ -135,9 +135,9 @@
> >> "setenv bootargs ${bootargs} ${fbmem}\0" \
> >> "findfdt="\
> >> "if test $board_name = C1 && test $board_rev = MX6Q ; then " \
> >> -     "setenv fdtfile imx6q-wandboard.dtb; fi; " \
> >> +     "setenv fdtfile imx6q-wandboard-revc1.dtb; fi; " \
> >> "if test $board_name = C1 && test $board_rev = MX6DL ; then " \
> >> -     "setenv fdtfile imx6dl-wandboard.dtb; fi; " \
> >> +     "setenv fdtfile imx6dl-wandboard-revc1.dtb; fi; " \
> >> "if test $board_name = B1 && test $board_rev = MX6Q ; then " \
> >> "setenv fdtfile imx6q-wandboard-revb1.dtb; fi; " \
> >> "if test $board_name = B1 && test $board_rev = MX6DL ; then " \
> >
> > Instead of adding to an ever growing list of names, would it not make
> > sense to solve this programmatically, like by concatenating "i" +
> > tolower($board_rev) + "-wandboard-rev" + tolower($board_name) + ".dtb"?
> >
> > I guess this would also result in shorter / faster script code?
> >
> > Best regards,
> >
> > Wolfgang Denk
> >
> > Signed-off-by: Adam Duskett <adamdusk...@outlook.com>
> > ---
> > Changes:
> >
> > v1 - v2:
> >  - Removed findfdt from h file and moved it to init code.
> >
> >
> >  board/wandboard/wandboard.c | 20 ++++++++++++++++++++
> >  include/configs/wandboard.h | 12 ------------
> >  2 files changed, 20 insertions(+), 12 deletions(-)
> 
> This is not really making things simpler as shown by the diff stat.It changes 
> it to be programatic instead of static.
> 
> I prefer to keep the current code as is.
If it is left as is, then the previous version of the patch needs to be 
appliedbecause the new dtb file names in kernel 4.1.15 are different.           
                          
_______________________________________________
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

Reply via email to