[PATCH v2] cmd: md5sum: use hash_command
Tom Rini
trini at konsulko.com
Thu Mar 7 18:12:01 CET 2024
On Sat, Mar 02, 2024 at 04:05:48PM +0100, Igor Opaniuk wrote:
> Drop old implementation and use hash_command() instead, as
> how it's currently done for crc32 and sha1sum cmds.
>
> Test:
> => md5sum 0x60000000 0x200
> md5 for 60000000 ... 600001ff ==> e6bbbe95f5b41996f4a9b9af7bbd4050
>
> Signed-off-by: Igor Opaniuk <igor.opaniuk at gmail.com>
So, I think this patch shows there's a bit more cleanup to do around
crc32/crc16. Some platforms show:
aarch64: (for 1/1 boards) all +1042.0 data +168.0 rodata +38.0 text +836.0
hikey960 : all +1042 data +168 rodata +38 text +836
u-boot: add: 10/0, grow: 1/-1 bytes: 988/-272 (716)
function old new delta
hash_command 200 472 +272
hash_algo - 168 +168
hash_lookup_algo - 116 +116
crc32_wd_buf - 60 +60
crc16_ccitt_wd_buf - 60 +60
hash_finish_crc32 - 56 +56
hash_finish_crc16_ccitt - 56 +56
hash_update_crc32 - 52 +52
hash_update_crc16_ccitt - 52 +52
hash_init_crc32 - 48 +48
hash_init_crc16_ccitt - 48 +48
do_md5sum 320 48 -272
And prior to this patch this platform had enabled CONFIG_HASH already.
That said, applied to u-boot/next, 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/20240307/ff162e7a/attachment.sig>
More information about the U-Boot
mailing list