|
|
1.1 ! root 1: notes on integrating kern_dev server ! 2: ! 3: What Jim did: ! 4: ! 5: * option in Makefile.m68k is udma ! 6: ! 7: * changes to kernel: ! 8: ! 9: * syscall_sw.c: ! 10: #if UDMA ! 11: FN(device_master_self, 0), /* 69 */ ! 12: #else ! 13: FN(kern_invalid, 0), /* 69 */ ! 14: #endif ! 15: ! 16: * add a call to ipc_dev_init() (one-time only init for kern_dev server, ! 17: in kern_dev.c) in mach_init.c ! 18: ! 19: * disabled the simple lock assertion in simple_lock_try (WHY???) ! 20: ! 21: * Add DEVICE_PRIV_TRAP to kern/ipc_ptraps.c ! 22: ! 23: * ipc_basic.c: ! 24: ! 25: #if UDMA ! 26: if (!dev_server_server(&kmsgptr->kmsg_header, &out_msg->kmsg_header)) ! 27: #endif ! 28: ! 29: What I have to do: ! 30: ! 31: * Move everything except for the mig stuff from driverkit/m88k into the ! 32: kernel. There's no reason for it to be outside. ! 33: --DONE ! 34: ! 35: * one-time only init function in kern_dev_priv. Runs before libIO is init'd. ! 36: ! 37: -- create device_master_port using port_alloc ! 38: -- the rest of the stuff in autoconfig_int. This function which does the ! 39: one-time only init should be in kern_dev_priv so it's not ! 40: KERNEL_FEATURES. ! 41: ! 42: ...DONE ! 43: ! 44: * at autoconfig time (autoconf_int()) ! 45: -- IOLibInit() ! 46: -- object_copyout() device_master_port to device_master_uport. This ! 47: should be a static in autoconf! ! 48: -- in an IOTask thread, do ! 49: -- autosize_bus() ! 50: -- probe_drivers ! 51: ...DONE ! 52: ! 53: * autosize_bus needs to create kern_dev_t's for hard-wired devices (adb ! 54: and frame buffer). Enumerate these neatly somehow. ! 55: ...DONE ! 56: ! 57: * for test, call do_autoconf() from init_main. Maybe later from a loaded ! 58: server. ! 59: ! 60: * Initialization sequeuence as of 2 Nov ! 61: dev_server_init() - end of setup_main() in kern/mach_init.c ! 62: objcInit() - main() in bsd/kern/init_main ! 63: do_autoconf() - just after objcInit(), before vfs_mountroot ! 64: ! 65: currently, setup_main() calls startup() early on, and this calls ! 66: configure()... ! 67: ! 68: testing libdriver in the 68k kernel ! 69: ! 70: * configuration = LIBDRV, enables: ! 71: kernobjc ! 72: objctest ! 73: driverdbg ! 74: udma ! 75: xpr_debug ! 76: ! 77: setup_main() in kern/mach_init.c ! 78: dev_server_init() ! 79: xprInit() ! 80: main() in init_main.c ! 81: _objcInit() ! 82: autoconf() (before mounting root) ! 83: IOlibIOInit() ! 84: fork off iotaskTest() in Kernel/libIO.m ! 85: config FAKE_DEVICE (defined in kern_dev_priv.h) ! 86: ! 87: Configuring w/FAKE_DEVICE true: ! 88: kernIOAttachInterrupt: avoids setting up h/w global_intr_map register ! 89: kernIOMapDevicePage: static fake device page for mapping ! 90: dev_intr_detach_com: avoid clearing global_intr_map ! 91: ! 92: testing ! 93: objtest.m has NXlock test, kernel version. Invoked via loadable ! 94: server klibtest (in driverkit/tests), which calls ! 95: doNXLockTest. ! 96: IOLibIOInit forks off iotaskTest() in Kernel/libIO.m, tests ! 97: mach functions. ! 98: dev_serv_test in driverkit/tests does half of Config's job, ! 99: doing IOGetDeviceType(), IOCreateDevicePort(), etc. for ! 100: each device known by kernel, and prints everything it ! 101: finds. ! 102: ! 103: ! 104:
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.