blob: 076f5d8d9358d888d566b23ac0941a827a23d120 [file] [log] [blame]
Tom Rini10e47792018-05-06 17:58:06 -04001// SPDX-License-Identifier: GPL-2.0+
Philipp Tomsich83ad7022017-06-22 23:38:36 +02002/*
3 * Copyright (C) 2017 Theobroma Systems Design und Consulting GmH
Philipp Tomsich83ad7022017-06-22 23:38:36 +02004 */
5
6#include <common.h>
7#include <spl.h>
8
9__weak void board_return_to_bootrom(void)
10{
11}
12
13static int spl_return_to_bootrom(struct spl_image_info *spl_image,
14 struct spl_boot_device *bootdev)
15{
16 /*
17 * If the board implements a way to return to its ROM (with
18 * the expectation that the next stage of will be booted by
19 * the ROM), it will implement board_return_to_bootrom() and
20 * should not return from it.
21 */
22 board_return_to_bootrom();
23 return false;
24}
25
26SPL_LOAD_IMAGE_METHOD("BOOTROM", 0, BOOT_DEVICE_BOOTROM, spl_return_to_bootrom);