uniphier_tsp_setup.c 628 Bytes
Newer Older
Masahiro Yamada's avatar
Masahiro Yamada committed
1
/*
2
 * Copyright (c) 2017-2020, ARM Limited and Contributors. All rights reserved.
Masahiro Yamada's avatar
Masahiro Yamada committed
3
4
5
6
 *
 * SPDX-License-Identifier: BSD-3-Clause
 */

7
8
#include <errno.h>

Masahiro Yamada's avatar
Masahiro Yamada committed
9
#include <platform_def.h>
10

11
#include <common/bl_common.h>
12
#include <plat/common/platform.h>
Masahiro Yamada's avatar
Masahiro Yamada committed
13
14
15

#include "../uniphier.h"

16
17
static unsigned int uniphier_soc = UNIPHIER_SOC_UNKNOWN;

Masahiro Yamada's avatar
Masahiro Yamada committed
18
19
void tsp_early_platform_setup(void)
{
20
21
22
23
24
	uniphier_soc = uniphier_get_soc_id();
	if (uniphier_soc == UNIPHIER_SOC_UNKNOWN)
		plat_error_handler(-ENOTSUP);

	uniphier_console_setup(uniphier_soc);
Masahiro Yamada's avatar
Masahiro Yamada committed
25
26
27
28
29
30
31
32
}

void tsp_platform_setup(void)
{
}

void tsp_plat_arch_setup(void)
{
33
	uniphier_mmap_setup(uniphier_soc);
Masahiro Yamada's avatar
Masahiro Yamada committed
34
}