public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Tom Rini <trini@konsulko.com>
To: u-boot@lists.denx.de
Subject: [PATCH 1/2] tools/mkimage: fix handling long filenames
Date: Fri, 1 May 2020 17:56:55 -0400	[thread overview]
Message-ID: <20200501215655.GS12564@bill-the-cat> (raw)
In-Reply-To: <20200427000839.26473-2-devel-sven@geroedel.de>

On Mon, Apr 27, 2020 at 02:08:38AM +0200, Sven Roederer wrote:

> The cmdline for calling the dtc was cut-off when using long filenames (e.g.
> 245 bytes) for output-file and datafile of "-f" parameter.
> For FIT-images cmd[MKIMAGE_MAX_DTC_CMDLINE_LEN] is declared (hardcoded 512 bytes),
> and contains some static values, the path of a tmpfile and a datafile. tmpfile is
> max MKIMAGE_MAX_TMPFILE_LEN (256) and datafile might be also this size. Having two
> very long pathname results in a truncation os the executed shell command, as the
> truncated datafile path will not be found.
> Redefine MKIMAGE_MAX_DTC_CMDLINE_LEN to "2 * MKIMAGE_MAX_TMPFILE_LEN + 35 for the
> parameters.
> This likely applies to the "-d" parameter, too.
> 
> Signed-off-by: Sven Roederer <devel-sven@geroedel.de>

Applied to u-boot/master, thanks!

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: not available
URL: <https://lists.denx.de/pipermail/u-boot/attachments/20200501/556e85bd/attachment.sig>

  reply	other threads:[~2020-05-01 21:56 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-27  0:08 [PATCH 0/2] mkimage: fix using long pathnames Sven Roederer
2020-04-27  0:08 ` [PATCH 1/2] tools/mkimage: fix handling long filenames Sven Roederer
2020-05-01 21:56   ` Tom Rini [this message]
2020-04-27  0:08 ` [PATCH 2/2] tools/fit-image: print a warning when cmd-line for dtc might be truncated Sven Roederer
2020-05-01 21:57   ` Tom Rini

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=20200501215655.GS12564@bill-the-cat \
    --to=trini@konsulko.com \
    --cc=u-boot@lists.denx.de \
    /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