2018-05-06 21:58:06 +00:00
|
|
|
// SPDX-License-Identifier: GPL-2.0+
|
2015-01-14 08:07:05 +00:00
|
|
|
|
|
|
|
#include <common.h>
|
2020-05-10 17:40:02 +00:00
|
|
|
#include <init.h>
|
2018-03-04 16:20:11 +00:00
|
|
|
#include <linux/libfdt.h>
|
2015-01-14 08:07:05 +00:00
|
|
|
#include <linux/compiler.h>
|
|
|
|
|
|
|
|
int __weak checkboard(void)
|
|
|
|
{
|
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
/*
|
|
|
|
* If the root node of the DTB has a "model" property, show it.
|
2015-07-09 11:58:03 +00:00
|
|
|
* Then call checkboard().
|
2015-01-14 08:07:05 +00:00
|
|
|
*/
|
2016-11-16 16:49:20 +00:00
|
|
|
int __weak show_board_info(void)
|
2015-01-14 08:07:05 +00:00
|
|
|
{
|
2016-11-16 16:49:19 +00:00
|
|
|
#ifdef CONFIG_OF_CONTROL
|
2015-01-14 08:07:05 +00:00
|
|
|
DECLARE_GLOBAL_DATA_PTR;
|
|
|
|
const char *model;
|
|
|
|
|
|
|
|
model = fdt_getprop(gd->fdt_blob, 0, "model", NULL);
|
|
|
|
|
2015-07-09 11:58:03 +00:00
|
|
|
if (model)
|
2015-01-14 08:07:05 +00:00
|
|
|
printf("Model: %s\n", model);
|
|
|
|
#endif
|
|
|
|
|
|
|
|
return checkboard();
|
|
|
|
}
|