From: AKASHI Takahiro <takahiro.akashi@linaro.org>
To: u-boot@lists.denx.de
Subject: [RFC] dfu: remove UPDATE_TFTP
Date: Thu, 16 Jul 2020 10:52:46 +0900 [thread overview]
Message-ID: <20200716015246.GD12429@laputa> (raw)
In-Reply-To: <098f26e2-a6f2-fbaa-f8da-92627e14147b@gmx.de>
On Wed, Jul 15, 2020 at 04:42:20PM +0200, Heinrich Schuchardt wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA256
>
> On 15.07.20 16:06, Michal Simek wrote:
> >
> >
> > On 15. 07. 20 15:23, Lukasz Majewski wrote:
> >> Hi Heinrich,
> >>
> >> On 15.07.20 13:24, Lukasz Majewski wrote:
> >>>>> Hi Heinrich,
> >>>>>
> >>>>>> Using UPDATE_TFTP the firmware can be updated from tFTP
> >>>>>> by writing to NOR flash. The same is possible by defining
> >>>>>> a dfu command in CONFIG_PREBOOT.
> >>>>>>
> >>>>>> The dfu command cannot only write to NOR but also to
> >>>>>> other devices. In README.dfutfp UPDATE_TFTP has been
> >>>>>> marked as deprecated.
> >>>>>
> >>>>> Could you also write in the proper README the steps
> >>>>> necessary to have the same functionality as with
> >>>>> UPDATE_TFTP with dfu and preboot? I think that it would be
> >>>>> good to have it written down in ./doc.
> >>>>>
> >>
> >> doc/README.dfutftp already describes the necessary steps as:
> >>
> >> * enable CONFIG_DFU_TFTP * enable CONFIG_PREBOOT * put a string
> >> like "dfu tftp 0 mmc 0" into the "preboot" env variable
> >>
> >> Do you want me to explicitly write that "dfu tftp 0 mtd 0"
> >> replaces the former auto-update functionality?
> >
> > I am curious if that command is really dfu tftp 0 mtd 0.
>
> Lukasz was asking about the replacement of the update that was
> executed when running with CONFIG_UPDATE_TFTP=y. This function that I
> am removing could only write to NOR flash. The update defined via
> CONFIG_PREBOOT is much more flexible and can server other storage media.
One of my concerns regarding CONFIG_PREBOOT is that it depends
on the "preboot" variable.
What this means is that, if a user unsets this variable (accidentally
or not), 'automatic firmware update' won't be executed.
This can be a critical issue if the system administrator intends to
*enforce* the update.
(I know there are more issues regarding enforcement though.)
That is why I added UEFI capsule update hook in main_loop() as
a compile-time option.
Thanks,
-Takahiro Akashi
> The different accessible devices are described in doc/README.dfu.
> "ram" is one of them.
>
> Best regards
>
> Heinrich
>
> >
> > I have just tested it on zynqmp with copying images to ram and
> > command is just dfu tftp ram 0. It means I think it would be worth
> > to list options which are really used by different back ends
> > because it is not fully clear from help how to exactly define it.
> >
> > dfu tftp [<interface> <dev>] [<addr>] - device firmware upgrade via
> > TFTP on device <dev>, attached to interface <interface> [<addr>] -
> > address where FIT image has been stored
> >
> > Thanks, Michal
> >
>
> -----BEGIN PGP SIGNATURE-----
>
> iQIzBAEBCAAdFiEEbcT5xx8ppvoGt20zxIHbvCwFGsQFAl8PFcUACgkQxIHbvCwF
> GsSwLQ//bU8AISZ5q4cgLcnAVPYnBPbVtoPXlyRROnX6XW3eDjq506Ah0Rk8UwYH
> lhLSM1m+bfJZzVtWUjymlRGjuaB1HLzcyd1PbfK0+50mMaVnFBV5PMU4ue6Ju+zT
> BukpUvtQ4KLpooo2QhjCz4/oXmur782RUJGq6hb7mDbk6R0+L8coqoiglLid5374
> GdOQhgTAa8jWu0QxIBbdeOOrTSZz1kOBaShYffKXfBCaUfMOf/2T6sxDrSuTB8/N
> WTeKdbTAsx5BVEY8s9EaAy6a7kWf8mb/7LdooFUMQ2noNbdw/ucfiNCA+H2JNTK1
> GjvzDgViWAF0A0sXu6c1fqFT+4xo2lpRvG0wXsz3zRwpggmlAVX5PPi7o4Xj2HVF
> 7HPBVxz4AjJ3YpOpyLm0rEVEXnwBdke/jy/2r0VRyn5QMFaqAMEkrA39/wHrjj6t
> 0s4EUeuy5IjMf51zUrTAE/J9xHowLwjldODRgwmWoEYShJRgZp+J0yr2nhGTwpyS
> 91ESrHzkok/5BPkYFYGulBeeJFDOBegA7N7xec5e6YsXrWEPDiOpS5I1AfbycceV
> lERhJpHIgPPjpaMgNcATKeti85o7veNe31IMoW758i5kbjQFOB8NlvtSSu97/2/K
> eB/dIrOdnzC+URaun+MEt0T4HYPYgEuGAsBPQJKYrTw0sFhJRkg=
> =JXjF
> -----END PGP SIGNATURE-----
next prev parent reply other threads:[~2020-07-16 1:52 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-15 10:45 [RFC] dfu: remove UPDATE_TFTP Heinrich Schuchardt
2020-07-15 11:24 ` Lukasz Majewski
2020-07-15 11:49 ` Heinrich Schuchardt
2020-07-15 13:23 ` Lukasz Majewski
2020-07-15 14:06 ` Michal Simek
2020-07-15 14:42 ` Heinrich Schuchardt
2020-07-15 14:48 ` Michal Simek
2020-07-21 3:03 ` Heinrich Schuchardt
2020-07-21 6:31 ` Michal Simek
2020-07-16 1:52 ` AKASHI Takahiro [this message]
2020-07-16 4:44 ` Heinrich Schuchardt
2020-07-21 11:56 ` AKASHI Takahiro
2020-07-16 1:36 ` AKASHI Takahiro
2020-07-16 4:13 ` Heinrich Schuchardt
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=20200716015246.GD12429@laputa \
--to=takahiro.akashi@linaro.org \
--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