From: Alexey Brodkin <Alexey.Brodkin@synopsys.com>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH] board: add support for ARC HS Development Kit (HSDK)
Date: Mon, 18 Dec 2017 13:05:25 +0000 [thread overview]
Message-ID: <1513602324.3211.27.camel@synopsys.com> (raw)
In-Reply-To: <20171218120618.4a8a9c83@windsurf>
Hi Thomas,
On Mon, 2017-12-18 at 12:06 +0100, Thomas Petazzoni wrote:
> Hello,
>
> On Fri, 15 Dec 2017 09:15:43 +0000, Alexey Brodkin wrote:
>
> > > I think option (3) is the best. But it has a drawback: it breaks
> > > backward compatibility for existing users that rely on the file being
> > > named uboot-env.bin. So instead, you could add a new U-Boot option that
> > > allows to customize the name of the generated image. By default it
> > > would be uboot-env.bin to keep backward compatibility, but it could be
> > > set to a different value in your defconfig.
> > >
> > > Or we decide to break the backward compatibility :)
> >
> > Well here again we're bumping to a situation that "something might be used
> > by BR users and we don't know what and how" :)
> >
> > I mean in upstream Buildroot (as of today, i.e. without HSDK support)
> > "uboot-env.bin" is only used for dumping binary data into SD-card image,
> > which essentially means file name makes no sense as long as genimage.cfg mentions
> > it correctly and as it might be seen from my patch proposal it is already handled
> > (proabably I should have left the patch above in place so you don't need to
> > look-up my previous email).
> >
> > So our only concern might be people use "uboot-env.bin" on their own.
>
> I think we should simply make the output file name configurable, which
> solves your use case, and preserves backward compatibility. This should
> all be explained in the commit log.
Right, we're already working on the patch to that effect.
> > > > > This should instead use the generic support/scripts/genimage.sh
> > > > >
> > > > > > +tar czf output/images/sdcard.img.tar.gz --directory="./output/images" sdcard.img
> > > > >
> > > > > And this is not needed.
> > > >
> > > > Well IMHO compression of the image makes sense because that way we may generate images
> > > > with larger FAT-partition without bumping size of the output image.
> > > >
> > > > See we always allocate a bit more space for FAT partition (or it is applicable to any not-last
> > > > partiotion - not sure about that) compared to what we need just to make sure it's enough space for our
> > > > stuff. Moreover I'd like to have some more space so I may for example put 2 uImages side by side
> > > > and switch between them later on and do it all without re-formatting of the SD-card.
> > > >
> > > > And given how large SD-cards these days are I'm fine with allocating even 100Mb for first FAT partiotion.
> > > > Now if we don't compress sdcard.img it will be of size 100+ Mb. But if we gzip it then we only have size
> > > > of real payload, i.e. ~6-7 Mb while keeping a lot of flexibility for image user.
> > > >
> > > > Not to mention a case of sharing built images.
> > > >
> > > > That said I'd rather prefer to either compress images by default (does it really hurt?)
> > > > or at least have it as an option.
> > >
> > > I'm not sure we want to solve this in your specific post-image script,
> > > it's a more generic problem. Though I agree we don't have a good way of
> > > solving it right now.
> > >
> > > Also, creating a tarball for just one file is a bit weird, you could
> > > just gzip sdcard.img to produce sdcard.img.gz.
> >
> > That's exactly what we do: we compress only resulting "sdcard.img" into "sdcard.img.tar.gz".
>
> No, the code creates a tarball:
>
> tar czf output/images/sdcard.img.tar.gz --directory="./output/images" sdcard.img
>
> Which is useless when compressing a single file. Just compress the file
> with gzip, no need to create a tarball.
I spotted that as well in Eugeniy's patch :)
Essentially there's no need for a tarball, plaingzip will be used.
> But again, I recommend against that, as none of our defconfigs do this
> currently.
As usual probably because people never had to share built images with others or
keep many of them. In comparison OpenWrt guys do it for all images just because
they build images for tons of boards and keep those images on FTPs.
> If you want to solve this problem, solve it separately,
> otherwise your defconfig will wait for ages before being merged.
Sure that makes perfect sense. But we'll keep working on that functionality so that
we'll be able to use it once corresponding patches are merged.
-Alexey
prev parent reply other threads:[~2017-12-18 13:05 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-12-07 17:06 [Buildroot] [PATCH] board: add support for ARC HS Development Kit (HSDK) Evgeniy Didin
2017-12-13 7:34 ` Thomas Petazzoni
2017-12-13 18:04 ` Alexey Brodkin
2017-12-14 6:08 ` Thomas Petazzoni
2017-12-15 9:15 ` Alexey Brodkin
2017-12-18 11:06 ` Thomas Petazzoni
2017-12-18 13:05 ` Alexey Brodkin [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1513602324.3211.27.camel@synopsys.com \
--to=alexey.brodkin@synopsys.com \
--cc=buildroot@busybox.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox