mirror of
https://gitlab.com/qemu-project/openbios.git
synced 2024-02-13 08:34:06 +08:00
Implement command "dir <path>".
This is the generic command, it needs support from the filesystem packages. Signed-off-by: Laurent Vivier <Laurent@vivier.eu> git-svn-id: svn://coreboot.org/openbios/trunk/openbios-devel@630 f158a5a8-5612-0410-a976-696ce0be7e32
This commit is contained in:
@@ -307,6 +307,23 @@ variable bootinfo-size
|
||||
init-program
|
||||
;
|
||||
|
||||
: dir ( "{paths}<cr>" -- )
|
||||
linefeed parse 2dup
|
||||
open-dev dup 0= if
|
||||
3drop
|
||||
exit
|
||||
then
|
||||
dup >r
|
||||
dup ihandle>phandle " dir" rot find-method ( xt 0|1 )
|
||||
if
|
||||
swap call-package
|
||||
else
|
||||
3drop
|
||||
cr ." Cannot find dir for this package"
|
||||
then
|
||||
r> close-dev
|
||||
;
|
||||
|
||||
: go ( -- )
|
||||
state-valid @ not if exit then
|
||||
elf file-type @ = if
|
||||
|
||||
Reference in New Issue
Block a user