mirror of
https://gitlab.com/qemu-project/openbios.git
synced 2024-02-13 08:34:06 +08:00
the source files into a structure whereby it is easier to find the relationship between a forth package word and its C implementation, while also creating a libopenbios library into which more common code from the arch/ tree can eventually be moved. Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@siriusit.co.uk> git-svn-id: svn://coreboot.org/openbios/trunk/openbios-devel@685 f158a5a8-5612-0410-a976-696ce0be7e32
36 lines
622 B
Forth
36 lines
622 B
Forth
\ tag: helper functions
|
|
\
|
|
\ deblocker / filesystem support
|
|
\
|
|
\ Copyright (C) 2003 Samuel Rydh
|
|
\
|
|
\ See the file "COPYING" for further information about
|
|
\ the copyright and warranty status of this work.
|
|
\
|
|
|
|
|
|
\ create device node and any missing parents.
|
|
\ The new node becomes the active package
|
|
|
|
: create-node ( nodepath -- )
|
|
recursive
|
|
ascii / right-split
|
|
2dup find-dev if
|
|
active-package!
|
|
2drop
|
|
else
|
|
( nodename path )
|
|
dup if
|
|
create-node
|
|
else
|
|
device-tree @ active-package!
|
|
2drop
|
|
then
|
|
then
|
|
new-device
|
|
device-name
|
|
active-package
|
|
finish-device
|
|
active-package!
|
|
;
|