image: Drop if/elseif hash selection in calculate_hash()
calculate_hash() would try to select the appropriate hashing function by a if/elseif contruct. But that is exactly why hash_lookup_algo() exists, so use it instead. This does mean that we now have to 'select HASH' to make sure we get the hash_lookup_algo() symbol. However, the change makes sense because even basic FITs will have to deal with "hash" nodes. My only concern is that the 'select SPL_HASH' might cause some platform to grow above its SPL size allowance Signed-off-by: Alexandru Gagniuc <mr.nuke.me@gmail.com> [trini: Make FSL_CAAM be implied only on ARM && SPL] Signed-off-by: Tom Rini <trini@konsulko.com>
This commit is contained in:
committed by
Tom Rini
parent
fe54aeaa4a
commit
92055e138f
@@ -11,6 +11,7 @@ config ANDROID_BOOT_IMAGE
|
||||
|
||||
config FIT
|
||||
bool "Support Flattened Image Tree"
|
||||
select HASH
|
||||
select MD5
|
||||
select SHA1
|
||||
imply SHA256
|
||||
@@ -134,6 +135,7 @@ if SPL
|
||||
config SPL_FIT
|
||||
bool "Support Flattened Image Tree within SPL"
|
||||
depends on SPL
|
||||
select SPL_HASH
|
||||
select SPL_OF_LIBFDT
|
||||
|
||||
config SPL_FIT_PRINT
|
||||
|
||||
Reference in New Issue
Block a user