Initial commit: Schunix as it stands before the SchOS rename
An x86-64 operating system built from xv6, now largely rewritten: SMP, a copy-on-write root filesystem (SchFS), PCI/USB/virtio drivers, a TTF rasteriser, and a Linux-numbered syscall ABI. No history before this point -- the tree was never under version control. This commit exists so the rename that follows has something to undo to.
This commit is contained in:
commit
d0f7acf9eb
275 changed files with 51417 additions and 0 deletions
28
include/param.h
Normal file
28
include/param.h
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
#pragma once
|
||||
|
||||
#define NPROC 128 // maximum number of processes
|
||||
#define KSTACKSIZE 4096 // size of per-process kernel stack (increased for x64)
|
||||
#define KSTACK_CANARY 0xDEADC0DEDEADC0DEULL // sentinel at kstack[0], see kstack_check_canary()
|
||||
#define NCPU 16 // maximum number of CPUs
|
||||
#define NOFILE 128 // open files per process
|
||||
#define NFILE 512 // open files per system
|
||||
#define NINODE 200 // maximum number of active i-nodes
|
||||
#define NDEV 10 // maximum major device number
|
||||
#define RAMDISK_DEV 2 // memory-backed block device (kernel/dev/ramdisk.c)
|
||||
#define USBDISK_DEV 3 // USB mass storage (kernel/drivers/usb_storage.c)
|
||||
|
||||
// Device the root filesystem is mounted from. Building with RAMROOT=1 defines
|
||||
// RAMDISK_ROOT and boots from the SCHFS image linked into the kernel instead
|
||||
// of the IDE disk, leaving the physical disk free to be reformatted from a
|
||||
// running system. See kernel/dev/ramdisk.c.
|
||||
#ifdef RAMDISK_ROOT
|
||||
#define ROOTDEV RAMDISK_DEV
|
||||
#else
|
||||
#define ROOTDEV 1 // device number of file system root disk
|
||||
#endif
|
||||
#define MAXARG 32 // max exec arguments
|
||||
#define MAXPATH 128 // max path
|
||||
#define MAXOPBLOCKS 30 // max # of blocks any FS op writes
|
||||
#define LOGSIZE (MAXOPBLOCKS*3) // max data blocks in on-disk log
|
||||
#define NBUF (MAXOPBLOCKS*3) // size of disk block cache
|
||||
#define FSSIZE 150000 // size of file system in blocks
|
||||
Loading…
Reference in a new issue