]> git.ipfire.org Git - people/ms/u-boot.git/blame - common/board_info.c
ARM: dts: DRA7: use new dra7-specific compatible string
[people/ms/u-boot.git] / common / board_info.c
CommitLineData
0365ffcc
MY
1/*
2 * SPDX-License-Identifier: GPL-2.0+
3 */
4
5#include <common.h>
6#include <libfdt.h>
7#include <linux/compiler.h>
8
9int __weak checkboard(void)
10{
0365ffcc
MY
11 return 0;
12}
13
14/*
15 * If the root node of the DTB has a "model" property, show it.
dac326b8 16 * Then call checkboard().
0365ffcc 17 */
f7637cc0 18int __weak show_board_info(void)
0365ffcc 19{
62e7a5c5 20#ifdef CONFIG_OF_CONTROL
0365ffcc
MY
21 DECLARE_GLOBAL_DATA_PTR;
22 const char *model;
23
24 model = fdt_getprop(gd->fdt_blob, 0, "model", NULL);
25
dac326b8 26 if (model)
0365ffcc 27 printf("Model: %s\n", model);
0365ffcc
MY
28#endif
29
30 return checkboard();
31}