diff options
author | Jean-Jacques Hiblot <jjhiblot@ti.com> | 2019-10-22 16:39:19 +0200 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2020-01-07 11:13:24 -0500 |
commit | d42730e8c67a0955c2f8236157b4723c585b9d24 (patch) | |
tree | d6e3d9b5eda9f681d47227363bbc6e10dfd6f4e5 /drivers/board | |
parent | 8c86f96d209837345200495048b4503cb02f6599 (diff) |
drivers: board: Add get_fit_loadable()
This function will be used by the SPL to get the names of images to load
from the FIT. This allows to load different images based on runtime HW
detection.
Signed-off-by: Jean-Jacques Hiblot <jjhiblot@ti.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'drivers/board')
-rw-r--r-- | drivers/board/board-uclass.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/drivers/board/board-uclass.c b/drivers/board/board-uclass.c index a516ba4962..b5485e9895 100644 --- a/drivers/board/board-uclass.c +++ b/drivers/board/board-uclass.c @@ -23,6 +23,17 @@ int board_detect(struct udevice *dev) return ops->detect(dev); } +int board_get_fit_loadable(struct udevice *dev, int index, + const char *type, const char **strp) +{ + struct board_ops *ops = board_get_ops(dev); + + if (!ops->get_fit_loadable) + return -ENOSYS; + + return ops->get_fit_loadable(dev, index, type, strp); +} + int board_get_bool(struct udevice *dev, int id, bool *val) { struct board_ops *ops = board_get_ops(dev); |