]> git.baikalelectronics.ru Git - uboot.git/commit
spl: fit: Only look up FIT configuration node once
authorAlexandru Gagniuc <mr.nuke.me@gmail.com>
Wed, 20 Jan 2021 16:46:53 +0000 (10:46 -0600)
committerTom Rini <trini@konsulko.com>
Thu, 18 Feb 2021 00:46:43 +0000 (19:46 -0500)
commit779989a50abd625092a1eda03b75fa7c2f4749ac
tree2e3eb4e50e4395c2d4e21510baaed88f9584b805
parentf52a4a643bdf88dc02baba889401c558667ec518
spl: fit: Only look up FIT configuration node once

The configuration node a sub node under "/configurations", which
describes the components to load from "/images". We only need to
locate this node once.

However, for each component, spl_fit_get_image_name() would parse the
FIT image, looking for the correct node. Such work duplication is not
necessary. Instead, once the node is found, cache it, and re-use it.

Signed-off-by: Alexandru Gagniuc <mr.nuke.me@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
common/spl/spl_fit.c