Repository navigation
Agent KB_headers_p2
grisun0 edited this page Oct 23, 2026
·
11 revisions
Previous: KB_headers.md
- Doc: The user-window memory layout (load base, stack, brk cap, graphics
- Layer: utility
- Language: h
- Symbols:
-
vfs_dirent(struct, line 383) -
vfs_ops(struct, line 388) -
vfs_file(struct, line 398) -
kfd_view(struct, line 855) -
RDFile(struct, line 281) -
KFILE(struct, line 470) -
KSym(struct, line 627) -
KProg(struct, line 632) -
kjmpbuf(struct, line 666) -
Elf64_Ehdr(struct, line 738) -
name(type_alias, line 383)typedef struct vfs_dirent { char name[VFS_NAME_MAX + 1]; -
file_operations(type_alias, line 414)typedef vfs_ops_t file_operations; -
vnode_t(type_alias, line 415)typedef vfs_file_t vnode_t; -
Elf64_Addr(type_alias, line 731)typedef unsigned long long Elf64_Addr; -
Elf64_Off(type_alias, line 732)typedef unsigned long long Elf64_Off; -
Elf64_Word(type_alias, line 733)typedef unsigned int Elf64_Word; -
Elf64_Half(type_alias, line 734)typedef unsigned short Elf64_Half; -
Elf64_Xword(type_alias, line 735)typedef unsigned long long Elf64_Xword; -
Elf64_Sxword(type_alias, line 736)typedef long long Elf64_Sxword; -
outb(function, line 26)static inline void outb(unsigned short port, unsigned char val) -
inb(function, line 29)static inline unsigned char inb(unsigned short port) -
outw(function, line 34)static inline void outw(unsigned short port, unsigned short val) -
inw(function, line 37)static inline unsigned short inw(unsigned short port) -
insw(function, line 47)static inline void insw(unsigned short port, unsigned short *buf, unsigne... -
outsw(function, line 54)static inline void outsw(unsigned short port, const unsigned short *buf, ... -
waits(function, line 64) `* and mouse_hw_init issues dozens of waits (measured 5 s of boot). This
-
- polls the port once p...`
-
C(function, line 903) `* it with pointer subtraction in C (undefined behaviour). The value is
- a link-time difference,...`
-
ktime_ms(function, line 25)unsigned long ktime_ms(void); -
vga_clear(function, line 94)void vga_clear(void); -
vga_putc(function, line 95)void vga_putc(char c); -
vga_puts(function, line 96)void vga_puts(const char *s); -
vga_scroll(function, line 97)void vga_scroll(void); -
vga_set_cursor(function, line 98)void vga_set_cursor(int x, int y); -
vga_newline(function, line 99)void vga_newline(void); -
vga_cursor_enable(function, line 100)void vga_cursor_enable(int on); -
vga_get_x(function, line 108)int vga_get_x(void); -
vga_get_y(function, line 109)int vga_get_y(void); -
vga_set_xy(function, line 110)void vga_set_xy(int x, int y); -
vga_get_color(function, line 111)char vga_get_color(void); -
minfo_sleep_init(function, line 116)void minfo_sleep_init(int tick_ok); -
minfo_tick_wake(function, line 117)void minfo_tick_wake(void *ctx); -
sb_init(function, line 120)void sb_init(void); -
sb_capture_row0(function, line 121)void sb_capture_row0(void); -
sb_reset(function, line 122)void sb_reset(void); -
sb_get_count(function, line 123)int sb_get_count(void); -
sb_get_head(function, line 124)int sb_get_head(void); -
sb_get_char(function, line 125)char sb_get_char(int row, int col); -
serial_init(function, line 128)void serial_init(void); -
serial_putc(function, line 129)void serial_putc(char c); -
serial_puts(function, line 130)void serial_puts(const char *s); -
sc_record_dump(function, line 131)void sc_record_dump(int pid); -
serial_e_count(function, line 132)unsigned long serial_e_count(void); -
serial_available(function, line 134)int serial_available(void); -
serial_getc(function, line 135)int serial_getc(void); -
kbd_read(function, line 173)int kbd_read(void); -
kbd_available(function, line 174)int kbd_available(void); -
kbd_reset_for_shell(function, line 175)void kbd_reset_for_shell(void); -
kmalloc(function, line 213)void *kmalloc(unsigned long size); -
kfree(function, line 215)void kfree(void *ptr); -
kcalloc(function, line 216)void *kcalloc(unsigned long nmemb, unsigned long size); -
krealloc(function, line 217)void *krealloc(void *ptr, unsigned long size); -
kallocator_init(function, line 218)void kallocator_init(void); -
kmalloc_aligned(function, line 219)void *kmalloc_aligned(unsigned long size, unsigned long align); -
kmalloc_page(function, line 221)void *kmalloc_page(void); -
kfree_aligned(function, line 222)void kfree_aligned(void *ptr); -
dlmalloc_init(function, line 226)void dlmalloc_init(unsigned long size); -
dlmalloc_malloc(function, line 230)void *dlmalloc_malloc(unsigned long size); -
dlmalloc_memalign(function, line 231)void *dlmalloc_memalign(unsigned long align, unsigned long size); -
dlmalloc_free(function, line 232)void dlmalloc_free(void *ptr); -
dlmalloc_calloc(function, line 233)void *dlmalloc_calloc(unsigned long nmemb, unsigned long size); -
dlmalloc_realloc(function, line 234)void *dlmalloc_realloc(void *ptr, unsigned long size); -
dlmalloc_usage(function, line 236)void dlmalloc_usage(unsigned long *used, unsigned long *free_b, unsigned long *arena); -
ramdisk_init(function, line 287)void ramdisk_init(void); -
ramdisk_open(function, line 288)RDFile *ramdisk_open(const char *name); -
ramdisk_read(function, line 289)int ramdisk_read(RDFile *f, void *buf, unsigned offset, unsigned len); -
ramdisk_write(function, line 290)int ramdisk_write(RDFile *f, const void *buf, unsigned offset, unsigned len); -
ramdisk_create(function, line 291)RDFile *ramdisk_create(const char *name, unsigned size); -
ramdisk_resize(function, line 292)int ramdisk_resize(RDFile *f, unsigned newsize); -
ramdisk_delete(function, line 293)int ramdisk_delete(RDFile *f); -
RAMDISK_FNAME_LEN(function, line 295)* RAMDISK_FNAME_LEN (fs_resolve guarantees it); -
ramdisk_rename(function, line 297)int ramdisk_rename(const char *oldname, const char *newname); -
ramdisk_list(function, line 298)int ramdisk_list(RDFile **out, int max); -
ramdisk_setup_from(function, line 299)void ramdisk_setup_from(void *data, unsigned size); -
ramdisk_count(function, line 300)int ramdisk_count(void); -
ramdisk_file_name(function, line 301)const char *ramdisk_file_name(int idx); -
ramdisk_usage(function, line 303)void ramdisk_usage(unsigned *used, unsigned *cap, unsigned *max); -
fs_resolve(function, line 311)int fs_resolve(const char *path, char *out, unsigned cap); -
fs_dir_exists(function, line 312)int fs_dir_exists(const char *dir); -
fs_is_dir(function, line 313)int fs_is_dir(const char *resolved); -
vfs_register(function, line 417)int vfs_register(const char *prefix, const vfs_ops_t *ops, const char *driver); -
vfs_unregister(function, line 418)int vfs_unregister(const char *prefix); -
vfs_list(function, line 422)int vfs_list(char prefixes[][VFS_PREFIX_LEN], char drivers[][VFS_DRIVER_LEN], int refs[], int cap); -
vfs_mount_driver(function, line 424)int vfs_mount_driver(const char *prefix, const char *driver); -
vfs_open(function, line 425)int vfs_open(const char *path, int mode, vfs_file_t *f); -
vfs_read(function, line 426)int vfs_read(vfs_file_t *f, void *buf, unsigned long len); -
vfs_write(function, line 427)int vfs_write(vfs_file_t *f, const void *buf, unsigned long len); -
vfs_close(function, line 428)int vfs_close(vfs_file_t *f); -
vfs_fstat(function, line 429)int vfs_fstat(vfs_file_t *f, unsigned long *size_out); -
vfs_readdir(function, line 430)int vfs_readdir(const char *path, vfs_dirent_t *ents, int cap); -
vfs_init(function, line 431)void vfs_init(void); -
vfs_register_builtins(function, line 432)void vfs_register_builtins(void); -
minifs_mkdir_p(function, line 433)int minifs_mkdir_p(const char *resolved); -
kfopen(function, line 495)KFILE *kfopen(const char *path, const char *mode); -
kfopen_dir(function, line 499)KFILE *kfopen_dir(const char *resolved); -
kfclose(function, line 500)int kfclose(KFILE *f); -
today(function, line 505)* cell is correct today (single shared ET_REL window, no miniGCC * threads); -
fs_rename(function, line 524)int fs_rename(const char *oldr, const char *newr); -
kfgetc(function, line 525)int kfgetc(KFILE *f); -
kfgets(function, line 526)char *kfgets(char *buf, int size, KFILE *f); -
kfungetc(function, line 527)int kfungetc(int c, KFILE *f); -
kfread(function, line 528)unsigned long kfread(void *ptr, unsigned long size, unsigned long nmemb, KFILE *f); -
kfwrite(function, line 529)unsigned long kfwrite(const void *ptr, unsigned long size, unsigned long nmemb, KFILE *f); -
kfseek(function, line 530)int kfseek(KFILE *f, long offset, int whence); -
kftell(function, line 531)long kftell(KFILE *f); -
kfputs(function, line 532)int kfputs(const char *s, KFILE *f); -
kfputc(function, line 533)int kfputc(int c, KFILE *f); -
kfflush(function, line 534)int kfflush(KFILE *f); -
krewind(function, line 535)void krewind(KFILE *f); -
kfile_stdin(function, line 540)KFILE *kfile_stdin(void); -
kfile_stdout(function, line 541)KFILE *kfile_stdout(void); -
kfile_stderr(function, line 542)KFILE *kfile_stderr(void); -
kstrlen(function, line 545)unsigned long kstrlen(const char *s); -
kstrcpy(function, line 546)char *kstrcpy(char *dst, const char *src); -
kstrncpy(function, line 547)char *kstrncpy(char *dst, const char *src, unsigned long n); -
kstrncat(function, line 548)char *kstrncat(char *dst, const char *src, unsigned long n); -
kstrcmp(function, line 549)int kstrcmp(const char *a, const char *b); -
kstrncmp(function, line 550)int kstrncmp(const char *a, const char *b, unsigned long n); -
kstrchr(function, line 551)char *kstrchr(const char *s, int c); -
kstrstr(function, line 552)char *kstrstr(const char *hay, const char *ndl); -
kmemcpy(function, line 553)void *kmemcpy(void *dst, const void *src, unsigned long n); -
kmemset(function, line 554)void *kmemset(void *dst, int c, unsigned long n); -
kmemcmp(function, line 555)int kmemcmp(const void *a, const void *b, unsigned long n); -
kmemmove(function, line 556)void *kmemmove(void *dst, const void *src, unsigned long n); -
katol(function, line 557)long katol(const char *s); -
kprintf(function, line 560)int kprintf(const char *fmt, ...); -
kfprintf(function, line 561)int kfprintf(KFILE *f, const char *fmt, ...); -
ksprintf(function, line 562)int ksprintf(char *buf, const char *fmt, ...); -
ksnprintf(function, line 563)int ksnprintf(char *buf, unsigned long size, const char *fmt, ...); -
klog(function, line 578)void klog(log_level_t level, log_subsystem_t subsys, const char *fmt, ...); -
klog_hexdump(function, line 580)void klog_hexdump(log_level_t level, log_subsystem_t subsys, const void *data, unsigned long len, const char *label); -
klog_set_level(function, line 582)void klog_set_level(log_level_t level); -
klog_set_subsys_level(function, line 583)void klog_set_subsys_level(log_subsystem_t subsys, log_level_t level); -
klog_disable(function, line 584)void klog_disable(void); -
klog_enable(function, line 585)void klog_enable(void); -
shell_init(function, line 588)void shell_init(void); -
shell_run(function, line 589)void shell_run(void); -
console_getc(function, line 590)int console_getc(void); -
console_peek(function, line 591)int console_peek(void); -
redirect_suspend(function, line 592)int redirect_suspend(void); -
redirect_resume(function, line 593)void redirect_resume(int was); -
redirect_begin(function, line 594)int redirect_begin(void); -
redirect_commit(function, line 595)int redirect_commit(const char *path, int append_mode); -
redirect_take(function, line 596)char *redirect_take(unsigned long *len_out); -
redirect_pending(function, line 597)unsigned long redirect_pending(void); -
redirect_take_into(function, line 598)unsigned long redirect_take_into(char *dst, unsigned long cap, unsigned long *len_out); -
redirect_discard(function, line 600)void redirect_discard(void); -
redirect_active(function, line 601)int redirect_active(void); -
console_stdin_push(function, line 602)int console_stdin_push(const char *data, unsigned long len); -
console_stdin_clear(function, line 603)void console_stdin_clear(void); -
console_stdin_active(function, line 604)int console_stdin_active(void); -
panic_screen(function, line 607)void panic_screen(unsigned long vector, unsigned long err, unsigned long rip, unsigned long rsp, unsigned long rbp... -
clip_set(function, line 611)int clip_set(const char *data, unsigned long len); -
clip_get(function, line 612)int clip_get(char *out, unsigned long cap); -
clip_clear(function, line 613)void clip_clear(void); -
clip_len_get(function, line 614)int clip_len_get(void); -
shell_take_redirect(function, line 615)int shell_take_redirect(int *argc, char **argv, char **path, int *append_mode); -
shell_run_any(function, line 616)int shell_run_any(const char *name, int argc, char **argv); -
shell_exec_builtin(function, line 617)void shell_exec_builtin(int argc, char **argv); -
shell_report_exit(function, line 618)void shell_report_exit(int code); -
shell_report(function, line 619)void shell_report(const char *what, const char *detail); -
kprog_slot(function, line 644)KProg *kprog_slot(const char *name); -
kprog_lookup(function, line 645)KProg *kprog_lookup(const char *name); -
ksym_resolve(function, line 646)void *ksym_resolve(const char *name); -
k_spawn(function, line 647)int k_spawn(const char *name, int argc, char **argv); -
k_register_program(function, line 648)void k_register_program(const char *name, prog_entry_t entry); -
k_register_process(function, line 649)void k_register_process(const char *name, void *proc_entry); -
k_register_symbol(function, line 650)void k_register_symbol(const char *name, void *addr); -
register_libc_symbols(function, line 654)void register_libc_symbols(void); -
k_exec_user(function, line 657)int k_exec_user(void *entry, int argc, char **argv); -
k_run_rel(function, line 658)int k_run_rel(prog_entry_t entry, int argc, char **argv); -
kexit(function, line 659)void kexit(int code); -
k_run_on_stack(function, line 662)int k_run_on_stack(void *stack_top, prog_entry_t entry, int argc, char **argv); -
ksetjmp(function, line 667)int ksetjmp(void *buf) __attribute__((returns_twice)); -
klongjmp(function, line 668)void klongjmp(void *buf, int val) __attribute__((noreturn)); -
setup_user_stack(function, line 671)unsigned long *setup_user_stack(char *sbase, unsigned long ssize, int argc, char **argv); -
vga_mode_set(function, line 673)void vga_mode_set(int on); -
vga_mode_is_active(function, line 674)int vga_mode_is_active(void); -
vga_gfx_ran_set(function, line 675)void vga_gfx_ran_set(int on); -
desktop_launch(function, line 678)void desktop_launch(const char *cmd); -
shell_queue_launch(function, line 679)void shell_queue_launch(const char *cmd); -
vga_fb_focus_next(function, line 682)void vga_fb_focus_next(void); -
vga_fb_focus_id(function, line 683)int vga_fb_focus_id(int id); -
vga_fb_focus_get(function, line 684)int vga_fb_focus_get(void); -
vga_fb_nterms_get(function, line 685)int vga_fb_nterms_get(void); -
vga_fb_term_split(function, line 686)int vga_fb_term_split(void); -
vga_fb_term_close_focused(function, line 687)int vga_fb_term_close_focused(void); -
vga_fb_tile_all(function, line 688)void vga_fb_tile_all(void); -
vga_fb_list_windows(function, line 689)void vga_fb_list_windows(void); -
vga_fb_park_line(function, line 690)void vga_fb_park_line(const char *b, int p); -
vga_fb_unpark_line(function, line 691)int vga_fb_unpark_line(char *b, int *p); -
vga_fb_set_gfx_program(function, line 692)void vga_fb_set_gfx_program(const char *name); -
vga_fb_act_empty(function, line 693)int vga_fb_act_empty(void); -
vga_fb_prompt_live(function, line 694)int vga_fb_prompt_live(void); -
vga_fb_note_prompt(function, line 695)void vga_fb_note_prompt(void); -
vga_fb_clear_prompt(function, line 696)void vga_fb_clear_prompt(void); -
vga_fb_prompted(function, line 697)int vga_fb_prompted(void); -
shell_readline_active(function, line 701)int shell_readline_active(void); -
shell_focus_park(function, line 702)void shell_focus_park(void); -
shell_focus_restore(function, line 703)void shell_focus_restore(void); -
user_range_ok(function, line 708)int user_range_ok(unsigned long p, unsigned long len); -
user_str_ok(function, line 709)int user_str_ok(unsigned long p, unsigned long maxlen); -
mm_setup_protections(function, line 712)void mm_setup_protections(void); -
pt_page_alloc(function, line 713)void *pt_page_alloc(void); -
pt_page_free(function, line 714)void pt_page_free(void *ptr); -
mm_user_pte_update(function, line 715)void mm_user_pte_update(unsigned long vaddr, int exec, unsigned long cr3); -
mm_user_set_exec(function, line 716)void mm_user_set_exec(unsigned long start, unsigned long end, unsigned long cr3); -
swap_out(function, line 719)int swap_out(unsigned long window_sz); -
swap_in(function, line 720)int swap_in(void); -
elf_load(function, line 766)void *elf_load(void *data, unsigned size, void **base_out); -
load_exec_elf(function, line 767)void *load_exec_elf(void *data, unsigned size); -
elf_wants_process(function, line 768)int elf_wants_process(const void *data, unsigned size); -
load_exec_elf_into(function, line 769)void *load_exec_elf_into(void *data, unsigned size, unsigned long cr3, unsigned long *brk_out, unsigned long *base_out); -
ldso_bind_into(function, line 778)int ldso_bind_into(void *data, unsigned size, unsigned long base, unsigned long cr3, vma_ctx_t *vma); -
ldso_pseudo_stat(function, line 780)int ldso_pseudo_stat(int ino, unsigned long *size_out); -
ldso_pseudo_read(function, line 781)int ldso_pseudo_read(int ino, void *dst, unsigned long off, unsigned len); -
pt_clone_user_empty(function, line 782)unsigned long pt_clone_user_empty(void); -
mm_user_ensure_page(function, line 783)int mm_user_ensure_page(unsigned long cr3, unsigned long va); -
mm_user_map_page(function, line 784)int mm_user_map_page(unsigned long cr3, unsigned long va, unsigned long phys, int write, int exec); -
mm_file_fault(function, line 786)int mm_file_fault(unsigned long cr3, unsigned long va); -
mm_file_break(function, line 787)int mm_file_break(unsigned long cr3, unsigned long va); -
mm_file_page_phys(function, line 788)unsigned long mm_file_page_phys(unsigned long cr3, unsigned long va); -
mm_file_range_release(function, line 789)void mm_file_range_release(unsigned long cr3, unsigned long base, unsigned long len, int ino, unsigned long off, int... -
mm_demand_pte(function, line 805)unsigned long mm_demand_pte(unsigned long prot); -
mm_anon_reserve(function, line 806)int mm_anon_reserve(unsigned long cr3, unsigned long base, unsigned long len, unsigned long prot); -
mm_anon_fault(function, line 808)int mm_anon_fault(unsigned long cr3, unsigned long va, int write); -
pt_page_owned(function, line 809)int pt_page_owned(unsigned long phys); -
mm_anon_release(function, line 810)void mm_anon_release(unsigned long cr3, unsigned long base, unsigned long len); -
cow_drop_ref(function, line 811)int cow_drop_ref(unsigned long phys); -
refused(function, line 817)* refused (see kernel/mm/paging.c for the fail-closed list). */ unsigned long kmm_map_device(unsigned long phys... -
kmm_make_uncached(function, line 819)int kmm_make_uncached(unsigned long phys, unsigned long len); -
mm_copy_user_page(function, line 820)int mm_copy_user_page(unsigned long dst_cr3, unsigned long src_cr3, unsigned long va); -
fault(function, line 824)* fixes one write fault (0 = resume), cow_release_window drops a * dying window's shares ahead of pt_free_user. */... -
cow_resolve(function, line 827)int cow_resolve(unsigned long cr3, unsigned long va); -
user_page_present(function, line 828)int user_page_present(unsigned long cr3, unsigned long va); -
cow_release_window(function, line 829)void cow_release_window(unsigned long cr3); -
cow_shared(function, line 830)int cow_shared(void); -
cow_page_shared(function, line 831)int cow_page_shared(unsigned long phys); -
syscall_init(function, line 834)void syscall_init(void); -
ksyscall(function, line 838)long ksyscall(long n, long a1, long a2, long a3, long a4, long a5, long a6); -
syscall_trace_enabled(function, line 839)long syscall_trace_enabled(void); -
syscall_trace_set(function, line 840)void syscall_trace_set(int on); -
syscall_trace_verbose_enabled(function, line 841)long syscall_trace_verbose_enabled(void); -
syscall_trace_verbose_set(function, line 842)void syscall_trace_verbose_set(int on); -
syscall_trace_shown(function, line 843)unsigned long syscall_trace_shown(void); -
syscall_name(function, line 844)const char *syscall_name(long n); -
kfd_get(function, line 865)KFILE *kfd_get(int fd); -
kfd_put(function, line 866)void kfd_put(KFILE *f); -
kfd_override(function, line 867)KFILE *kfd_override(int fd, KFILE *f); -
kpipe_pair(function, line 868)int kpipe_pair(KFILE **rend_out, KFILE **wend_out); -
kpipe_empty_wopen(function, line 869)int kpipe_empty_wopen(KFILE *f); -
kpipe_is_write_end(function, line 870)int kpipe_is_write_end(KFILE *f); -
kpipe_state(function, line 873)int kpipe_state(KFILE *f, unsigned *avail, unsigned *space, int *wopen, int *ropen); -
kfd_poll_revents(function, line 876)int kfd_poll_revents(int fd); -
kevent_create(function, line 882)KFILE *kevent_create(unsigned long long initval, int semaphore); -
kevent_read(function, line 883)long kevent_read(KFILE *f, unsigned long long *out); -
kevent_write(function, line 884)long kevent_write(KFILE *f, unsigned long long v); -
kevent_readable(function, line 885)int kevent_readable(KFILE *f); -
kevent_writable(function, line 886)int kevent_writable(KFILE *f); -
fd_lock(function, line 889)* fd_lock (never nested, never held across yields); -
ktime_us(function, line 913)unsigned long ktime_us(void); -
wall_us_now(function, line 914)unsigned long wall_us_now(void); -
bootlog_mark(function, line 917)void bootlog_mark(const char *name); -
bootlog_report(function, line 918)void bootlog_report(void); -
pcspk_init(function, line 921)void pcspk_init(void); -
pcspk_tone(function, line 922)void pcspk_tone(unsigned freq); -
pcspk_off(function, line 923)void pcspk_off(void); -
pcspk_set_volume(function, line 924)void pcspk_set_volume(unsigned volume); -
pcspk_get_volume(function, line 925)unsigned pcspk_get_volume(void); -
rtc_read_tod(function, line 928)int rtc_read_tod(int *hour, int *min, int *sec); -
ide_init(function, line 931)void ide_init(void); -
ide_read_sectors(function, line 932)int ide_read_sectors(unsigned int lba, unsigned int count, void *buf); -
ide_write_sectors(function, line 933)int ide_write_sectors(unsigned int lba, unsigned int count, const void *buf); -
ide_read_sector(function, line 934)int ide_read_sector(unsigned int lba, void *buf); -
ide_write_sector(function, line 935)int ide_write_sector(unsigned int lba, const void *buf); -
ide_total_sectors(function, line 936)unsigned int ide_total_sectors(void); -
ide_present(function, line 937)int ide_present(void); -
block_init(function, line 940)void block_init(void); -
block_read(function, line 941)int block_read(unsigned int block_num, void *buf); -
block_write(function, line 942)int block_write(unsigned int block_num, const void *buf); -
block_read_multi(function, line 943)int block_read_multi(unsigned int block_num, unsigned int count, void *buf); -
block_write_multi(function, line 944)int block_write_multi(unsigned int block_num, unsigned int count, const void *buf); -
block_total(function, line 945)unsigned int block_total(void); -
k_user_fault_return(function, line 948)void k_user_fault_return(void); -
console_lock(variable, line 105)extern spinlock_t console_lock; -
ser_e_cpu(variable, line 133)extern unsigned long ser_e_ra, ser_e_cpu; -
kmalloc_fail_after(variable, line 214)extern long kmalloc_fail_after; -
kheap_size(variable, line 229)extern unsigned long kheap_size; -
fs_cwd(variable, line 434)extern char fs_cwd[]; -
kerrno(variable, line 521)extern int kerrno; -
kstdin(variable, line 537)extern KFILE *kstdin; -
kstdout(variable, line 538)extern KFILE *kstdout; -
kstderr(variable, line 539)extern KFILE *kstderr; -
ksym_table(variable, line 639)extern KSym ksym_table[]; -
ksym_count(variable, line 640)extern int ksym_count; -
kprog_table(variable, line 641)extern KProg kprog_table[]; -
kprog_count(variable, line 642)extern int kprog_count; -
exec_return(variable, line 669)extern kjmpbuf exec_return; -
exec_exit_code(variable, line 670)extern int exec_exit_code; -
shell_fg_active(variable, line 705)extern volatile int shell_fg_active; -
g_brk(variable, line 723)extern unsigned long g_brk; -
g_brk_limit(variable, line 724)extern unsigned long g_brk_limit; -
user_mmap_cur(variable, line 725)extern unsigned long user_mmap_cur; -
fd_lock(variable, line 864)extern spinlock_t fd_lock; -
fs_lock(variable, line 891)extern spinlock_t fs_lock; -
kernel_end(variable, line 894)extern unsigned long kernel_end; -
ramdisk_start(variable, line 895)extern char ramdisk_start[]; -
ramdisk_end(variable, line 896)extern char ramdisk_end[]; -
ramdisk_size(variable, line 897)extern char ramdisk_size[]; -
KERNEL_H(macro, line 2)#define KERNEL_H -
EFAULT(macro, line 4)#define EFAULT -
ALIGN_UP(macro, line 20)#define ALIGN_UP(x, a) -
PORT_IO_DEFINED(macro, line 22)#define PORT_IO_DEFINED -
VGA_BASE(macro, line 90)#define VGA_BASE -
VGA_COLS(macro, line 91)#define VGA_COLS -
VGA_ROWS(macro, line 92)#define VGA_ROWS -
KEY_BACKSPACE(macro, line 138)#define KEY_BACKSPACE -
KEY_ENTER(macro, line 139)#define KEY_ENTER -
KEY_LSHIFT(macro, line 140)#define KEY_LSHIFT -
KEY_RSHIFT(macro, line 141)#define KEY_RSHIFT -
KEY_CAPS(macro, line 142)#define KEY_CAPS -
KEY_E0(macro, line 143)#define KEY_E0 -
KEY_UP(macro, line 144)#define KEY_UP -
KEY_DOWN(macro, line 145)#define KEY_DOWN -
KEY_PGUP(macro, line 146)#define KEY_PGUP -
KEY_PGDN(macro, line 147)#define KEY_PGDN -
KEY_ESC(macro, line 148)#define KEY_ESC -
KEY_CSI(macro, line 149)#define KEY_CSI -
KEY_ARR_UP(macro, line 150)#define KEY_ARR_UP -
KEY_ARR_DOWN(macro, line 151)#define KEY_ARR_DOWN -
KEY_ARR_RIGHT(macro, line 152)#define KEY_ARR_RIGHT -
KEY_ARR_LEFT(macro, line 153)#define KEY_ARR_LEFT -
KEY_HOME_SEQ(macro, line 154)#define KEY_HOME_SEQ -
KEY_END_SEQ(macro, line 155)#define KEY_END_SEQ -
KEY_PGUP_SEQ(macro, line 156)#define KEY_PGUP_SEQ -
KEY_PGDN_SEQ(macro, line 157)#define KEY_PGDN_SEQ -
KEY_LEFT(macro, line 158)#define KEY_LEFT -
KEY_RIGHT(macro, line 159)#define KEY_RIGHT -
KEY_LCTRL(macro, line 160)#define KEY_LCTRL -
KEY_RCTRL(macro, line 161)#define KEY_RCTRL -
KEY_F5(macro, line 162)#define KEY_F5 -
KEY_F11(macro, line 163)#define KEY_F11 -
KEY_TILDE(macro, line 164)#define KEY_TILDE -
KEY_LALT(macro, line 165)#define KEY_LALT -
KEY_RALT(macro, line 166)#define KEY_RALT -
KEY_HOME(macro, line 167)#define KEY_HOME -
KEY_END(macro, line 168)#define KEY_END -
KEY_TAB(macro, line 169)#define KEY_TAB -
KEY_SUPER_L(macro, line 170)#define KEY_SUPER_L -
KEY_SUPER_R(macro, line 171)#define KEY_SUPER_R -
USER_LOAD_BASE(macro, line 185)#define USER_LOAD_BASE -
USER_LOAD_END(macro, line 186)#define USER_LOAD_END -
USER_STACK_SIZE(macro, line 187)#define USER_STACK_SIZE -
USER_STACK_TOP(macro, line 188)#define USER_STACK_TOP -
USER_STACK_BASE(macro, line 189)#define USER_STACK_BASE -
USER_BRK_END(macro, line 190)#define USER_BRK_END -
LDSO_REGION_BASE(macro, line 194)#define LDSO_REGION_BASE -
LDSO_REGION_SIZE(macro, line 195)#define LDSO_REGION_SIZE -
LDSO_REGION_END(macro, line 196)#define LDSO_REGION_END -
SYS_KSTK_TOP(macro, line 201)#define SYS_KSTK_TOP -
SYS_KSTK_BASE(macro, line 202)#define SYS_KSTK_BASE -
HEAP_BASE(macro, line 204)#define HEAP_BASE -
HEAP_SIZE(macro, line 205)#define HEAP_SIZE -
DEV_MMIO_VBASE(macro, line 210)#define DEV_MMIO_VBASE -
PCI_MMIO_SIZE(macro, line 211)#define PCI_MMIO_SIZE -
KMALLOC_PAGE(macro, line 220)#define KMALLOC_PAGE -
RAMDISK_MAX_FILES(macro, line 269)#define RAMDISK_MAX_FILES -
RAMDISK_FNAME_LEN(macro, line 279)#define RAMDISK_FNAME_LEN -
RD_DATA_MAX(macro, line 305)#define RD_DATA_MAX -
ETREL_TRUSTED_DIR(macro, line 322)#define ETREL_TRUSTED_DIR -
ETREL_TRUSTED_LEN(macro, line 323)#define ETREL_TRUSTED_LEN -
VFS_NAME_MAX(macro, line 382)#define VFS_NAME_MAX -
VFS_MAX_MOUNTS(macro, line 419)#define VFS_MAX_MOUNTS -
VFS_PREFIX_LEN(macro, line 420)#define VFS_PREFIX_LEN -
VFS_DRIVER_LEN(macro, line 421)#define VFS_DRIVER_LEN -
EOF(macro, line 468)#define EOF -
ENOENT(macro, line 509)#define ENOENT -
EIO(macro, line 510)#define EIO -
EBADF(macro, line 511)#define EBADF -
ENOMEM(macro, line 512)#define ENOMEM -
ENOTDIR(macro, line 513)#define ENOTDIR -
EISDIR(macro, line 514)#define EISDIR -
EINVAL(macro, line 515)#define EINVAL -
EFBIG(macro, line 516)#define EFBIG -
ENOSPC(macro, line 517)#define ENOSPC -
ESPIPE(macro, line 518)#define ESPIPE -
ENAMETOOLONG(macro, line 519)#define ENAMETOOLONG -
KSYM_MAX(macro, line 624)#define KSYM_MAX -
KPROG_MAX(macro, line 625)#define KPROG_MAX -
EI_NIDENT(macro, line 730)#define EI_NIDENT -
ET_REL(macro, line 755)#define ET_REL -
ET_EXEC(macro, line 756)#define ET_EXEC -
ET_DYN(macro, line 757)#define ET_DYN -
USER_HEAP_CEIL(macro, line 764)#define USER_HEAP_CEIL -
PTE_DEMAND(macro, line 798)#define PTE_DEMAND -
PTE_DEMAND_READ(macro, line 799)#define PTE_DEMAND_READ -
PTE_DEMAND_WRITE(macro, line 800)#define PTE_DEMAND_WRITE -
PTE_DEMAND_EXEC(macro, line 801)#define PTE_DEMAND_EXEC -
LINUX_PROT_READ(macro, line 802)#define LINUX_PROT_READ -
LINUX_PROT_WRITE(macro, line 803)#define LINUX_PROT_WRITE -
LINUX_PROT_EXEC(macro, line 804)#define LINUX_PROT_EXEC -
KFD_MAX(macro, line 845)#define KFD_MAX -
KEVENT_MAX(macro, line 881)#define KEVENT_MAX - Depends on:
headers/ldso.h,headers/pipe.h,headers/spinlock.h,headers/vma.h,progs/minios_abi.h - Imported by:
headers/editor.h,headers/shell.h,headers/spawn.h,headers/tls_port.h
- Doc: pure time-conversion helpers shared by the kernel clock
- Layer: utility
- Language: h
- Symbols:
-
ktime_us_from_delta(function, line 19)static inline unsigned long ktime_us_from_delta(unsigned long delta_ticks, ... -
wall_us_from_parts(function, line 30)static inline unsigned long wall_us_from_parts(unsigned long base_sec, ... -
KTIME_H(macro, line 2)#define KTIME_H
-
- Imported by:
kernel/syscalls.c,kernel/time.c,tests/test_ktime.c
- Doc: Docstring: headers/ldso.h -- minimal dynamic-linking (T8 ld.so) contract.
- Layer: utility
- Language: h
- Symbols:
-
LdsoSeg(struct, line 53) -
LdsoDynInfo(struct, line 61) -
LdsoRelaRow(struct, line 77) -
ldso_find_dynamic(function, line 86)int ldso_find_dynamic(const unsigned char *file, unsigned long long fsize, unsigned long long *dyn_off, unsigned... -
ldso_vaddr_to_offset(function, line 92)int ldso_vaddr_to_offset(const unsigned char *file, unsigned long long fsize, unsigned long long va, unsigned long... -
ldso_segments(function, line 97)int ldso_segments(const unsigned char *file, unsigned long long fsize, LdsoSeg *segs, unsigned ncap, unsigned *nseg); -
ldso_scan_dynamic(function, line 103)int ldso_scan_dynamic(const unsigned char *file, unsigned long long fsize, unsigned long long dyn_off, unsigned long... -
ldso_sym_count(function, line 110)int ldso_sym_count(const unsigned char *file, unsigned long long fsize, unsigned long long hash_off, unsigned *nsyms); -
ldso_copy_str(function, line 116)int ldso_copy_str(const unsigned char *file, unsigned long long fsize, unsigned long long strtab_off, unsigned long... -
ldso_sym_lookup(function, line 124)int ldso_sym_lookup(const unsigned char *file, unsigned long long fsize, unsigned long long symtab_off, unsigned... -
ldso_rela_count(function, line 132)int ldso_rela_count(const LdsoDynInfo *info, unsigned *nrela); -
ldso_read_rela(function, line 137)int ldso_read_rela(const unsigned char *file, unsigned long long fsize, unsigned long long rela_off, unsigned nrela... -
ldso_basename(function, line 144)void ldso_basename(char *out, const char *src); -
LDSO_H(macro, line 15)#define LDSO_H -
LDSO_MAX_LIBS(macro, line 17)#define LDSO_MAX_LIBS -
LDSO_MAX_NEEDED(macro, line 18)#define LDSO_MAX_NEEDED -
LDSO_NAME_LEN(macro, line 19)#define LDSO_NAME_LEN -
LDSO_MAX_DYN(macro, line 20)#define LDSO_MAX_DYN -
LDSO_FILE_MAX(macro, line 21)#define LDSO_FILE_MAX -
LDSO_INO_BASE(macro, line 22)#define LDSO_INO_BASE -
LDSO_ET_EXEC(macro, line 24)#define LDSO_ET_EXEC -
LDSO_ET_DYN(macro, line 25)#define LDSO_ET_DYN -
LDSO_EM_X86_64(macro, line 26)#define LDSO_EM_X86_64 -
LDSO_PT_LOAD(macro, line 27)#define LDSO_PT_LOAD -
LDSO_PT_DYNAMIC(macro, line 28)#define LDSO_PT_DYNAMIC -
LDSO_PF_X(macro, line 29)#define LDSO_PF_X -
LDSO_DT_NULL(macro, line 31)#define LDSO_DT_NULL -
LDSO_DT_NEEDED(macro, line 32)#define LDSO_DT_NEEDED -
LDSO_DT_HASH(macro, line 33)#define LDSO_DT_HASH -
LDSO_DT_STRTAB(macro, line 34)#define LDSO_DT_STRTAB -
LDSO_DT_SYMTAB(macro, line 35)#define LDSO_DT_SYMTAB -
LDSO_DT_RELA(macro, line 36)#define LDSO_DT_RELA -
LDSO_DT_RELASZ(macro, line 37)#define LDSO_DT_RELASZ -
LDSO_DT_RELAENT(macro, line 38)#define LDSO_DT_RELAENT -
LDSO_DT_STRSZ(macro, line 39)#define LDSO_DT_STRSZ -
LDSO_DT_SYMENT(macro, line 40)#define LDSO_DT_SYMENT -
LDSO_DT_SONAME(macro, line 41)#define LDSO_DT_SONAME -
LDSO_R_GLOB_DAT(macro, line 43)#define LDSO_R_GLOB_DAT -
LDSO_R_JUMP_SLOT(macro, line 44)#define LDSO_R_JUMP_SLOT -
LDSO_STB_GLOBAL(macro, line 46)#define LDSO_STB_GLOBAL -
LDSO_STT_NOTYPE(macro, line 47)#define LDSO_STT_NOTYPE -
LDSO_STT_FUNC(macro, line 48)#define LDSO_STT_FUNC -
LDSO_SHN_UNDEF(macro, line 49)#define LDSO_SHN_UNDEF -
LDSO_SYM_SIZE(macro, line 50)#define LDSO_SYM_SIZE -
LDSO_RELA_SIZE(macro, line 51)#define LDSO_RELA_SIZE
-
- Imported by:
headers/kernel.h,kernel/ldso_parse.c,kernel/loader.c,kernel/mm/paging.c,tests/test_ldso.c
Next: KB_headers_p3.md
Generated offline by readmenator from commit cd87980b5eb5. Edits here are overwritten by readmenator . --rebuild.
Start
Wiki
- community_0_headers_kernel
- community_10_orphans
- community_1_progs_doomgeneric_d_englsh
- community_2_progs_src
- community_3_progs_doomgeneric_p_spec
- community_4_tools_tls_crypto
- community_5_headers_vga_fb
- community_6_progs_doomgeneric_net_defs
- community_7_headers_batch
- community_8_headers_tick
- community_9_tools_doom_pwad
- concepts
- queries
- REPORT
Agent Docs
- API
- API_p10
- API_p11
- API_p12
- API_p13
- API_p14
- API_p15
- API_p16
- API_p17
- API_p18
- API_p19
- API_p2
- API_p20
- API_p21
- API_p3
- API_p4
- API_p5
- API_p6
- API_p7
- API_p8
- API_p9
- ARCHITECTURE
- ARCHITECTURE_p2
- ARCHITECTURE_p3
- ARCHITECTURE_p4
- CONCEPTS
- GOTCHAS
- INDEX
- INDEX_p2
- KB_asm
- KB_boot
- KB_doomgeneric
- KB_doomgeneric_p10
- KB_doomgeneric_p11
- KB_doomgeneric_p12
- KB_doomgeneric_p2
- KB_doomgeneric_p3
- KB_doomgeneric_p4
- KB_doomgeneric_p5
- KB_doomgeneric_p6
- KB_doomgeneric_p7
- KB_doomgeneric_p8
- KB_doomgeneric_p9
- KB_drivers
- KB_drivers_p2
- KB_file
- KB_freedomui
- KB_fs
- KB_headers
- KB_headers_arch_x86
- KB_headers_drivers
- KB_headers_kernel
- KB_headers_p2
- KB_headers_p3
- KB_headers_p4
- KB_headers_p5
- KB_headers_p6
- KB_kernel
- KB_kernel_p2
- KB_kernel_p3
- KB_kernel_p4
- KB_lib
- KB_lisp
- KB_lua
- KB_mcp
- KB_minios
- KB_misc
- KB_misc_p2
- KB_misc_p3
- KB_mm
- KB_net
- KB_nuklear
- KB_pokemon
- KB_progs
- KB_quake2generic
- KB_root
- KB_src
- KB_src_p2
- KB_src_p3
- KB_tests
- KB_tests_p2
- KB_tls_u
- KB_tools
- KB_tools_p2
- KB_wl
- KB_x86
- MEMORY
- SECURITY
- SYMBOLS
- SYMBOLS_p10
- SYMBOLS_p11
- SYMBOLS_p12
- SYMBOLS_p13
- SYMBOLS_p14
- SYMBOLS_p15
- SYMBOLS_p16
- SYMBOLS_p17
- SYMBOLS_p18
- SYMBOLS_p19
- SYMBOLS_p2
- SYMBOLS_p20
- SYMBOLS_p21
- SYMBOLS_p22
- SYMBOLS_p23
- SYMBOLS_p24
- SYMBOLS_p25
- SYMBOLS_p26
- SYMBOLS_p27
- SYMBOLS_p3
- SYMBOLS_p4
- SYMBOLS_p5
- SYMBOLS_p6
- SYMBOLS_p7
- SYMBOLS_p8
- SYMBOLS_p9
Recipes