sandbox: implement ft_board_setup()

Currently we are not able to test reservations created by ft_board_setup().

Implement ft_board_setup() to create an arbitrary reservation and enable
OF_BOARD_SETUP.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Reviewed-by: Simon Glass <sjg@chromum.org>
This commit is contained in:
Heinrich Schuchardt 2020-03-14 12:13:40 +01:00 committed by Simon Glass
parent 1ecea74e2e
commit 1c0bc80ae1
2 changed files with 7 additions and 0 deletions

View file

@ -96,6 +96,7 @@ config SANDBOX
select DM_SPI_FLASH select DM_SPI_FLASH
select HAVE_BLOCK_DEVICE select HAVE_BLOCK_DEVICE
select LZO select LZO
select OF_BOARD_SETUP
select PCI_ENDPOINT select PCI_ENDPOINT
select SPI select SPI
select SUPPORT_OF_CONTROL select SUPPORT_OF_CONTROL

View file

@ -58,6 +58,12 @@ int board_init(void)
return 0; return 0;
} }
int ft_board_setup(void *fdt, bd_t *bd)
{
/* Create an arbitrary reservation to allow testing OF_BOARD_SETUP.*/
return fdt_add_mem_rsv(fdt, 0x00d02000, 0x4000);
}
#ifdef CONFIG_BOARD_LATE_INIT #ifdef CONFIG_BOARD_LATE_INIT
int board_late_init(void) int board_late_init(void)
{ {