Skip to content
Snippets Groups Projects
Commit 18e1c3e2 authored by Tobias Kahlki's avatar Tobias Kahlki
Browse files

cmd:seco: Renamed the guf command to seco-ne

Renamed the old G&F based name to the new SECO name.
parent 595c90c9
No related branches found
No related tags found
1 merge request!203Rename guf command and rework bootorder evaluation
......@@ -1799,11 +1799,11 @@ config CMD_UUID
source "cmd/guf_xml2dto/Kconfig"
config CMD_GUF
bool "Garz & Fricke sub-system"
config CMD_SECO_NE
bool "SECO Northern Europe sub-system"
default y
help
Provides the Garz & Fricke sub-system. The sub-system is used
Provides the SECO Northern Europe sub-system. The sub-system is used
for the board and boot configuration.
config CMD_SECO_SYSDATA
......
......@@ -194,7 +194,7 @@ obj-$(CONFIG_ARCH_MVEBU) += mvebu/
# SECO commands
obj-$(CONFIG_CMD_GUF_XML2DTO) += guf_xml2dto/
obj-$(CONFIG_CMD_GUF) += guf.o
obj-$(CONFIG_CMD_SECO_NE) += seco-ne.o
obj-$(CONFIG_CMD_SECO_SYSDATA) += sysdata.o
endif # !CONFIG_SPL_BUILD
......
......@@ -82,7 +82,7 @@ const static struct rtc_type rtc_types[] = {
* Helper Functions
*/
static uint8_t guf_get_bootbus(void)
static uint8_t seco_ne_get_bootbus(void)
{
enum boot_device bootdevice = MMC3_BOOT;
uint8_t bootbus = 0;
......@@ -114,7 +114,7 @@ static uint8_t guf_get_bootbus(void)
return bootbus;
}
static int32_t guf_read_bootmode_gpio(uint8_t *bootmode_gpio)
static int32_t seco_ne_read_bootmode_gpio(uint8_t *bootmode_gpio)
{
const board_info_t* board_info = baseboard_get_board_info();
int32_t value = 0;
......@@ -146,7 +146,7 @@ static int32_t guf_read_bootmode_gpio(uint8_t *bootmode_gpio)
return 0;
}
static int32_t guf_read_rtc(uint8_t *bootmode_rtc)
static int32_t seco_ne_read_rtc(uint8_t *bootmode_rtc)
{
size_t next_type = 0;
const struct rtc_type *rtc = NULL;
......@@ -169,7 +169,7 @@ static int32_t guf_read_rtc(uint8_t *bootmode_rtc)
if (!ret) {
/*
* Using dm_i2c_probe instead of i2c_get_chip, because the return
* value isn't meaningful to us (also see do_guf_write_rtc).
* value isn't meaningful to us (also see do_seco_ne_write_rtc).
*/
ret = dm_i2c_probe(bus, rtc->chip_address, 0, &chip);
......@@ -212,7 +212,7 @@ static int32_t guf_read_rtc(uint8_t *bootmode_rtc)
return EBUSY;
}
static int guf_write_rtc(uint8_t bootmode_rtc)
static int seco_ne_write_rtc(uint8_t bootmode_rtc)
{
size_t next_type = 0;
const struct rtc_type *rtc = NULL;
......@@ -294,7 +294,7 @@ static int guf_write_rtc(uint8_t bootmode_rtc)
/*
* Command Functions
*/
static void do_guf_bootselect(int argc, char *const *argv[])
static void do_seco_ne_bootselect(int argc, char *const *argv[])
{
size_t next_bootmode = 0;
const struct bootmode_type *bm = NULL;
......@@ -315,7 +315,7 @@ static void do_guf_bootselect(int argc, char *const *argv[])
if (!strcmp((*argv)[2], bm->name) || !strcmp((*argv)[2], bm->shortname)) {
if (env_get("disable_bootselect_rtc") == NULL) {
ret = guf_write_rtc(bm->id);
ret = seco_ne_write_rtc(bm->id);
} else {
ret = -1;
}
......@@ -358,7 +358,7 @@ static void do_guf_bootselect(int argc, char *const *argv[])
* in the U-Boot environment.
*/
if (env_get("disable_bootmode_gpio") == NULL) {
ret = guf_read_bootmode_gpio(&bootmode);
ret = seco_ne_read_bootmode_gpio(&bootmode);
}
/*
......@@ -372,7 +372,7 @@ static void do_guf_bootselect(int argc, char *const *argv[])
if (bootmode != BM_ALTERNATIVE) {
if (env_get("disable_bootselect_rtc") == NULL) {
ret = guf_read_rtc(&bootmode);
ret = seco_ne_read_rtc(&bootmode);
} else {
ret = -1;
}
......@@ -429,26 +429,26 @@ static void do_guf_bootselect(int argc, char *const *argv[])
}
}
static void do_guf_get_bootbus(int argc, char *const *argv[])
static void do_seco_ne_get_bootbus(int argc, char *const *argv[])
{
uint8_t bootbus = env_get_ulong(env_bootbus, 10, 0);
if (env_get("disable_bootbus_detection") == NULL) {
bootbus = guf_get_bootbus();
bootbus = seco_ne_get_bootbus();
}
printf("Bootbus: %d\n", bootbus);
}
static int do_guf(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[])
static int do_seco_ne(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[])
{
if (argc < 2)
return CMD_RET_USAGE;
if (!strcmp(argv[1], "bootselect"))
do_guf_bootselect(argc, &argv);
do_seco_ne_bootselect(argc, &argv);
else if (!strcmp(argv[1], "bootbus"))
do_guf_get_bootbus(argc, &argv);
do_seco_ne_get_bootbus(argc, &argv);
else
return CMD_RET_USAGE;
......@@ -456,7 +456,7 @@ static int do_guf(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[])
}
U_BOOT_CMD(
guf, 3, 0, do_guf,
seco_ne, 3, 0, do_seco_ne,
"SECO Northern Europe sub-system",
"bootselect - Determine the bootmode from GPIO/RTC or write the bootmode to the RTC\n" \
" bootbus - Get the bus from which U-Boot has been started\n" \
......
......@@ -52,7 +52,7 @@
"run edgehog; " \
"else " \
""SECO_BOOTBUS_CMD"; "\
"guf bootselect; " \
"seco_ne bootselect; " \
"if test ${bootmode} = 'initialized';then " \
"echo Bootmode initialized; " \
"part list mmc 0 -bootable partbootable; " \
......@@ -79,7 +79,7 @@
"script=boot.scr; " \
"script1=boot-alt.scr; " \
"script2=bootB.scr; " \
"guf bootselect alternative; " \
"seco_ne bootselect alternative; " \
"elif test ${bootmode} = 'regularB';then " \
"echo Bootmode regular B; " \
"script=bootB.scr; " \
......@@ -90,13 +90,13 @@
"script=boot.scr; " \
"script1=bootB.scr; " \
"script2=boot-alt.scr; " \
"guf bootselect regularB; " \
"seco_ne bootselect regularB; " \
"elif test ${bootmode} = 'oneshotB';then " \
"echo Bootmode oneshot B; " \
"script=bootB.scr; " \
"script1=boot.scr; " \
"script2=boot-alt.scr; " \
"guf bootselect regular; " \
"seco_ne bootselect regular; " \
"else " \
"echo Unknown bootmode $bootmode; " \
"script=boot-alt.scr; " \
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment