More mkfs changes as Phil tries to get the kernel up to reading init.
This commit is contained in:
+3
-2
@@ -15,7 +15,8 @@ Getopt::Long::Configure qw(gnu_getopt);
|
|||||||
use constant NUMBLOCKS => 8000; # Number of blocks on a surface
|
use constant NUMBLOCKS => 8000; # Number of blocks on a surface
|
||||||
use constant WORDSPERBLK => 64; # 64 words per block
|
use constant WORDSPERBLK => 64; # 64 words per block
|
||||||
use constant NUMINODEBLKS => 710; # Blocks 1 to 710 for i-nodes
|
use constant NUMINODEBLKS => 710; # Blocks 1 to 710 for i-nodes
|
||||||
use constant FIRSTINODEBLK => 1; # First i-node block number
|
#use constant FIRSTINODEBLK => 1; # First i-node block number
|
||||||
|
use constant FIRSTINODEBLK => 2; # First i-node block number
|
||||||
use constant INODESIZE => 12; # Size of an i-node
|
use constant INODESIZE => 12; # Size of an i-node
|
||||||
use constant INODESPERBLK => int(WORDSPERBLK / INODESIZE);
|
use constant INODESPERBLK => int(WORDSPERBLK / INODESIZE);
|
||||||
use constant DIRENTSIZE => 8; # Size of an directory entry
|
use constant DIRENTSIZE => 8; # Size of an directory entry
|
||||||
@@ -58,7 +59,7 @@ use constant D_NUMWORDS => 8; # Eight words in a direntry
|
|||||||
# Globals
|
# Globals
|
||||||
my $debug = 0;
|
my $debug = 0;
|
||||||
my @Block; # Array of blocks and words in each block
|
my @Block; # Array of blocks and words in each block
|
||||||
my $nextblknum = NUMINODEBLKS + 1; # Next free block number
|
my $nextblknum = FIRSTINODEBLK + NUMINODEBLKS; # Next free block number
|
||||||
my $nextinum = 1; # i-num 0 is never used
|
my $nextinum = 1; # i-num 0 is never used
|
||||||
my @Dirstack; # Stack of directories. Each value is a ref
|
my @Dirstack; # Stack of directories. Each value is a ref
|
||||||
# to a [ blocknum, offset, inum ] array which
|
# to a [ blocknum, offset, inum ] array which
|
||||||
|
|||||||
@@ -0,0 +1,2 @@
|
|||||||
|
ken:ken:ken:12
|
||||||
|
dmr:dmr:dmr:14
|
||||||
@@ -14,6 +14,7 @@
|
|||||||
dd drw-- -1 2
|
dd drw-- -1 2
|
||||||
system drw-- -1 3
|
system drw-- -1 3
|
||||||
init frwr- -1 ../bin/init
|
init frwr- -1 ../bin/init
|
||||||
|
password frw-- -1 password
|
||||||
ttyin irwr- -1 6
|
ttyin irwr- -1 6
|
||||||
keyboard irwr- -1 7
|
keyboard irwr- -1 7
|
||||||
pptin irwr- -1 8
|
pptin irwr- -1 8
|
||||||
|
|||||||
Reference in New Issue
Block a user