Next:
10.1 Introduction
Up:
Part III: Function Libraries
Previous:
9.9.6 fs_mountfs_unmount: Compose
10 Kernel Support Library:
liboskit_kern.a
10.1 Introduction
10.1.1 Machine-dependence of code and interfaces
10.1.2 Generic versus Base Environment code
10.1.3 Road Map
10.2 Machine-independent Facilities
10.2.1
page.h
: Page size definitions
10.2.2
spin_lock.h
: Spin locks
10.2.3
queue.h
: Generic queues
10.2.4
debug.h
: debugging support facilities
10.2.5
base_critical
: simple critical section support
(X86) Generic Low-level Definitions
10.3.1
asm.h
: assembly language support macros
10.3.2
eflags.h
: Processor flags register definitions
10.3.3
proc_reg.h
: Processor register definitions and accessor functions
10.3.4
debug_reg.h
: Debug register definitions and accessor functions
10.3.5
fp_reg.h
: Floating point register definitions and accessor functions
10.3.6
far_ptr.h
: Far (segment:offset) pointers
10.3.7
pio.h
: Programmed I/O functions
10.3.8
seg.h
: Segment descriptor data structure definitions and constants
10.3.9
gate_init.h
: Gate descriptor initialization support
10.3.10
trap.h
: Processor trap vectors
10.3.11
paging.h
: Page translation data structures and constants
10.3.12
tss.h
: Processor task save state structure definition
(X86 PC) Generic Low-level Definitions
10.4.1
irq_list.h
: Standard hardware interrupt assignments
10.4.2
pic.h
: Programmable Interrupt Controller definitions
10.4.3
keyboard.h
: PC keyboard definitions
10.4.4
rtc.h
: NVRAM Register locations
(X86) Processor Identification and Management
10.5.1
cpu_info
: CPU identification data structure
10.5.2
cpuid
: identify the current CPU
10.5.3
cpu_info_format
: output a cpu_info structure in ASCII form
10.5.4
cpu_info_min
: return the minimum feature set of two CPU information structures
10.5.5
cpu_info_dump
: pretty-print a CPU information structure to the console
10.5.6
i16_enter_pmode
: enter protected mode
10.5.7
i16_leave_pmode
: leave protected mode
10.5.8
paging_enable
: enable page translation
10.5.9
paging_disable
: disable page translation
10.5.10
gate_init
: install gate descriptors
(X86) Base Environment
10.6.1 Memory Model
10.6.2
base_vm.h
: definitions for the base virtual memory environment
10.6.3
base_cpu_setup
: initialize and activate the base CPU environment
10.6.4
base_cpu_init
: initialize the base environment data structures
10.6.5
base_cpu_load
: activate the base processor execution environment
10.6.6
base_cpuid
: global variable describing the processor
10.6.7
base_stack.h
: default kernel stack
(X86) Base Environment: Segmentation Support
10.7.1
base_gdt
: default global descriptor table for the base environment
10.7.2
base_gdt_init
: initialize the base GDT to default values
10.7.3
base_gdt_load
: load the base GDT into the CPU
10.7.4
base_idt
: default interrupt descriptor table
10.7.5
base_idt_load
: load the base IDT into the current processor
10.7.6
base_tss
: default task state segment
10.7.7
base_tss_init
: initialize the base task state segment
10.7.8
base_tss_load
: load the base TSS into the current processor
(X86) Base Environment: Trap Handling
10.8.1
trap_state
: saved state format used by the default trap handler
10.8.2
base_trap_init
: initialize the processor trap vectors in the base IDT
10.8.3
base_trap_inittab
: initialization table for the default trap entrypoints
10.8.4
base_trap_handlers
: Array of handler routines for hardware traps
10.8.5
base_trap_default_handler
: default trap handler for unexpected traps
10.8.6
trap_dump
: dump a saved trap state structure
10.8.7
trap_dump_panic
: dump a saved trap state structure
(X86) Base Environment: Page Translation
10.9.1
base_paging_init
: create minimal kernel page tables and enable paging
10.9.2
base_pdir_pa
: initial kernel page directory
10.9.3
pdir_find_pde
: find an entry in a page directory given a linear address
10.9.4
ptab_find_pte
: find an entry in a page table given a linear address
10.9.5
pdir_find_pte
: look up a page table entry from a page directory
10.9.6
pdir_get_pte
: retrieve the contents of a page table entry
10.9.7
ptab_alloc
: allocate a page table page and clear it to zero
10.9.8
ptab_free
: free a page table allocated using ptab_alloc
10.9.9
pdir_map_page
: map a 4KB page into a linear address space
10.9.10
pdir_unmap_page
: unmap a single 4KB page mapping
10.9.11
pdir_map_range
: map a contiguous range of physical addresses
10.9.12
pdir_prot_range
: change the permissions on a mapped memory range
10.9.13
pdir_unmap_range
: remove a mapped range of linear addresses
10.9.14
pdir_clean_range
: free unused page table pages in a page directory
10.9.15
pdir_dump
: dump the contents of a page directory and all its page tables
10.9.16
ptab_dump
: dump the contents of a page table
(X86) Base Environment: Protected-mode entry and exit
(X86 PC) Base Environment: Physical Memory Management
10.11.1
phys_lmm.h
: Physical memory management for PCs
10.11.2
phys_mem_max
: Highest physical memory address
10.11.3
phys_lmm_init
: Initialize kernel physical memory LMM
10.11.4
phys_lmm_add
: Add memory to the kernel physical memory LMM
(X86 PC) Base Environment: Interrupt Support
10.12.1
base_irq.h
: Hardware interrupt definitions for standard PCs
10.12.2
base_irq_handlers
: Array of handler routines for hardware interrupts
10.12.3
base_irq_init
: Initialize hardware interrupts
10.12.4
base_irq_inittab
: initialization table for default interrupt entrypoints
10.12.5
base_irq_default_handler
: default IRQ handler for unexpected interrupts
10.12.6
base_irq_nest
: interrupt nesting counter and software interrupt flag
10.12.7
base_irq_softint_request
: request a software interrupt
10.12.8
base_irq_softint_handler
: handler for software interrupts
(X86 PC) Base Environment: Console Support
10.13.1
base_console.h
: definitions for base console support
10.13.2
base_console_init
: Initialize the base console
10.13.3
base_cooked_termios
: Default
termios
setting for cooked-mode console
10.13.4
base_raw_termios
: Default
termios
setting for raw-mode console
10.13.5
direct_cons_getchar
: wait for and read a character from the keyboard
10.13.6
direct_cons_putchar
: write a character to the video console
10.13.7
direct_cons_trygetchar
: read an available character from the keyboard
10.13.8
com_cons_init
: initialize a serial port
10.13.9
com_cons_getchar
: wait for and read a character from a serial port
10.13.10
com_cons_putchar
: write a character to a serial port
10.13.11
com_cons_flush
: delay until all output is flushed on a serial line
10.13.12
com_cons_enable_receive_interrupt
: enable receive interrupts on a serial port
(X86 PC) MultiBoot Startup
10.14.1 Startup code organization
10.14.2 Startup sequence
10.14.3 Memory model
10.14.4 Command-line arguments
10.14.5 Linking MultiBoot kernels
10.14.6
multiboot.h
: Definitions of MultiBoot structures and constants
10.14.7
boot_info
: MultiBoot information structure
10.14.8
multiboot_main
: general MultiBoot initialization
10.14.9
base_multiboot_init_mem
: physical memory initialization
10.14.10
base_multiboot_init_cmdline
: command-line preprocessing
10.14.11
base_multiboot_find
: find a MultiBoot boot module by name
10.14.12 Multiboot Specification
(X86 PC) Raw BIOS Startup
(X86 PC) DOS Startup
10.17 Remote Kernel Debugging with GDB
10.17.1 Organization of remote GDB support code
10.17.2 Using the remote debugging code
10.17.3 Debugging address spaces other than the kernel's
10.17.4
gdb_state
: processor register state frame used by GDB
10.17.5
gdb_trap
: default trap handler for remote GDB debugging
10.17.6
gdb_copyin
: safely read data from the subject's address space
10.17.7
gdb_copyout
: safely write data into the subject's address space
10.17.8
gdb_trap_recover
: recovery pointer for safe memory transfer routines
10.17.9
gdb_signal
: vector to GDB trap/signal handler routine
10.17.10
gdb_set_trace_flag
: enable or disable single-stepping in a state frame
10.17.11
gdb_breakpoint
: macro to generate a manual instruction breakpoint
10.18 Serial-line Remote Debugging with GDB
10.18.1 Redirecting console output to the remote debugger
10.18.2
gdb_serial_signal
: primary event handler in the GDB stub
10.18.3
gdb_serial_exit
: notify the remote debugger that the subject is dead
10.18.4
gdb_serial_getchar
: input a character from the remote debugger's console
10.18.5
gdb_serial_putchar
: output a character to the remote debugger's console
10.18.6
gdb_serial_puts
: output a line to the remote debugger's console
10.18.7
gdb_serial_recv
: vector to GDB serial line receive function
10.18.8
gdb_serial_send
: vector to GDB serial line send function
gdb_pc_com_init
: (X86 PC) set up serial-line debugging over a COM port
10.19 Annotations
anno.h
: (X86) generic macros to place annotations in kernel code.
10.19.2
anno_dump
: dump all annotation tables
10.19.3
anno_find_exact
: find annotation table exactly entry matching a value.
10.19.4
anno_find_lower
: find greatest annotation table entry below a value.
10.19.5
anno_init
: initialize annotation tables and sort the entries.
anno_intr
: (X86) interrupt annotations
anno_trap
: (X86) trap annotations
10.20 Boot Module Filesystem
10.20.1
oskit_bmod_init
: initialize BMOD filesystem
10.20.2
oskit_bmod_lock
: lock BMOD filesystem
10.20.3
oskit_bmod_unlock
: unlock BMOD filesystem
10.20.4
oskit_bmod_file_set_contents
: replace contents of a BMOD file
10.21 Signals
10.21.1
oskit_sendsig_init
: initialize kernel signal delivery
10.21.2
oskit_sendsig
: deliver a signal
10.21.3
sendsig_trap_handler
: convert trap into a signal
University of Utah Flux Research Group