From: Tom Rini <trini@konsulko.com>
To: u-boot@lists.denx.de
Subject: [PATCH] cmd: add clone command
Date: Mon, 29 Jun 2020 11:54:41 -0400 [thread overview]
Message-ID: <20200629155441.GU8432@bill-the-cat> (raw)
In-Reply-To: <20200627031549.4156-1-johnchau.2nd@gmail.com>
On Sat, Jun 27, 2020 at 11:15:49AM +0800, John Chau wrote:
> From: John Chau <john@harmon.hk>
>
> This patch adds a feature for block device cloning similar to dd
> command, this should be useful for boot-strapping a device where
> usb gadget or networking is not available. For instance one can
> clone a factory image into a blank emmc from an external sd card.
>
> Signed-off-by: John Chau <john@harmon.hk>
In general, checkpatch.pl complains a lot and those need to be fixed.
[snip]
> +config CMD_CLONE
> + bool "clone"
> + depends on BLK
> + select CLONE
There's no "config CLONE" so we don't need this line.
[snip]
> +//FIXME: we assume blk size of both devices can be divided by 1M, which should be normal
> +#define BUFSIZE (1 * 1024 * 1024)
Can we do some run-time checks of the block sizes of each device and
confirm this assumption and fail if it's not true?
Finally, we should also enable this on sandbox so that it's build-tested
and put through coverity. 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/20200629/febaeda1/attachment.sig>
next prev parent reply other threads:[~2020-06-29 15:54 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-06-27 3:15 [PATCH] cmd: add clone command John Chau
2020-06-29 15:54 ` Tom Rini [this message]
2020-07-02 3:38 ` [PATCH v2] " John Chau
2020-07-02 4:01 ` [PATCH v3] " John Chau
2020-08-05 20:27 ` 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=20200629155441.GU8432@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