github.com/jspc/eggos@v0.5.1-0.20221028160421-556c75c878a5/zz_load_eggos.go (about) 1 //+build eggos 2 package eggos 3 4 import ( 5 "runtime" 6 7 "github.com/jspc/eggos/console" 8 "github.com/jspc/eggos/drivers/cga/fbcga" 9 _ "github.com/jspc/eggos/drivers/e1000" 10 "github.com/jspc/eggos/drivers/kbd" 11 "github.com/jspc/eggos/drivers/pci" 12 "github.com/jspc/eggos/drivers/ps2/mouse" 13 "github.com/jspc/eggos/drivers/uart" 14 "github.com/jspc/eggos/drivers/vbe" 15 "github.com/jspc/eggos/fs" 16 "github.com/jspc/eggos/inet" 17 "github.com/jspc/eggos/kernel" 18 ) 19 20 func kernelInit() { 21 // trap and syscall threads use two Ps, 22 // and the remainings are for other goroutines 23 runtime.GOMAXPROCS(6) 24 25 kernel.Init() 26 uart.Init() 27 kbd.Init() 28 mouse.Init() 29 console.Init() 30 31 fs.Init() 32 vbe.Init() 33 fbcga.Init() 34 pci.Init() 35 inet.Init() 36 } 37 38 func init() { 39 kernelInit() 40 }