Browse Source

Add load boot_menu_list form /boot.cfg

Change-Id: I4a08a51325f75aa09eba1b680522819a4845be20
master
lixuefeng 8 years ago
parent
commit
f76924eb07
  1. 36
      pmon/common/main.c

36
pmon/common/main.c

@ -174,16 +174,31 @@ static int load_menu_list()
if (retid == 0) {
return 1;
}
sprintf(load, "bl -d ide /dev/fs/ext2@%s/boot.cfg", dev->dv_xname);
retid = do_cmd(load);
if (retid == 0) {
return 1;
}
sprintf(load, "bl -d ide /dev/fs/fat@%s/boot/boot.cfg", dev->dv_xname);
retid = do_cmd(load);
if (retid == 0) {
return 1;
}
sprintf(load, "bl -d ide /dev/fs/fat@%s/boot.cfg", dev->dv_xname);
retid = do_cmd(load);
if (retid == 0) {
return 1;
}
sprintf(load, "bl -d ide /dev/fs/iso9660@%s/boot/boot.cfg", dev->dv_xname);
retid = do_cmd(load);
if (retid == 0) {
return 1;
}
sprintf(load, "bl -d ide /dev/fs/iso9660@%s/boot.cfg", dev->dv_xname);
retid = do_cmd(load);
if (retid == 0) {
return 1;
}
}
}
@ -200,6 +215,11 @@ static int load_menu_list()
if (retid == 0) {
return 1;
}
sprintf(load, "bl -d ide /dev/fs/iso9660@%s/boot.cfg", dev->dv_xname);
retid = do_cmd(load);
if (retid == 0) {
return 1;
}
}
}
@ -215,8 +235,24 @@ static int load_menu_list()
path = NULL;
return 1;
}
}else{
sprintf(path, "%s/boot.cfg", rootdev);
if (check_config(path) == 1)
{
sprintf(path, "bl -d ide %s/boot.cfg", rootdev);
if (do_cmd(path) == 0)
{
show_menu = 0;
free(path);
path = NULL;
return 1;
}
}
}
}
int check_user_password()
{

Loading…
Cancel
Save