From mboxrd@z Thu Jan 1 00:00:00 1970 From: Tom Rini Date: Sat, 27 Apr 2019 10:43:58 -0400 Subject: [U-Boot] fit: Add support for printing more than one FPGA node name In-Reply-To: <1556259160.10912.2.camel@intel.com> References: <1550061144-20888-1-git-send-email-tien.fong.chee@intel.com> <20190422172939.GA32292@bill-the-cat> <1556259160.10912.2.camel@intel.com> Message-ID: <20190427144358.GU31207@bill-the-cat> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit To: u-boot@lists.denx.de On Fri, Apr 26, 2019 at 06:12:40AM +0000, Chee, Tien Fong wrote: > On Mon, 2019-04-22 at 13:29 -0400, Tom Rini wrote: > > On Wed, Feb 13, 2019 at 08:32:24PM +0800, tien.fong.chee at intel.com > > wrote: > > > > > > > > From: Tien Fong Chee > > > > > > This would print out all the FPGA node names setting to fpga > > > property. > > > > > > Signed-off-by: Tien Fong Chee > > > --- > > >  common/image-fit.c |   14 +++++++++++--- > > >  1 files changed, 11 insertions(+), 3 deletions(-) > > > > > > diff --git a/common/image-fit.c b/common/image-fit.c > > > index ac901e1..816e17d 100644 > > > --- a/common/image-fit.c > > > +++ b/common/image-fit.c > > > @@ -263,6 +263,7 @@ static void fit_conf_print(const void *fit, int > > > noffset, const char *p) > > >   int ret; > > >   int fdt_index, loadables_index; > > >   int ndepth; > > > + ulong count; > > >   > > >   /* Mandatory properties */ > > >   ret = fit_get_desc(fit, noffset, &desc); > > > @@ -299,9 +300,16 @@ static void fit_conf_print(const void *fit, > > > int noffset, const char *p) > > >   printf("%s\n", uname); > > >   } > > >   > > > - uname = fdt_getprop(fit, noffset, FIT_FPGA_PROP, NULL); > > > - if (uname) > > > - printf("%s  FPGA:         %s\n", p, uname); > > > + count = fit_conf_get_prop_node_count(fit, noffset, > > > FIT_FPGA_PROP); > > > + > > > + for (ndepth = 0; ndepth < count; ndepth++) { > > > + int images_noffset = > > > fit_conf_get_prop_node_index(fit, noffset, > > > + FIT_FPGA_PROP, > > > ndepth); > > > + uname = fit_get_name(fit, images_noffset, NULL); > > > + > > > + if (uname) > > > + printf("%s  FPGA:         %s\n", p, > > > uname); > > > + } > > >   > > >   /* Print out all of the specified loadables */ > > >   for (loadables_index = 0; > > While I'm fine with the conceptual change here, both > > fit_conf_get_prop_node_count / fit_conf_get_prop_node_index are > > defined > > later in the file and while public functions not documented in a > > header. > > Can you please do a patch that does so first, as we otherwise get a > > warning?  Thanks! > The header file in this patch https://patchwork.ozlabs.org/patch/1058289/, > unfortunately the review taking a bit longer than what i expected. > > I would update you once the whole series patches are accepted. Ah, OK, I'll hold off until the other series is complete. -- Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 819 bytes Desc: not available URL: