Full Code of thethumbler/Aquila for AI

master eb1d273218e5 cached
453 files
1.3 MB
431.1k tokens
2223 symbols
1 requests
Download .txt
Showing preview only (1,401K chars total). Download the full file or copy to clipboard to get everything.
Repository: thethumbler/Aquila
Branch: master
Commit: eb1d273218e5
Files: 453
Total size: 1.3 MB

Directory structure:
gitextract__96k71ly/

├── .gitignore
├── .gitlab-ci.yml
├── .travis.yml
├── LICENSE
├── Makefile
├── README.md
├── configs/
│   ├── clang.mk
│   ├── gcc.mk
│   ├── i386-pc.mk
│   ├── i386-quark.mk
│   ├── none.mk
│   ├── pcc.mk
│   └── x86_64-pc.mk
├── initrd/
│   ├── Makefile
│   ├── etc/
│   │   ├── font.tf
│   │   ├── hostname
│   │   ├── motd
│   │   ├── passwd
│   │   └── rc.init
│   ├── init/
│   │   ├── Makefile
│   │   └── init.c
│   └── usr/
│       ├── bin/
│       │   ├── p++
│       │   ├── pcc
│       │   └── pcpp
│       ├── libexec/
│       │   ├── ccom
│       │   ├── cpp
│       │   └── cxxcom
│       ├── share/
│       │   └── man/
│       │       └── man1/
│       │           ├── ccom.1
│       │           ├── cpp.1
│       │           ├── p++.1
│       │           ├── pcc.1
│       │           └── pcpp.1
│       └── test.c
├── iso/
│   └── boot/
│       └── grub/
│           └── grub.cfg
├── kernel/
│   ├── Makefile
│   ├── README.md
│   ├── arch/
│   │   ├── Build.mk
│   │   ├── Makefile
│   │   ├── arm/
│   │   │   ├── Build.mk
│   │   │   ├── include/
│   │   │   │   ├── core/
│   │   │   │   │   └── types.h
│   │   │   │   ├── cpu/
│   │   │   │   │   └── io.h
│   │   │   │   └── mm/
│   │   │   │       └── mm.h
│   │   │   ├── kernel.arm.ld
│   │   │   └── none.c
│   │   ├── i386/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   ├── boot/
│   │   │   │   ├── Build.mk
│   │   │   │   ├── Makefile
│   │   │   │   ├── init.c
│   │   │   │   ├── multiboot.S
│   │   │   │   ├── sys.S
│   │   │   │   └── x86_64_bootstrap.S
│   │   │   ├── cpu/
│   │   │   │   ├── Build.mk
│   │   │   │   ├── Makefile
│   │   │   │   ├── arith.c
│   │   │   │   ├── cpu.S
│   │   │   │   ├── cpu.h
│   │   │   │   ├── fpu.c
│   │   │   │   ├── gdt.c
│   │   │   │   ├── idt.c
│   │   │   │   ├── init.c
│   │   │   │   ├── isr.c
│   │   │   │   ├── smp.S
│   │   │   │   └── trace.c
│   │   │   ├── earlycon/
│   │   │   │   ├── Build.mk
│   │   │   │   ├── Makefile
│   │   │   │   ├── earlycon.c
│   │   │   │   ├── fb.c
│   │   │   │   ├── font.h
│   │   │   │   ├── uart.c
│   │   │   │   └── vga.c
│   │   │   ├── include/
│   │   │   │   ├── boot/
│   │   │   │   │   ├── boot.h
│   │   │   │   │   └── multiboot.h
│   │   │   │   ├── config.h
│   │   │   │   ├── core/
│   │   │   │   │   ├── _string.h
│   │   │   │   │   ├── arch.h
│   │   │   │   │   ├── panic.h
│   │   │   │   │   ├── platform.h
│   │   │   │   │   └── system.h
│   │   │   │   ├── cpu/
│   │   │   │   │   ├── cpu.h
│   │   │   │   │   ├── cpuid.h
│   │   │   │   │   ├── io.h
│   │   │   │   │   ├── msr.h
│   │   │   │   │   ├── pit.h
│   │   │   │   │   └── sdt.h
│   │   │   │   ├── mm/
│   │   │   │   │   ├── mm.h
│   │   │   │   │   └── pmap.h
│   │   │   │   └── platform/
│   │   │   │       └── misc.h
│   │   │   ├── kernel.i386.ld
│   │   │   ├── kernel.x86_64.ld
│   │   │   ├── mm/
│   │   │   │   ├── Build.mk
│   │   │   │   ├── Makefile
│   │   │   │   ├── frame_utils.h
│   │   │   │   ├── i386.c
│   │   │   │   ├── i386.h
│   │   │   │   ├── mm.c
│   │   │   │   ├── page_utils.h
│   │   │   │   ├── x86_64.c
│   │   │   │   └── x86_64.h
│   │   │   ├── platform/
│   │   │   │   ├── Build.mk
│   │   │   │   ├── Makefile
│   │   │   │   ├── misc/
│   │   │   │   │   ├── Build.mk
│   │   │   │   │   ├── Makefile
│   │   │   │   │   ├── acpi.c
│   │   │   │   │   ├── cmos.c
│   │   │   │   │   ├── hpet.c
│   │   │   │   │   ├── i8042.c
│   │   │   │   │   ├── pic.c
│   │   │   │   │   └── pit.c
│   │   │   │   ├── pc/
│   │   │   │   │   ├── Build.mk
│   │   │   │   │   ├── Makefile
│   │   │   │   │   ├── init.c
│   │   │   │   │   └── reboot.c
│   │   │   │   └── quark/
│   │   │   │       ├── Build.mk
│   │   │   │       ├── include/
│   │   │   │       │   └── chipset/
│   │   │   │       │       ├── legacy_bridge.h
│   │   │   │       │       ├── root_complex.h
│   │   │   │       │       └── system.h
│   │   │   │       ├── init.c
│   │   │   │       └── legacy/
│   │   │   │           ├── Build.mk
│   │   │   │           ├── bridge.c
│   │   │   │           ├── interrupt.c
│   │   │   │           └── root_complex.c
│   │   │   └── sys/
│   │   │       ├── Build.mk
│   │   │       ├── Makefile
│   │   │       ├── execve.c
│   │   │       ├── fork.c
│   │   │       ├── proc.c
│   │   │       ├── sched.c
│   │   │       ├── signal.c
│   │   │       ├── sys.h
│   │   │       ├── syscall.c
│   │   │       └── thread.c
│   │   └── none/
│   │       ├── Build.mk
│   │       ├── include/
│   │       │   ├── core/
│   │       │   │   └── types.h
│   │       │   ├── cpu/
│   │       │   │   └── io.h
│   │       │   └── mm/
│   │       │       └── mm.h
│   │       ├── kernel.none.ld
│   │       └── none.c
│   ├── core/
│   │   ├── Build.mk
│   │   ├── Makefile
│   │   ├── kargs.c
│   │   ├── main.c
│   │   ├── module.c
│   │   ├── printk.c
│   │   ├── snprintf.c
│   │   └── time.c
│   ├── dev/
│   │   ├── Build.mk
│   │   ├── Makefile
│   │   ├── ata/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   ├── ata.c
│   │   │   ├── ata.h
│   │   │   └── pio.c
│   │   ├── fb/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   ├── fbdev/
│   │   │   │   ├── Build.mk
│   │   │   │   ├── Makefile
│   │   │   │   └── fbdev.c
│   │   │   └── vesa/
│   │   │       ├── Build.mk
│   │   │       ├── Makefile
│   │   │       └── vesa.c
│   │   ├── fdc/
│   │   │   ├── Build.mk
│   │   │   ├── fdc.c
│   │   │   ├── fdc_82077AA.c
│   │   │   └── fdc_82077AA.h
│   │   ├── kbd/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   ├── kbd.c
│   │   │   └── ps2kbd.c
│   │   ├── kdev.c
│   │   ├── mem/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   ├── kmsg.c
│   │   │   ├── memdev.c
│   │   │   ├── memdev.h
│   │   │   ├── null.c
│   │   │   └── zero.c
│   │   ├── mouse/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   └── ps2mouse.c
│   │   ├── pci/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   └── pci.c
│   │   ├── rd/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   └── ramdisk.c
│   │   └── tty/
│   │       ├── Build.mk
│   │       ├── Makefile
│   │       ├── console/
│   │       │   ├── Build.mk
│   │       │   ├── Makefile
│   │       │   └── console.c
│   │       ├── generic.c
│   │       ├── pty/
│   │       │   ├── Build.mk
│   │       │   ├── Makefile
│   │       │   └── pty.c
│   │       ├── tty.c
│   │       └── uart/
│   │           ├── 8250/
│   │           │   ├── 8250.c
│   │           │   ├── Build.mk
│   │           │   └── Makefile
│   │           ├── Build.mk
│   │           ├── Makefile
│   │           └── uart.c
│   ├── fs/
│   │   ├── Build.mk
│   │   ├── Makefile
│   │   ├── bcache.c
│   │   ├── close.c
│   │   ├── devfs/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   └── devfs.c
│   │   ├── devpts/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   └── devpts.c
│   │   ├── ext2/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   ├── block.c
│   │   │   ├── dentry.c
│   │   │   ├── ext2.c
│   │   │   ├── ext2.h
│   │   │   ├── inode.c
│   │   │   ├── super.c
│   │   │   └── vops.c
│   │   ├── fops.c
│   │   ├── initramfs/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   ├── cpio/
│   │   │   │   ├── Build.mk
│   │   │   │   ├── Makefile
│   │   │   │   ├── cpio.c
│   │   │   │   └── cpio.h
│   │   │   └── initramfs.c
│   │   ├── ioctl.c
│   │   ├── lookup.c
│   │   ├── minix/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   ├── block.c
│   │   │   ├── dentry.c
│   │   │   ├── inode.c
│   │   │   ├── minix.c
│   │   │   ├── minix.h
│   │   │   ├── super.c
│   │   │   └── vops.c
│   │   ├── mknod.c
│   │   ├── mount.c
│   │   ├── pipe.c
│   │   ├── posix/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   ├── close.c
│   │   │   ├── helpers.c
│   │   │   ├── ioctl.c
│   │   │   ├── lseek.c
│   │   │   ├── open.c
│   │   │   ├── read.c
│   │   │   ├── readdir.c
│   │   │   ├── trunc.c
│   │   │   └── write.c
│   │   ├── procfs/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   └── procfs.c
│   │   ├── pseudofs/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   └── pseudofs.c
│   │   ├── read.c
│   │   ├── readdir.c
│   │   ├── rofs.c
│   │   ├── stat.c
│   │   ├── sync.c
│   │   ├── tmpfs/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   └── tmpfs.c
│   │   ├── trunc.c
│   │   ├── unlink.c
│   │   ├── vcache.c
│   │   ├── vfs.c
│   │   ├── vm_object.c
│   │   ├── vops.c
│   │   └── write.c
│   ├── include/
│   │   ├── bits/
│   │   │   ├── dirent.h
│   │   │   ├── errno.h
│   │   │   ├── fcntl.h
│   │   │   ├── mman.h
│   │   │   └── utsname.h
│   │   ├── boot/
│   │   │   └── boot.h
│   │   ├── config.h
│   │   ├── console/
│   │   │   └── earlycon.h
│   │   ├── core/
│   │   │   ├── arch.h
│   │   │   ├── assert.h
│   │   │   ├── kargs.h
│   │   │   ├── module.h
│   │   │   ├── panic.h
│   │   │   ├── printk.h
│   │   │   ├── qsort.h
│   │   │   ├── string.h
│   │   │   ├── system.h
│   │   │   ├── time.h
│   │   │   └── types.h
│   │   ├── cpu/
│   │   │   ├── cpu.h
│   │   │   └── io.h
│   │   ├── dev/
│   │   │   ├── console.h
│   │   │   ├── dev.h
│   │   │   ├── fbdev.h
│   │   │   ├── kbd.h
│   │   │   ├── pci.h
│   │   │   ├── ramdev.h
│   │   │   ├── tty.h
│   │   │   ├── ttydev.h
│   │   │   └── uart.h
│   │   ├── ds/
│   │   │   ├── bitmap.h
│   │   │   ├── buddy.h
│   │   │   ├── ds.dox
│   │   │   ├── hashmap.h
│   │   │   ├── queue.h
│   │   │   └── ringbuf.h
│   │   ├── fs/
│   │   │   ├── bcache.h
│   │   │   ├── devfs.h
│   │   │   ├── devpts.h
│   │   │   ├── initramfs.h
│   │   │   ├── ioctl.h
│   │   │   ├── mbr.h
│   │   │   ├── pipe.h
│   │   │   ├── posix.h
│   │   │   ├── pseudofs.h
│   │   │   ├── rofs.h
│   │   │   ├── stat.h
│   │   │   ├── termios.h
│   │   │   ├── tmpfs.h
│   │   │   ├── vcache.h
│   │   │   └── vfs.h
│   │   ├── mm/
│   │   │   ├── buddy.h
│   │   │   ├── heap.h
│   │   │   ├── kvmem.h
│   │   │   ├── mm.h
│   │   │   ├── pmap.h
│   │   │   └── vm.h
│   │   ├── net/
│   │   │   └── socket.h
│   │   ├── stdarg.h
│   │   ├── stddef.h
│   │   ├── stdint.h
│   │   ├── sys/
│   │   │   ├── binfmt.h
│   │   │   ├── elf.h
│   │   │   ├── proc.h
│   │   │   ├── sched.h
│   │   │   ├── signal.h
│   │   │   ├── syscall.h
│   │   │   └── thread.h
│   │   └── video/
│   │       ├── vbe.h
│   │       └── vesa.h
│   ├── mm/
│   │   ├── Build.mk
│   │   ├── Makefile
│   │   ├── buddy.c
│   │   ├── fault.c
│   │   ├── kvmem.c
│   │   ├── mm.c
│   │   ├── vm_anon.c
│   │   ├── vm_entry.c
│   │   ├── vm_object.c
│   │   ├── vm_space.c
│   │   └── vmm.c
│   ├── net/
│   │   ├── Build.mk
│   │   ├── Makefile
│   │   ├── socket.c
│   │   └── unix/
│   │       ├── Build.mk
│   │       ├── Makefile
│   │       ├── unix.c
│   │       └── unix.h
│   └── sys/
│       ├── Build.mk
│       ├── Makefile
│       ├── binfmt/
│       │   ├── Build.mk
│       │   ├── Makefile
│       │   ├── binfmt.c
│       │   └── elf.c
│       ├── execve.c
│       ├── fork.c
│       ├── proc.c
│       ├── sched.c
│       ├── signal.c
│       ├── syscall.c
│       └── thread.c
├── loader/
│   ├── grub-legacy/
│   │   └── boot/
│   │       └── grub/
│   │           └── menu.lst
│   └── grub2/
│       └── boot/
│           └── grub/
│               └── grub.cfg
└── system/
    ├── Makefile
    ├── aqbox/
    │   ├── Build.mk
    │   ├── Makefile
    │   ├── aqbox.c
    │   ├── extra/
    │   │   ├── Build.mk
    │   │   ├── Makefile
    │   │   ├── bim.c
    │   │   ├── clear.c
    │   │   ├── mknod.c
    │   │   ├── mktemp.c
    │   │   ├── readmbr.c
    │   │   ├── stat.c
    │   │   ├── truncate.c
    │   │   └── vmstat.c
    │   ├── include/
    │   │   ├── aq_applets.h
    │   │   └── aqbox.h
    │   ├── posix/
    │   │   ├── Build.mk
    │   │   ├── Makefile
    │   │   ├── cat.c
    │   │   ├── date.c
    │   │   ├── echo.c
    │   │   ├── env.c
    │   │   ├── kill.c
    │   │   ├── ls.c
    │   │   ├── mkdir.c
    │   │   ├── ps.c
    │   │   ├── pwd.c
    │   │   ├── sh.c
    │   │   ├── touch.c
    │   │   ├── uname.c
    │   │   └── unlink.c
    │   └── sys/
    │       ├── Build.mk
    │       ├── Makefile
    │       ├── getty.c
    │       ├── login.c
    │       ├── mount.c
    │       └── reboot.c
    ├── fbterm/
    │   ├── Build.mk
    │   ├── Makefile
    │   ├── aqkb.c
    │   ├── fb.c
    │   ├── fbterm.c
    │   ├── font.c
    │   ├── include/
    │   │   ├── aqkb.h
    │   │   ├── config.h
    │   │   ├── fb.h
    │   │   ├── fbterm.h
    │   │   ├── tinyfont.h
    │   │   ├── vterm.h
    │   │   └── vterm_keycodes.h
    │   ├── libvterm/
    │   │   ├── Build.mk
    │   │   ├── Makefile
    │   │   ├── encoding/
    │   │   │   ├── DECdrawing.inc
    │   │   │   ├── DECdrawing.tbl
    │   │   │   ├── uk.inc
    │   │   │   └── uk.tbl
    │   │   ├── encoding.c
    │   │   ├── keyboard.c
    │   │   ├── mouse.c
    │   │   ├── parser.c
    │   │   ├── pen.c
    │   │   ├── rect.h
    │   │   ├── screen.c
    │   │   ├── state.c
    │   │   ├── unicode.c
    │   │   ├── utf8.h
    │   │   ├── vterm.c
    │   │   └── vterm_internal.h
    │   └── nanojpeg.c
    ├── kilo/
    │   ├── Build.mk
    │   ├── LICENSE
    │   ├── Makefile
    │   ├── README.md
    │   └── kilo.c
    └── scripts/
        └── gen.pl

================================================
FILE CONTENTS
================================================

================================================
FILE: .gitignore
================================================
*.o
*.iso
*.elf
*.img

tools/
graph.sh
tags
mnt/

build-tools/*
!build-tools/build.sh
!build-tools/aquila/
!build-tools/patches/

ramdisk/sysroot
ramdisk/out

system/usr
system/nuklear/nuklear
system/nuklear/libnk.a
system/fbterm/fbterm
system/aqbox/aqbox


================================================
FILE: .gitlab-ci.yml
================================================
image: manwar/aquila

build:
  stage: build
  before_script:
    - apt update && apt -y install make cpio texinfo grub-pc-bin xorriso wget
  script:
    - export PATH=$PATH:/opt/aquila/bin
    - export TRAVIS_BUILD_DIR=$(pwd)
    - make aquila.iso -j$(nproc)
  artifacts:
    paths:
      - aquila.iso


================================================
FILE: .travis.yml
================================================
language: c
before_install:
  - sudo apt-get update -qq
  - sudo apt-get install -qq texinfo grub-pc-bin xorriso
install:
  - cd build-tools && bash build.sh && cd ..
cache:
  directories:
    # Cache Packages
  - build-tools/pkgs
    # And unpacked directories
  - build-tools/binutils-2.28
  - build-tools/gcc-7.3.0
  - build-tools/autoconf-2.69
  - build-tools/automake-1.12.1
    # And gcc cross compiler
  - build-tools/sysroot
script:
  - make aquila.iso
deploy:
  provider: releases
  api_key:
    secure: aFJAuaPBhCn7R+4Ymeu12E0WapPSQFDljtCrqFOSsq/vCOJ7QeXuKp0P6XEXEPpZ2mv4V9GVnGHjWflWCH1frWHbCCSZsWkR36Rxlv0sY8ufoMjWeJqkcn1BNUVluGoZSjXyYp9jzFei6kbkk4jsoh3ipfFj8VK/i3qIZuUl7DAz70y8cg9z1Ue3FGgSq010+QI6iH/+hYssn1hJgtyOLmM8Fe4rRADBeAZQ8XFohqj1yTQRCAyVnL96OGes5mBGfYSikwU8n6errx78FI9ei7CkZEqZtqwoBxyX9XKbCo5TcdIITZ/7vXfiEf/3u/G6623M5pPPXRrxZfWcU+Oon20eQU9CKlGnzaMlGXTU6KtqeT53ullkCBC3X6dWwflcFXel/rpSXfyJY5ihllB4CpD/kXWSEZaFm/ip2II+MrkIK+qm469WArMNWvx7NqdC9BujEJ2phrT667qPzoUe+O7XCPxlWrcHJa8veo2GN1f2O8pH1PEvHPMWZfK0Z9N3ZKpLLn3P9BtMh0Chw0Cy+qMEa9Q3joRGBrQAzVUhGcCl9RsSWb89W7v1kvc6C9oiGO1Q+SRcdJtWkFRsjqGGowbzocjakPgJ8NaEztsiZvM0Om7CB0HeJR1fNA2i4NWfLx3GKt81v8/ld4zWjuukIkzxshuXkRqrcYB50cgHXGg=
  file: aquila.iso
  skip_cleanup: true
  on:
    repo: mohamed-anwar/Aquila
    tags: true


================================================
FILE: LICENSE
================================================
                    GNU GENERAL PUBLIC LICENSE
                       Version 3, 29 June 2007

 Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
 Everyone is permitted to copy and distribute verbatim copies
 of this license document, but changing it is not allowed.

                            Preamble

  The GNU General Public License is a free, copyleft license for
software and other kinds of works.

  The licenses for most software and other practical works are designed
to take away your freedom to share and change the works.  By contrast,
the GNU General Public License is intended to guarantee your freedom to
share and change all versions of a program--to make sure it remains free
software for all its users.  We, the Free Software Foundation, use the
GNU General Public License for most of our software; it applies also to
any other work released this way by its authors.  You can apply it to
your programs, too.

  When we speak of free software, we are referring to freedom, not
price.  Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
them if you wish), that you receive source code or can get it if you
want it, that you can change the software or use pieces of it in new
free programs, and that you know you can do these things.

  To protect your rights, we need to prevent others from denying you
these rights or asking you to surrender the rights.  Therefore, you have
certain responsibilities if you distribute copies of the software, or if
you modify it: responsibilities to respect the freedom of others.

  For example, if you distribute copies of such a program, whether
gratis or for a fee, you must pass on to the recipients the same
freedoms that you received.  You must make sure that they, too, receive
or can get the source code.  And you must show them these terms so they
know their rights.

  Developers that use the GNU GPL protect your rights with two steps:
(1) assert copyright on the software, and (2) offer you this License
giving you legal permission to copy, distribute and/or modify it.

  For the developers' and authors' protection, the GPL clearly explains
that there is no warranty for this free software.  For both users' and
authors' sake, the GPL requires that modified versions be marked as
changed, so that their problems will not be attributed erroneously to
authors of previous versions.

  Some devices are designed to deny users access to install or run
modified versions of the software inside them, although the manufacturer
can do so.  This is fundamentally incompatible with the aim of
protecting users' freedom to change the software.  The systematic
pattern of such abuse occurs in the area of products for individuals to
use, which is precisely where it is most unacceptable.  Therefore, we
have designed this version of the GPL to prohibit the practice for those
products.  If such problems arise substantially in other domains, we
stand ready to extend this provision to those domains in future versions
of the GPL, as needed to protect the freedom of users.

  Finally, every program is threatened constantly by software patents.
States should not allow patents to restrict development and use of
software on general-purpose computers, but in those that do, we wish to
avoid the special danger that patents applied to a free program could
make it effectively proprietary.  To prevent this, the GPL assures that
patents cannot be used to render the program non-free.

  The precise terms and conditions for copying, distribution and
modification follow.

                       TERMS AND CONDITIONS

  0. Definitions.

  "This License" refers to version 3 of the GNU General Public License.

  "Copyright" also means copyright-like laws that apply to other kinds of
works, such as semiconductor masks.

  "The Program" refers to any copyrightable work licensed under this
License.  Each licensee is addressed as "you".  "Licensees" and
"recipients" may be individuals or organizations.

  To "modify" a work means to copy from or adapt all or part of the work
in a fashion requiring copyright permission, other than the making of an
exact copy.  The resulting work is called a "modified version" of the
earlier work or a work "based on" the earlier work.

  A "covered work" means either the unmodified Program or a work based
on the Program.

  To "propagate" a work means to do anything with it that, without
permission, would make you directly or secondarily liable for
infringement under applicable copyright law, except executing it on a
computer or modifying a private copy.  Propagation includes copying,
distribution (with or without modification), making available to the
public, and in some countries other activities as well.

  To "convey" a work means any kind of propagation that enables other
parties to make or receive copies.  Mere interaction with a user through
a computer network, with no transfer of a copy, is not conveying.

  An interactive user interface displays "Appropriate Legal Notices"
to the extent that it includes a convenient and prominently visible
feature that (1) displays an appropriate copyright notice, and (2)
tells the user that there is no warranty for the work (except to the
extent that warranties are provided), that licensees may convey the
work under this License, and how to view a copy of this License.  If
the interface presents a list of user commands or options, such as a
menu, a prominent item in the list meets this criterion.

  1. Source Code.

  The "source code" for a work means the preferred form of the work
for making modifications to it.  "Object code" means any non-source
form of a work.

  A "Standard Interface" means an interface that either is an official
standard defined by a recognized standards body, or, in the case of
interfaces specified for a particular programming language, one that
is widely used among developers working in that language.

  The "System Libraries" of an executable work include anything, other
than the work as a whole, that (a) is included in the normal form of
packaging a Major Component, but which is not part of that Major
Component, and (b) serves only to enable use of the work with that
Major Component, or to implement a Standard Interface for which an
implementation is available to the public in source code form.  A
"Major Component", in this context, means a major essential component
(kernel, window system, and so on) of the specific operating system
(if any) on which the executable work runs, or a compiler used to
produce the work, or an object code interpreter used to run it.

  The "Corresponding Source" for a work in object code form means all
the source code needed to generate, install, and (for an executable
work) run the object code and to modify the work, including scripts to
control those activities.  However, it does not include the work's
System Libraries, or general-purpose tools or generally available free
programs which are used unmodified in performing those activities but
which are not part of the work.  For example, Corresponding Source
includes interface definition files associated with source files for
the work, and the source code for shared libraries and dynamically
linked subprograms that the work is specifically designed to require,
such as by intimate data communication or control flow between those
subprograms and other parts of the work.

  The Corresponding Source need not include anything that users
can regenerate automatically from other parts of the Corresponding
Source.

  The Corresponding Source for a work in source code form is that
same work.

  2. Basic Permissions.

  All rights granted under this License are granted for the term of
copyright on the Program, and are irrevocable provided the stated
conditions are met.  This License explicitly affirms your unlimited
permission to run the unmodified Program.  The output from running a
covered work is covered by this License only if the output, given its
content, constitutes a covered work.  This License acknowledges your
rights of fair use or other equivalent, as provided by copyright law.

  You may make, run and propagate covered works that you do not
convey, without conditions so long as your license otherwise remains
in force.  You may convey covered works to others for the sole purpose
of having them make modifications exclusively for you, or provide you
with facilities for running those works, provided that you comply with
the terms of this License in conveying all material for which you do
not control copyright.  Those thus making or running the covered works
for you must do so exclusively on your behalf, under your direction
and control, on terms that prohibit them from making any copies of
your copyrighted material outside their relationship with you.

  Conveying under any other circumstances is permitted solely under
the conditions stated below.  Sublicensing is not allowed; section 10
makes it unnecessary.

  3. Protecting Users' Legal Rights From Anti-Circumvention Law.

  No covered work shall be deemed part of an effective technological
measure under any applicable law fulfilling obligations under article
11 of the WIPO copyright treaty adopted on 20 December 1996, or
similar laws prohibiting or restricting circumvention of such
measures.

  When you convey a covered work, you waive any legal power to forbid
circumvention of technological measures to the extent such circumvention
is effected by exercising rights under this License with respect to
the covered work, and you disclaim any intention to limit operation or
modification of the work as a means of enforcing, against the work's
users, your or third parties' legal rights to forbid circumvention of
technological measures.

  4. Conveying Verbatim Copies.

  You may convey verbatim copies of the Program's source code as you
receive it, in any medium, provided that you conspicuously and
appropriately publish on each copy an appropriate copyright notice;
keep intact all notices stating that this License and any
non-permissive terms added in accord with section 7 apply to the code;
keep intact all notices of the absence of any warranty; and give all
recipients a copy of this License along with the Program.

  You may charge any price or no price for each copy that you convey,
and you may offer support or warranty protection for a fee.

  5. Conveying Modified Source Versions.

  You may convey a work based on the Program, or the modifications to
produce it from the Program, in the form of source code under the
terms of section 4, provided that you also meet all of these conditions:

    a) The work must carry prominent notices stating that you modified
    it, and giving a relevant date.

    b) The work must carry prominent notices stating that it is
    released under this License and any conditions added under section
    7.  This requirement modifies the requirement in section 4 to
    "keep intact all notices".

    c) You must license the entire work, as a whole, under this
    License to anyone who comes into possession of a copy.  This
    License will therefore apply, along with any applicable section 7
    additional terms, to the whole of the work, and all its parts,
    regardless of how they are packaged.  This License gives no
    permission to license the work in any other way, but it does not
    invalidate such permission if you have separately received it.

    d) If the work has interactive user interfaces, each must display
    Appropriate Legal Notices; however, if the Program has interactive
    interfaces that do not display Appropriate Legal Notices, your
    work need not make them do so.

  A compilation of a covered work with other separate and independent
works, which are not by their nature extensions of the covered work,
and which are not combined with it such as to form a larger program,
in or on a volume of a storage or distribution medium, is called an
"aggregate" if the compilation and its resulting copyright are not
used to limit the access or legal rights of the compilation's users
beyond what the individual works permit.  Inclusion of a covered work
in an aggregate does not cause this License to apply to the other
parts of the aggregate.

  6. Conveying Non-Source Forms.

  You may convey a covered work in object code form under the terms
of sections 4 and 5, provided that you also convey the
machine-readable Corresponding Source under the terms of this License,
in one of these ways:

    a) Convey the object code in, or embodied in, a physical product
    (including a physical distribution medium), accompanied by the
    Corresponding Source fixed on a durable physical medium
    customarily used for software interchange.

    b) Convey the object code in, or embodied in, a physical product
    (including a physical distribution medium), accompanied by a
    written offer, valid for at least three years and valid for as
    long as you offer spare parts or customer support for that product
    model, to give anyone who possesses the object code either (1) a
    copy of the Corresponding Source for all the software in the
    product that is covered by this License, on a durable physical
    medium customarily used for software interchange, for a price no
    more than your reasonable cost of physically performing this
    conveying of source, or (2) access to copy the
    Corresponding Source from a network server at no charge.

    c) Convey individual copies of the object code with a copy of the
    written offer to provide the Corresponding Source.  This
    alternative is allowed only occasionally and noncommercially, and
    only if you received the object code with such an offer, in accord
    with subsection 6b.

    d) Convey the object code by offering access from a designated
    place (gratis or for a charge), and offer equivalent access to the
    Corresponding Source in the same way through the same place at no
    further charge.  You need not require recipients to copy the
    Corresponding Source along with the object code.  If the place to
    copy the object code is a network server, the Corresponding Source
    may be on a different server (operated by you or a third party)
    that supports equivalent copying facilities, provided you maintain
    clear directions next to the object code saying where to find the
    Corresponding Source.  Regardless of what server hosts the
    Corresponding Source, you remain obligated to ensure that it is
    available for as long as needed to satisfy these requirements.

    e) Convey the object code using peer-to-peer transmission, provided
    you inform other peers where the object code and Corresponding
    Source of the work are being offered to the general public at no
    charge under subsection 6d.

  A separable portion of the object code, whose source code is excluded
from the Corresponding Source as a System Library, need not be
included in conveying the object code work.

  A "User Product" is either (1) a "consumer product", which means any
tangible personal property which is normally used for personal, family,
or household purposes, or (2) anything designed or sold for incorporation
into a dwelling.  In determining whether a product is a consumer product,
doubtful cases shall be resolved in favor of coverage.  For a particular
product received by a particular user, "normally used" refers to a
typical or common use of that class of product, regardless of the status
of the particular user or of the way in which the particular user
actually uses, or expects or is expected to use, the product.  A product
is a consumer product regardless of whether the product has substantial
commercial, industrial or non-consumer uses, unless such uses represent
the only significant mode of use of the product.

  "Installation Information" for a User Product means any methods,
procedures, authorization keys, or other information required to install
and execute modified versions of a covered work in that User Product from
a modified version of its Corresponding Source.  The information must
suffice to ensure that the continued functioning of the modified object
code is in no case prevented or interfered with solely because
modification has been made.

  If you convey an object code work under this section in, or with, or
specifically for use in, a User Product, and the conveying occurs as
part of a transaction in which the right of possession and use of the
User Product is transferred to the recipient in perpetuity or for a
fixed term (regardless of how the transaction is characterized), the
Corresponding Source conveyed under this section must be accompanied
by the Installation Information.  But this requirement does not apply
if neither you nor any third party retains the ability to install
modified object code on the User Product (for example, the work has
been installed in ROM).

  The requirement to provide Installation Information does not include a
requirement to continue to provide support service, warranty, or updates
for a work that has been modified or installed by the recipient, or for
the User Product in which it has been modified or installed.  Access to a
network may be denied when the modification itself materially and
adversely affects the operation of the network or violates the rules and
protocols for communication across the network.

  Corresponding Source conveyed, and Installation Information provided,
in accord with this section must be in a format that is publicly
documented (and with an implementation available to the public in
source code form), and must require no special password or key for
unpacking, reading or copying.

  7. Additional Terms.

  "Additional permissions" are terms that supplement the terms of this
License by making exceptions from one or more of its conditions.
Additional permissions that are applicable to the entire Program shall
be treated as though they were included in this License, to the extent
that they are valid under applicable law.  If additional permissions
apply only to part of the Program, that part may be used separately
under those permissions, but the entire Program remains governed by
this License without regard to the additional permissions.

  When you convey a copy of a covered work, you may at your option
remove any additional permissions from that copy, or from any part of
it.  (Additional permissions may be written to require their own
removal in certain cases when you modify the work.)  You may place
additional permissions on material, added by you to a covered work,
for which you have or can give appropriate copyright permission.

  Notwithstanding any other provision of this License, for material you
add to a covered work, you may (if authorized by the copyright holders of
that material) supplement the terms of this License with terms:

    a) Disclaiming warranty or limiting liability differently from the
    terms of sections 15 and 16 of this License; or

    b) Requiring preservation of specified reasonable legal notices or
    author attributions in that material or in the Appropriate Legal
    Notices displayed by works containing it; or

    c) Prohibiting misrepresentation of the origin of that material, or
    requiring that modified versions of such material be marked in
    reasonable ways as different from the original version; or

    d) Limiting the use for publicity purposes of names of licensors or
    authors of the material; or

    e) Declining to grant rights under trademark law for use of some
    trade names, trademarks, or service marks; or

    f) Requiring indemnification of licensors and authors of that
    material by anyone who conveys the material (or modified versions of
    it) with contractual assumptions of liability to the recipient, for
    any liability that these contractual assumptions directly impose on
    those licensors and authors.

  All other non-permissive additional terms are considered "further
restrictions" within the meaning of section 10.  If the Program as you
received it, or any part of it, contains a notice stating that it is
governed by this License along with a term that is a further
restriction, you may remove that term.  If a license document contains
a further restriction but permits relicensing or conveying under this
License, you may add to a covered work material governed by the terms
of that license document, provided that the further restriction does
not survive such relicensing or conveying.

  If you add terms to a covered work in accord with this section, you
must place, in the relevant source files, a statement of the
additional terms that apply to those files, or a notice indicating
where to find the applicable terms.

  Additional terms, permissive or non-permissive, may be stated in the
form of a separately written license, or stated as exceptions;
the above requirements apply either way.

  8. Termination.

  You may not propagate or modify a covered work except as expressly
provided under this License.  Any attempt otherwise to propagate or
modify it is void, and will automatically terminate your rights under
this License (including any patent licenses granted under the third
paragraph of section 11).

  However, if you cease all violation of this License, then your
license from a particular copyright holder is reinstated (a)
provisionally, unless and until the copyright holder explicitly and
finally terminates your license, and (b) permanently, if the copyright
holder fails to notify you of the violation by some reasonable means
prior to 60 days after the cessation.

  Moreover, your license from a particular copyright holder is
reinstated permanently if the copyright holder notifies you of the
violation by some reasonable means, this is the first time you have
received notice of violation of this License (for any work) from that
copyright holder, and you cure the violation prior to 30 days after
your receipt of the notice.

  Termination of your rights under this section does not terminate the
licenses of parties who have received copies or rights from you under
this License.  If your rights have been terminated and not permanently
reinstated, you do not qualify to receive new licenses for the same
material under section 10.

  9. Acceptance Not Required for Having Copies.

  You are not required to accept this License in order to receive or
run a copy of the Program.  Ancillary propagation of a covered work
occurring solely as a consequence of using peer-to-peer transmission
to receive a copy likewise does not require acceptance.  However,
nothing other than this License grants you permission to propagate or
modify any covered work.  These actions infringe copyright if you do
not accept this License.  Therefore, by modifying or propagating a
covered work, you indicate your acceptance of this License to do so.

  10. Automatic Licensing of Downstream Recipients.

  Each time you convey a covered work, the recipient automatically
receives a license from the original licensors, to run, modify and
propagate that work, subject to this License.  You are not responsible
for enforcing compliance by third parties with this License.

  An "entity transaction" is a transaction transferring control of an
organization, or substantially all assets of one, or subdividing an
organization, or merging organizations.  If propagation of a covered
work results from an entity transaction, each party to that
transaction who receives a copy of the work also receives whatever
licenses to the work the party's predecessor in interest had or could
give under the previous paragraph, plus a right to possession of the
Corresponding Source of the work from the predecessor in interest, if
the predecessor has it or can get it with reasonable efforts.

  You may not impose any further restrictions on the exercise of the
rights granted or affirmed under this License.  For example, you may
not impose a license fee, royalty, or other charge for exercise of
rights granted under this License, and you may not initiate litigation
(including a cross-claim or counterclaim in a lawsuit) alleging that
any patent claim is infringed by making, using, selling, offering for
sale, or importing the Program or any portion of it.

  11. Patents.

  A "contributor" is a copyright holder who authorizes use under this
License of the Program or a work on which the Program is based.  The
work thus licensed is called the contributor's "contributor version".

  A contributor's "essential patent claims" are all patent claims
owned or controlled by the contributor, whether already acquired or
hereafter acquired, that would be infringed by some manner, permitted
by this License, of making, using, or selling its contributor version,
but do not include claims that would be infringed only as a
consequence of further modification of the contributor version.  For
purposes of this definition, "control" includes the right to grant
patent sublicenses in a manner consistent with the requirements of
this License.

  Each contributor grants you a non-exclusive, worldwide, royalty-free
patent license under the contributor's essential patent claims, to
make, use, sell, offer for sale, import and otherwise run, modify and
propagate the contents of its contributor version.

  In the following three paragraphs, a "patent license" is any express
agreement or commitment, however denominated, not to enforce a patent
(such as an express permission to practice a patent or covenant not to
sue for patent infringement).  To "grant" such a patent license to a
party means to make such an agreement or commitment not to enforce a
patent against the party.

  If you convey a covered work, knowingly relying on a patent license,
and the Corresponding Source of the work is not available for anyone
to copy, free of charge and under the terms of this License, through a
publicly available network server or other readily accessible means,
then you must either (1) cause the Corresponding Source to be so
available, or (2) arrange to deprive yourself of the benefit of the
patent license for this particular work, or (3) arrange, in a manner
consistent with the requirements of this License, to extend the patent
license to downstream recipients.  "Knowingly relying" means you have
actual knowledge that, but for the patent license, your conveying the
covered work in a country, or your recipient's use of the covered work
in a country, would infringe one or more identifiable patents in that
country that you have reason to believe are valid.

  If, pursuant to or in connection with a single transaction or
arrangement, you convey, or propagate by procuring conveyance of, a
covered work, and grant a patent license to some of the parties
receiving the covered work authorizing them to use, propagate, modify
or convey a specific copy of the covered work, then the patent license
you grant is automatically extended to all recipients of the covered
work and works based on it.

  A patent license is "discriminatory" if it does not include within
the scope of its coverage, prohibits the exercise of, or is
conditioned on the non-exercise of one or more of the rights that are
specifically granted under this License.  You may not convey a covered
work if you are a party to an arrangement with a third party that is
in the business of distributing software, under which you make payment
to the third party based on the extent of your activity of conveying
the work, and under which the third party grants, to any of the
parties who would receive the covered work from you, a discriminatory
patent license (a) in connection with copies of the covered work
conveyed by you (or copies made from those copies), or (b) primarily
for and in connection with specific products or compilations that
contain the covered work, unless you entered into that arrangement,
or that patent license was granted, prior to 28 March 2007.

  Nothing in this License shall be construed as excluding or limiting
any implied license or other defenses to infringement that may
otherwise be available to you under applicable patent law.

  12. No Surrender of Others' Freedom.

  If conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License.  If you cannot convey a
covered work so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you may
not convey it at all.  For example, if you agree to terms that obligate you
to collect a royalty for further conveying from those to whom you convey
the Program, the only way you could satisfy both those terms and this
License would be to refrain entirely from conveying the Program.

  13. Use with the GNU Affero General Public License.

  Notwithstanding any other provision of this License, you have
permission to link or combine any covered work with a work licensed
under version 3 of the GNU Affero General Public License into a single
combined work, and to convey the resulting work.  The terms of this
License will continue to apply to the part which is the covered work,
but the special requirements of the GNU Affero General Public License,
section 13, concerning interaction through a network will apply to the
combination as such.

  14. Revised Versions of this License.

  The Free Software Foundation may publish revised and/or new versions of
the GNU General Public License from time to time.  Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.

  Each version is given a distinguishing version number.  If the
Program specifies that a certain numbered version of the GNU General
Public License "or any later version" applies to it, you have the
option of following the terms and conditions either of that numbered
version or of any later version published by the Free Software
Foundation.  If the Program does not specify a version number of the
GNU General Public License, you may choose any version ever published
by the Free Software Foundation.

  If the Program specifies that a proxy can decide which future
versions of the GNU General Public License can be used, that proxy's
public statement of acceptance of a version permanently authorizes you
to choose that version for the Program.

  Later license versions may give you additional or different
permissions.  However, no additional obligations are imposed on any
author or copyright holder as a result of your choosing to follow a
later version.

  15. Disclaimer of Warranty.

  THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
APPLICABLE LAW.  EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE.  THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
IS WITH YOU.  SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.

  16. Limitation of Liability.

  IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
SUCH DAMAGES.

  17. Interpretation of Sections 15 and 16.

  If the disclaimer of warranty and limitation of liability provided
above cannot be given local legal effect according to their terms,
reviewing courts shall apply local law that most closely approximates
an absolute waiver of all civil liability in connection with the
Program, unless a warranty or assumption of liability accompanies a
copy of the Program in return for a fee.

                     END OF TERMS AND CONDITIONS

            How to Apply These Terms to Your New Programs

  If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these terms.

  To do so, attach the following notices to the program.  It is safest
to attach them to the start of each source file to most effectively
state the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.

    {one line to give the program's name and a brief idea of what it does.}
    Copyright (C) {year}  {name of author}

    This program is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.

    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with this program.  If not, see <http://www.gnu.org/licenses/>.

Also add information on how to contact you by electronic and paper mail.

  If the program does terminal interaction, make it output a short
notice like this when it starts in an interactive mode:

    {project}  Copyright (C) {year}  {fullname}
    This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
    This is free software, and you are welcome to redistribute it
    under certain conditions; type `show c' for details.

The hypothetical commands `show w' and `show c' should show the appropriate
parts of the General Public License.  Of course, your program's commands
might be different; for a GUI interface, you would use an "about box".

  You should also get your employer (if you work as a programmer) or school,
if any, to sign a "copyright disclaimer" for the program, if necessary.
For more information on this, and how to apply and follow the GNU GPL, see
<http://www.gnu.org/licenses/>.

  The GNU General Public License does not permit incorporating your program
into proprietary programs.  If your program is a subroutine library, you
may consider it more useful to permit linking proprietary applications with
the library.  If this is what you want to do, use the GNU Lesser General
Public License instead of this License.  But first, please read
<http://www.gnu.org/philosophy/why-not-lgpl.html>.


================================================
FILE: Makefile
================================================
# This is the top leve Makefile of AquilaOS
#
# Targets:
#
#  build-kernel     - build kernel image in kernel/{ARCH}/kernel-{VERSION}.{ARCH}
#  install-kernel   - install kernel image into {DESTDIR}/boot/kernel
#  clean-kernel     - clean kernel source tree
#
#  build-system     - build system components
#  install-system   - install system components into {DESTDIR}/
#  clean-system	    - clean system source tree
#
#  build-initrd     - build ramdisk image in initrd/initrd.img
#  install-initrd   - install ramdisk image into {DESTDIR}/boot/initrd.img
#  clean-initrd     - clean ramdisk source tree
#
#  build-all        - build everything
#  install-all      - install everything
#  clean-all        - clean everything
#

export

ifeq ($(SRCDIR),)
SRCDIR := $(TRAVIS_BUILD_DIR)
endif

ifeq ($(SRCDIR),)
SRCDIR != pwd
endif

ifeq ($(BUILDDIR),)
BUILDDIR != pwd
endif

ifeq ($(CONFIG),)
CONFIG := i386-pc
endif

include $(SRCDIR)/configs/$(CONFIG).mk

ARCH=i386
VERSION=0.0.1
CP=cp
BASH=bash
MKDIR=mkdir -p
ECHO=echo
STRIP=/opt/aquila/bin/i686-aquila-strip
LN=ln

MAKEFLAGS += --no-print-directory

GRUB_MKRESCUE = $(shell command -v grub2-mkrescue 2> /dev/null)
ifeq ($(GRUB_MKRESCUE),)
GRUB_MKRESCUE = grub-mkrescue
endif

DESTDIR = $(SRCDIR)/sysroot

.PHONY: build-all install-all clean-all
build-all: \
	build-kernel \
	build-system \
	build-initrd

install-all: \
	install-kernel \
	install-system \
	install-initrd

clean-all: \
	clean-kernel \
	clean-system \
	clean-initrd

#
# kernel targets
#

.PHONY: build-kernel clean-kernel install-kernel
build-kernel:
	$(MAKE) -C $(SRCDIR)/kernel/

install-kernel:
	$(MAKE) -C $(SRCDIR)/kernel/ install

clean-kernel:
	$(MAKE) -C $(SRCDIR)/kernel/ clean

#
# initrd targets
#

.PHONY: build-initrd install-initrd clean-initrd
build-initrd: build-system
	$(MAKE) -C $(SRCDIR)/initrd/

install-initrd: build-initrd
	$(MAKE) -C $(SRCDIR)/initrd/ install

clean-initrd:
	$(MAKE) -C $(SRCDIR)/initrd/ clean

#
# system targets
#

.PHONY: build-system install-system clean-system
build-system: 
	$(MAKE) -C $(SRCDIR)/system/

install-system: build-system
	$(MAKE) -C $(SRCDIR)/system/ install

clean-system:
	$(MAKE) -C $(SRCDIR)/system/ clean

.PHONY: iso/kernel.elf.gz
iso/kernel.elf.gz: build-kernel
	$(BASH) -c "if [[ ! -e iso ]]; then mkdir iso; fi"
	$(CP) kernel/arch/$(ARCH)/kernel-$(VERSION).$(ARCH) iso/kernel.elf
	gzip -f iso/kernel.elf

.PHONY: iso/initrd.img.gz
iso/initrd.img.gz: build-initrd
	$(BASH) -c "if [[ ! -e iso ]]; then mkdir iso; fi"
	cp initrd/initrd.img iso/initrd.img
	gzip -f iso/initrd.img

.PHONY: try
try: aquila.iso
	qemu-kvm -cdrom aquila.iso -hda hd.img -serial stdio -m 2G -d cpu_reset -no-reboot -boot d

aquila.iso: iso/kernel.elf.gz iso/initrd.img.gz
	$(GRUB_MKRESCUE) -d /usr/lib/grub/i386-pc/ -o aquila.iso iso/
#	#$(GRUB_MKRESCUE) -d /usr/lib/grub/i386-pc/ --install-modules="multiboot normal videoinfo videotest gzio" --locales="en@quot" --fonts=ascii -o aquila.iso iso/


================================================
FILE: README.md
================================================
# Aquila OS ![https://travis-ci.org/mohamed-anwar/Aquila](https://api.travis-ci.org/mohamed-anwar/Aquila.svg?branch=master) [![Gitter chat](https://badges.gitter.im/mohamed-anwar/aquila.png)](https://gitter.im/_aquila)
![Image of Aquila](http://aquilaos.com/img/screenshot.png)

UNIX-like Operating System, including the kernel and system tools.
Intended to be fully **POSIX** compliant. Oh, and it compiles with -O3.

#### Build Instructions
Follow the instructions in this [wiki page.](https://github.com/mohamed-anwar/Aquila/wiki/Build-Instructions)

#### CPU-based Features:
##### Supported Archetictures:
> - [X] x86
> - [ ] x86-64

- [X] Multitasking
- [X] Multithreading
- [ ] SMP

#### Kernel Features:
- [X] Monolitihic kernel
- [X] Virtual Filesystem
- [ ] Supports loadable modules

#### Supported Filesystems:
- [X] initramfs (CPIO Archive filesystem, used for Ramdisk, read only)
- [X] tmpfs     (Generic temporary filesystem, read/write)
- [X] devfs     (Virtual filesystem, used for device handlers, statically populated, read/write)
- [X] devpts    (Virtual filesystem, used for psudo-terminals, dynamically populated, read/write)
- [X] procfs    (Processes information filesystem, read only)
- [X] ext2      (Basic Extended 2 filesystem, read/write)
- [ ] ext3
- [ ] ext4
- [ ] sysfs

#### Supported Devices:
- [X] i8042   (PS/2 Controller)
- [X] ramdev  (Memory mapped device, generic handler)
- [X] ps2kbd  (PS/2 Keyboard Controller)
- [X] console (IBM TGA console)
- [X] ata     (ATA Harddisk handler, PIO mode)
- [X] fbdev   (Generic framebuffer device handler)
- [X] 8250    (UART)

#### Supported video interfaces:
- [X] VESA 3.0

#### System Feautres:
- [X] newlib-3.0.0 (latest)
- [X] aqbox        (Aquila Box, like busybox)
- [X] fbterm       (Framebuffer based terminal)
- [X] tcc          (Tiny C Compiler)
- [X] lua          (Lua programming language)
- [X] kilo         (Kilo text editor)


================================================
FILE: configs/clang.mk
================================================
CC := clang

CFLAGS := $(INCLUDES) \
		-nostdlib -ffreestanding -m32 \
		-O3 -Wall -Wextra -Werror \
		-Wno-unused -Wno-unused-parameter -march=i386

AS := $(CC)
ASFLAGS := $(CFLAGS)
#LD := ld.gold
LD := ld.lld
LDFLAGS := -nostdlib -melf_i386


================================================
FILE: configs/gcc.mk
================================================
CC := i686-aquila-gcc

CFLAGS += \
		-nostdlib -ffreestanding -m32 \
		-O3 -Wall -Wextra -Werror \
		-Wno-unused -Wno-unused-parameter -march=i386 \
		-funsigned-bitfields -fuse-ld=bfd

AS := $(CC)
ASFLAGS := $(CFLAGS)
LD := i686-aquila-ld
LDFLAGS := -nostdlib -melf_i386

SYSCC := i686-aquila-gcc
SYSLD := i686-aquila-ld


================================================
FILE: configs/i386-pc.mk
================================================
include $(SRCDIR)/configs/gcc.mk

#
# Configurations
#

ARCH=i386
ARCH_DIR=i386
ARCH_I386=y
ARCH_BITS=32

#
# Boot Definitions
#

X86_MULTIBOOT=y

#
# Platform - PC
#

PLATFORM_X86_PC=y
PLATFORM_DIR=pc
# Support 8259 PIC
PLATFORM_X86_MISC_PIC=y
# Support 8253/8254 PIT
PLATFORM_X86_MISC_PIT=y
# Support i8042 PS/2 Controller
PLATFORM_X86_MISC_I8042=y
# Support HPET
PLATFORM_X86_MISC_HPET=n
# Support ACPI
PLATFORM_X86_MISC_ACPI=y
# Support CMOS
PLATFORM_X86_MISC_CMOS=y

#
# Devices
#

# Generic framebuffer (fbdev) support
DEV_FRAMEBUFFER=y
# Generic console (condev) support
DEV_CONSOLE=y
DEV_KEYBOARD=y
DEV_MOUSE=y
DEV_KEYBOARD_PS2=y
DEV_UART=y
DEV_PTY=y
DEV_MEMDEV=y
DEV_ATA=y
DEV_FDC=y

#
# Framebuffer
#

FBDEV_VESA=y

# Filesystems
FS_TMPFS=y
FS_DEVFS=y
FS_DEVPTS=y
FS_EXT2=y
FS_PROCFS=y
FS_MINIX=y

# Initramfs
INITRAMFS_CPIO=y

# Network
NET_UNIX=y


================================================
FILE: configs/i386-quark.mk
================================================
#
# Compilation flags
#

CC := $(PDIR)/../build-tools/sys/bin/i686-elf-gcc
CFLAGS := -std=gnu99 -I. -I$(PDIR)/arch/$$(ARCH_DIR)/chipset/$$(CHIPSET_DIR)/include -I$(PDIR)/arch/$$(ARCH_DIR)/include -I $(PDIR) -I $(PDIR)/include/ -nostdlib -ffreestanding -m32 \
		  -O3 -Wall -Wextra -Werror -funsigned-bitfields -fuse-ld=bfd \
		  -Wno-unused -march=i586

AS := $(CC)
ASFLAGS := $(CFLAGS)

LD := $(PDIR)/../build-tools/sys/bin/i686-elf-ld.bfd
LDFLAGS := -nostdlib -melf_i386

#
# Configurations
#

ARCH=X86
ARCH_DIR=x86
ARCH_X86=y
ARCH_BITS=32

#
# Boot Definitions
#

X86_MULTIBOOT=y

#
# Chipset - generic
#

#CHIPSET_X86_GENERIC=y
CHIPSET_X86_QUARK=y
CHIPSET_DIR=quark
# Support 8259 PIC
CHIPSET_X86_MISC_PIC=y
# Support 8253/8254 PIT
CHIPSET_X86_MISC_PIT=y
# Support i8042 PS/2 Controller
#CHIPSET_X86_MISC_I8042=y

#
# Devices
#

# Generic framebuffer (fbdev) support
#DEV_FRAMEBUFFER=y
# Generic console (condev) support
DEV_CONSOLE=y
#DEV_KEYBOARD=y
#DEV_MOUSE=y
#DEV_KEYBOARD_PS2=y
DEV_UART=y
DEV_PTY=y

#
# Framebuffer
#

#FBDEV_VESA=y

# Filesystems
FS_TMPFS=y
FS_DEVFS=y
FS_DEVPTS=y
#FS_EXT2=y
FS_PROCFS=y


================================================
FILE: configs/none.mk
================================================
CC := $(PDIR)/../build-tools/sysroot/bin/i686-elf-gcc
CFLAGS := -std=gnu99 -I. -I$(PDIR)/arch/$$(ARCH_DIR)/chipset/$$(CHIPSET_DIR)/include -I$(PDIR)/arch/$$(ARCH_DIR)/include -I $(PDIR) -I $(PDIR)/include/ -nostdlib -ffreestanding -m32 \
		  -O3 -Wall -Wextra -Werror -funsigned-bitfields -fuse-ld=bfd \
		  -Wno-unused -march=i386

AS := $(CC)
ASFLAGS := $(CFLAGS)

LD := ld.bfd
LDFLAGS := -nostdlib -melf_i386 -L /opt/aquila/lib/gcc/i686-aquila/7.3.0/

ARCH=none
ARCH_DIR=none
ARCH_NONE=y
ARCH_BITS=32

#DEV_FRAMEBUFFER=y
#DEV_CONSOLE=y
#DEV_KEYBOARD=y
#DEV_MOUSE=y
#DEV_KEYBOARD_PS2=y
#DEV_UART=y
#DEV_PTY=y
#DEV_MEMDEV=y
#DEV_ATA=y
#DEV_FDC=y

FBDEV_VESA=y

# Filesystems
FS_TMPFS=y
FS_DEVFS=y
FS_DEVPTS=y
FS_EXT2=y
FS_PROCFS=y
FS_MINIX=y

# Initramfs
INITRAMFS_CPIO=y


================================================
FILE: configs/pcc.mk
================================================
CC := /opt/aquila/bin/i686-aquila-pcc

CFLAGS += \
		-nostdlib -ffreestanding -m32 \
		-O3 -Wall -Wextra -Werror \
		-Wno-unused -Wno-unused-parameter -march=i386 \
		-funsigned-bitfields -fuse-ld=bfd

AS := $(CC)
ASFLAGS := $(CFLAGS)
LD := /opt/aquila/bin/i686-aquila-ld
LDFLAGS := -nostdlib -melf_i386

SYSCC := /opt/aquila/bin/i686-aquila-pcc
SYSLD := /opt/aquila/bin/i686-aquila-ld


================================================
FILE: configs/x86_64-pc.mk
================================================
#
# Compilation flags
#

CC := gcc
CFLAGS := -std=gnu99 -I. -I$(PDIR)/arch/$$(ARCH_DIR)/chipset/$$(PLATFORM_DIR)/include -I$(PDIR)/arch/$$(ARCH_DIR)/include -I $(PDIR) -I $(PDIR)/include/ -nostdlib -ffreestanding \
		  -O3 -Wall -Wextra -Werror -funsigned-bitfields -fuse-ld=bfd \
		  -Wno-unused \
		  -mcmodel=large -mno-red-zone -mno-mmx -mno-sse -mno-sse2 -z max-page-size=0x1000

AS := $(CC)
ASFLAGS := $(CFLAGS)

LD := ld.bfd
LDFLAGS := -nostdlib -melf_x86_64

#
# Configurations
#

ARCH=x86_64
ARCH_DIR=x86_64
ARCH_X86_64=y
ARCH_BITS=64

#
# Boot Definitions
#

X86_MULTIBOOT=y

#
# Chipset - generic
#

PLATFORM_X86_PC=y
PLATFORM_DIR=pc
# Support 8259 PIC
PLATFORM_X86_MISC_PIC=y
# Support 8253/8254 PIT
PLATFORM_X86_MISC_PIT=y
# Support i8042 PS/2 Controller
PLATFORM_X86_MISC_I8042=y

#
# Devices
#

# Generic framebuffer (fbdev) support
DEV_FRAMEBUFFER=y
# Generic console (condev) support
DEV_CONSOLE=y
DEV_KEYBOARD=y
DEV_MOUSE=y
DEV_KEYBOARD_PS2=y
DEV_UART=y
DEV_PTY=y
DEV_MEMDEV=y
DEV_ATA=y

#
# Framebuffer
#

FBDEV_VESA=y

# Filesystems
FS_TMPFS=y
FS_DEVFS=y
FS_DEVPTS=y
#FS_EXT2=y
FS_PROCFS=y

# Initramfs
INITRAMFS_CPIO=y


================================================
FILE: initrd/Makefile
================================================
ROOT= initrd
DIRS= bin sbin dev mnt proc tmp root
COPY= etc usr

AQBOX= aqbox
AQBOX_BIN= cat clear echo env ls mkdir mknod ps pwd sh stat uname unlink touch kill bim date
AQBOX_SBIN= login mount kbd getty readmbr reboot

# Create initrd CPIO image
initrd.img: all
	cd $(ROOT); find . | cpio -o > ../initrd.img;

all: $(DIRS) $(COPY) $(ROOT)/init fbterm aqbox $(ROOT)/dev/kmsg #nuklear

$(ROOT):
	$(MKDIR) -p $(ROOT)

# Inflate initrd ROOT with required directories
$(DIRS): $(ROOT)
	$(MKDIR) -p $(ROOT)/$@

# Copy some files and directories into initrd ROOT
$(COPY): $(ROOT)
	$(CP) -r $@ $(ROOT)/

fbterm: $(ROOT)/bin/fbterm

$(ROOT)/bin/fbterm: $(ROOT)/bin
	$(CP) $(SRCDIR)/system/fbterm/fbterm  $(ROOT)/bin/
	$(STRIP) $(ROOT)/bin/fbterm

aqbox: $(ROOT)/bin/aqbox $(AQBOX_BIN) $(AQBOX_SBIN)

$(ROOT)/bin/aqbox: $(ROOT)/bin
	$(CP) $(SRCDIR)/system/aqbox/aqbox $(ROOT)/bin/
	$(STRIP) $(ROOT)/bin/aqbox

$(AQBOX_BIN): $(ROOT)/bin/aqbox
	$(LN) -fs /bin/aqbox $(ROOT)/bin/$@

$(AQBOX_SBIN): $(ROOT)/bin/aqbox
	$(LN) -fs /bin/aqbox $(ROOT)/sbin/$@

$(ROOT)/init:
	$(MAKE) -C init/
	$(CP) init/init $@

$(ROOT)/dev/kmsg:
	#sudo mknod $(ROOT)/dev/kmsg c 1 11

clean:
	$(MAKE) -C init/ clean
	$(RM) -rf $(ROOT) initrd.img

.PHONY: all $(DIRS) clean $(COPY) fbterm aqbox $(AQBOX_BIN) $(AQBOX_SBIN) install
install: all
	$(MKDIR) -p $(DESTDIR)/boot
	$(CP) initrd.img $(DESTDIR)/boot


================================================
FILE: initrd/etc/hostname
================================================
aquila


================================================
FILE: initrd/etc/motd
================================================

                                               _...__..-'
                                             .'
                                           .'
                                         .'
                                       .'
            .------._                 ;
      .-"""`-.<')    `-._           .'
     (.--. _   `._       `'---.__.-'
      `   `;'-.-'         '-    ._
        .--'``  '._      - '   .
         `""'-.    `---'    ,
 ''--..__      `\
         ``''---'`\      .'
                   `'. '
                     `'.
   _____               .__.__          ________    _________
  /  _  \   ________ __|__|  | _____   \_____  \  /   _____/
 /  /_\  \ / ____/  |  \  |  | \__  \   /   |   \ \_____  \ 
/    |    < <_|  |  |  /  |  |__/ __ \_/    |    \/        \
\____|__  /\__   |____/|__|____(____  /\_______  /_______  /
        \/    |__|                  \/         \/        \/ 

Welcome to AquilaOS!



================================================
FILE: initrd/etc/passwd
================================================
root:x:0:0:root:/root:/bin/sh


================================================
FILE: initrd/etc/rc.init
================================================
#!/bin/sh

set -x
export PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/libexec:/usr/local/bin:/usr/local/sbin

# Mount devfs on /dev
echo mounting devfs on /dev
mount -t devfs /dev

# Populate static devices
echo populating static devices in /dev
mknod /dev/console c 5 1 
mknod /dev/ptmx c 5 2 
mknod /dev/kbd c 11 0 
mknod /dev/fb0 c 29 0 
mknod /dev/hda b 3 0 
mknod /dev/hda1 b 3 1 
mknod /dev/ttyS0 c 4 64 
mknod /dev/mouse c 10 1 
mknod /dev/kmsg c 1 11
mknod /dev/fd0 b 2 0

# Mount devpts on /dev/pts
echo mounting devpts on /dev/pts
mkdir /dev/pts
mount -t devpts /dev/pts


================================================
FILE: initrd/init/Makefile
================================================
#ARCH=i686
#SYSROOT= ../../build-tools/sysroot
#CC= $(SYSROOT)/bin/$(ARCH)-aquila-gcc
#CFLAGS= -I$(SYSROOT)/usr/$(ARCH)-aquila/include
#
#LD= $(CC)
#LDFLAGS= -nostdlib -ffreestanding -Wl,-Ttext=0x1000
#LDLIBS= $(SYSROOT)/usr/$(ARCH)-aquila/lib/crt0.o -L$(SYSROOT)/usr/$(ARCH)-aquila/lib -lc -lpthread -lm -lgcc 

all: init

init: init.c
	$(SYSCC) $< -o $@

clean:
	rm -rf init

.PHONY: all clean


================================================
FILE: initrd/init/init.c
================================================
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <fcntl.h>
#include <string.h>
#include <sys/wait.h>
#include <stdarg.h>
#include <signal.h>
#include <errno.h>

int log_fd = -1;
int log_init()
{
    log_fd = open("/dev/kmsg", O_WRONLY);
}

int _log(int level, const char *fmt, ...)
{
    static char buf[512];

    if (log_fd >= 0) {
        va_list ap;
        va_start(ap, fmt);
        int len = vsnprintf(buf, sizeof(buf), fmt, ap);
        va_end(ap);
        write(log_fd, buf, len);
    }
}

int run(char **argv)
{
    int child, status, pid;

    if (child = fork()) {
        do pid = waitpid(child, &status, 0);
        while (pid != child);
    } else {
        int x = execv(argv[0], argv);
        _log(1, "failed to execute %s: %s\n", argv[0], strerror(errno));
        exit(x);
    }

    return status;
}

void signal_handler(int sig)
{
    switch (sig) {
        case SIGTERM:
            _log(1, "init: reached target reboot\n");
            exit(0);
        default:
            /* ignore */
            return;
    }
}

int main(int argc, char **argv)
{
    signal(SIGKILL, signal_handler);
    signal(SIGTERM, signal_handler);

    close(0); close(1); close(2);
    open("/dev/kmsg", O_RDONLY);
    log_init();

    if (open("/dev/kmsg", O_WRONLY) != 2) {
        _log(1, "could not open stderr\n");
    }

    _log(1, "init: started\n");

    /* execute /etc/rc.init script */
    _log(1, "init: executing /etc/rc.init script\n");
    char *argp[] = {"/bin/sh", "/etc/rc.init", NULL};
    run(argp);

    int use_fbterm = 0, use_serial = 0;

    if (argc > 0) {
        char *cmdline = argv[0], *token;
        while ((token = strtok(cmdline, " "))) {
            cmdline = NULL;
            if (!strcmp(token, "--serial"))
                use_serial = 1;
            else if (!strcmp(token, "--fbterm"))
                use_fbterm = 1;
        }
    }

    if (use_fbterm || !use_serial) {
        _log(1, "init: starting fbterm\n");
        char *argp[] = {"/bin/fbterm", NULL};
        if (!fork()) {
            for (int i = 0; i < 3; ++i)
                close(i);

            execv(argp[0], argp);
        }
    }

    if (use_serial) {
        if (!fork()) {
            for (int i = 0; i < 3; ++i)
                close(i);

            open("/dev/ttyS0", O_RDONLY);
            open("/dev/ttyS0", O_WRONLY);
            open("/dev/ttyS0", O_WRONLY);

            char *argp[] = {"/sbin/login", NULL};
            while (1) run(argp);
            //execv(argp[0], argp);
        }
    }

    /* init can't die */
	for (;;);
}


================================================
FILE: initrd/usr/share/man/man1/ccom.1
================================================
.\"	$Id: ccom.1,v 1.33 2018/12/15 09:12:14 plunky Exp $
.\"
.\" Copyright (c) 2007 Jeremy C. Reed <reed@reedmedia.net>
.\"
.\" Permission to use, copy, modify, and/or distribute this software for any
.\" purpose with or without fee is hereby granted, provided that the above
.\" copyright notice and this permission notice appear in all copies.
.\"
.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR AND CONTRIBUTORS DISCLAIM
.\" ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
.\" WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL AUTHOR AND
.\" CONTRIBUTORS BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
.\" DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
.\" PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
.\" ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
.\" THIS SOFTWARE.
.\"
.Dd March 22, 2012
.Dt CCOM 1
.Os
.Sh NAME
.Nm ccom
.Nd C compiler
.Sh SYNOPSIS
.Nm
.Op Fl gkpsv
.Op Fl f Ar features
.Op Fl m Ar options
.Op Fl W Ar warnings
.Op Fl X Ar flags
.Op Fl x Ar settings
.Op Fl Z Ar flags
.Op infile
.Op outfile
.Sh DESCRIPTION
The
.Nm
utility provides a C compiler.
The frontend is usually
.Xr pcc 1 .
It is
.Em not
intended to be run directly.
.Nm
reads the C source from
.Ar infile
or standard input and writes the assembler source
to
.Ar outfile
or to standard output.
.Pp
The options are as follows:
.Bl -tag -width Ds
.It Fl f Ar feature
Enable language features.
Multiple
.Fl f
options can be given, the following features are supported:
.Bl -tag -width Ds
.It Sy stack-protector
Enable stack smashing protection.
Currently the same as
.Sy stack-protector-all .
.It Sy stack-protector-all
Enable stack smashing protection for all functions.
.It Sy pack-struct Ns Oo = Ns Ar n Oc
Specify maximum alignment for structure members, similar to a #pragma pack
statement at the start of the file.
If no value is given, the default is 1.
.It Sy freestanding
Emit code for a freestanding environment.
Currently not implemented.
.El
.It Fl g
Include debugging information in the output code for use by
symbolic and source-level debuggers.
Currently this uses the
.Sy stabs
format, encoding information in
.Em s Ns ymbol Em tab Ns le entrie Ns Em s.
.It Fl k
Generate PIC code.
.It Fl m Ar option
Target-specific options, used in machine-dependent code.
Multiple
.Fl m
options can be given, the following options are supported:
.Bl -tag -width PowerPC
.It AMD64
.It ARM
.Sy little-endian ,
.Sy big-endian ,
.Sy fpe=fpa ,
.Sy fpe=vpf ,
.Sy soft-float ,
.Sy arch=armv1 ,
.Sy arch=armv2 ,
.Sy arch=armv2a ,
.Sy arch=armv3 ,
.Sy arch=armv4 ,
.Sy arch=armv4t ,
.Sy arch=armv4tej ,
.Sy arch=armv5 ,
.Sy arch=armv5te ,
.Sy arch=armv5tej ,
.Sy arch=armv6 ,
.Sy arch=armv6t2 ,
.Sy arch=armv6kz ,
.Sy arch=armv6k No \*(Am
.Sy arch=armv7 .
.It HPPA
.It i386
.It M16C
.It MIPS
.Sy little-endian No \*(Am
.Sy big-endian .
.It NOVA
.It PDP-10
.It PDP-11
.It PowerPC
.Sy little-endian ,
.Sy big-endian ,
.Sy soft-float No \*(Am
.Sy hard-float .
.It Sparc64
.It VAX
.El
.It Fl p
Generate profiling code.
.It Fl s
Print statistics to standard error when complete.
This includes:
name table entries, name string size, permanent allocated memory,
temporary allocated memory, lost memory, argument list unions,
dimension/function unions, struct/union/enum blocks, inline node count,
inline control blocks, and permanent symtab entries.
.\" TODO: explain units for above?
.It Fl v
Display version.
.It Fl W Ar warning
Do some basic checks and emit warnings about possible coding problems.
Multiple
.Fl W
options can be given, the following warnings are supported:
.Bl -tag -width Ds
.It Sy error Ns Oo = Ns Ar warning Oc
Enable
.Ar warning ,
and treat it as an error condition.
If a specific warning is not given, producing any warning will cause an error.
.It Sy attributes
Warn when unsupported attributes are used.
This warning is enabled by default.
.It Sy deprecated-declarations
Report whenever a symbol marked with the
.Sq deprecated
attribute is used.
This warning is enabled by default.
.It Sy implicit-function-declaration
(TODO) Require explicit prototypes for all called functions.
.It Sy implicit-int
(TODO) Warn when a function declaration lacks a type.
.It Sy missing-prototypes
Require explicit prototypes for all global function definitions.
.It Sy pointer-sign
Warn when pointer operations are done with mismatched signed and unsigned values.
.It Sy sign-compare
(TODO) Warn about comparisons between signed and unsigned values.
.It Sy strict-prototypes
(TODO) Require that function prototypes are strictly C99.
.It Sy shadow
Report when a local variable shadows something from a higher scope.
.It Sy truncate
Report when integer values may be implicitly truncated to fit a smaller type.
.It Sy uninitialized
A variable is read before being written.
.It Sy unknown-pragmas
Report unhandled pragma statements.
.It Sy unreachable-code
Report statements that cannot be executed.
.El
.Pp
Any of the above may be prefixed with
.Dq no-
in order to disable the effect.
.\"
.It Fl X Ar flags
C specific debugging where
.Ar flags
is one or more of the following:
.Pp
.Bl -tag -compact -width Ds
.It Sy b
Building of parse trees
.It Sy d
Declarations (using multiple
.Sy d
flags gives more output)
.It Sy e
Pass1 trees at exit
.It Sy i
Initializations
.It Sy n
Memory allocations
.It Sy o
Turn off optimisations
.It Sy p
Prototypes
.It Sy s
Inlining
.It Sy t
Type conversions
.It Sy x
Target-specific flag, used in machine-dependent code
.El
.\"
.It Fl x Ar setting
Enable
.Ar setting
in the compiler.
Multiple
.Fl x
options can be given, the following settings are supported:
.Bl -tag -width Ds
.It Sy ccp
Apply sparse conditional constant propagation techniques for optimization.
Currently not implemented.
.It Sy dce
Do dead code elimination.
.It Sy deljumps
Delete redundant jumps and dead code.
.It Sy gnu89
.It Sy gnu99
Use GNU C semantics rather than C99 for some things.
Currently only inline.
.It Sy inline
Replace calls to functions marked with an inline specifier with a copy
of the actual function.
.It Sy ssa
Convert statements into static single assignment form for optimization.
Not yet finished.
.It Sy tailcall
Enable optimization of tail-recursion functions.
Currently not implemented.
.It Sy temps
Locate automatic variables into registers where possible, for further
optimization by the register allocator.
.It Sy uchar
Treat character constants as unsigned values.
.El
.\"
.It Fl Z Ar flags
Code generator (pass2) specific debugging where
.Ar flags
is one or more of the following:
.Pp
.Bl -tag -compact -width Ds
.It Sy b
Basic block and SSA building
.It Sy c
Code printout
.It Sy e
Trees when entering pass2
.It Sy f
Instruction matcher, may provide much output
.It Sy g
Print flow graphs
.It Sy n
Memory allocation
.It Sy o
Instruction generator
.It Sy r
Register allocator
.It Sy s
Shape matching in instruction generator
.It Sy t
Type matching in instruction generator
.It Sy u
Sethi-Ullman computations
.It Sy x
Target-specific flag, used in machine-dependent code
.El
.El
.Sh PRAGMAS
Input lines starting with a
.Dq #pragma
directive can be used to modify behaviour of
.Nm
during compilation.
All tokens up to the first unescaped newline are considered part
of the pragma command, with the following operations being recognized:
.Bl -tag -width Ds
.It Sy STDC
Standard C99 operator follows.
Currently no C99 operations are implemented, and any directives starting
with this token will be silently ignored.
.It Sy GCC diagnostic Ar effect Qq Ar option
GNU C compatibility.
Alter the effects of compiler diagnostics.
The required
.Ar effect
should be stated as
.Sy warning ,
.Sy error
or
.Sy ignored ,
followed by the compiler diagnostic
.Ar option
in double quotes.
For example, to force unknown pragmas to always generate an error,
a standard header might include
.Bd -literal -offset 2n
#pragma GCC diagnostic error "-Wunknown-pragmas"
.Ed
.It Sy GCC poison Ar identifier ...
GNU C compatibility.
Cause an error if any of the following
.Ar identifier Ns s
subsequently appear in the code
.Pq but not in any macro expansions .
Currently not implemented.
.It Sy GCC system_header
GNU C compatibility.
Currently not implemented.
.It Sy GCC visibility
GNU C compatibility.
Currently not implemented.
.It Sy pack Ns Pq Op Ar n
Set the default maximum alignment for structures and unions, such that
members will have their natural alignment requirements clamped at this
value and may be stored misaligned.
If
.Ar n
is not given, the alignment is reset to the target default.
.It Sy pack Ns Pq Sy push Ns Op , Ar n
Push the current pack setting onto an internal stack then, if
.Ar n
is given, change the default alignment for structures and unions.
Currently not implemented.
.It Sy pack Ns Pq Sy pop
Change the pack setting to the most recently pushed value, and remove
that setting from the stack.
Currently not implemented.
.It Sy packed Op Ar n
Set the maximum alignment for the structure or union defined
in the current statement.
If
.Ar n
is not given, the default value of 1 is used.
.Pq Currently this works except Ar n is not used
.It Sy aligned Op Ar n
Set the minimum alignment for the structure or union defined
in the current statement.
.It Sy rename Ar name
Provide an alternative
.Ar name
which will be used to reference the object declared in the current statement.
.It Sy weak Ar name Ns Op = Ns Ar alias
Mark
.Ar name
as a weak rather than a global symbol, to allow its definition to be
overridden at link time.
If an
.Ar alias
is given, this will be used as the default value of
.Ar name .
.It Sy ident
Currently not implemented.
.El
.Lp
and the following target-specific operations are handled by
machine-dependent code:
.Bl -tag -width Ds
.It Sy tls
For AMD64 and i386 targets, the variable declared in the current statement
will be referenced via the
.Dq thread-local storage
mechanism.
.It Sy init
For AMD64, ARM, HPPA, i386, MIPS and PowerPC targets, when the current statement is a
function declaration, generate a reference in the
.Sy .ctors
section, enabling library code to call the function prior to entering
.Fn main .
.It Sy fini
For AMD64, ARM, HPPA, i386, MIPS and PowerPC targets, when the current statement is a
function declaration, generate a reference in the
.Sy .dtors
section, enabling library code to call the function when
.Fn main
returns or the
.Fn exit
function is called.
.It Sy section Ar name
For AMD64, ARM, HPPA and i386 targets, place the subsequent code in the named
section.
.Pq This is currently broken .
.It Sy alias Ar name
For AMD64, HPPA and i386 targets, emit assembler instructions providing an
alias for the symbol defined by the current statement.
.It Sy stdcall
For i386 targets, enable
.Dq stdcall
semantics during code generation, where function arguments are passed on
the stack in right-to-left order, and the callee is responsible for adjusting
the stack pointer before returning.
Any function result is passed in the EAX register.
On win32, the function name is postfixed with an
.Dq @
and the size of the stack adjustment.
.It Sy cdecl
For i386 targets, enable
.Dq cdecl
semantics during code generation, where function arguments are passed on
the stack in right-to-left order, and the caller is responsible for cleaning
up the stack after the function returns.
Any function result is passed in the EAX register.
This is the default.
.It Sy fastcall
For i386-win32 targets, enable
.Dq fastcall
semantics during code generation.
.Po
Currently this is equivalent to
.Sy stdcall ,
which is likely wrong
.Pc .
.It Sy dllimport
For i386-win32 targets, references to the external symbol defined by
the current statement will be made via indirect access through a
location identified by the symbol name prefixed with
.Dq __imp_ .
.It Sy dllexport
For i386-win32 targets, the external symbol declared by the current
statement will be exported as an indirect reference to be
accessed with
.Sy dllimport .
The global locator will be the symbol name prefixed with
.Dq __imp_ .
Currently this is not completely implemented.
.El
.Pp
Any unknown
.Dq #pragma
directives will be ignored unless the
.Fl Wunknown-pragmas
diagnostic is in effect.
.Sh SEE ALSO
.Xr as 1 ,
.Xr cpp 1 ,
.Xr pcc 1
.Sh HISTORY
The
.Nm
compiler is based on the original Portable C Compiler by
.An "S. C. Johnson" ,
written in the late 70's.
Even though much of the compiler has been rewritten
.Pq about 50% of the frontend code and 80% of the backend ,
some of the basics still remain.
Most is written by
.An "Anders Magnusson" ,
with the exception of the data-flow analysis part and
the SSA conversion code which is written by
.An "Peter A Jonsson" ,
and the Mips port that were written as part of a project
by undergraduate students at Lulea University of Technology.
.Pp
This product includes software developed or owned by Caldera
International, Inc.


================================================
FILE: initrd/usr/share/man/man1/cpp.1
================================================
.\"	$Id: cpp.1,v 1.17 2013/02/26 19:27:38 plunky Exp $
.\"
.\" Copyright (c) 2007 Jeremy C. Reed <reed@reedmedia.net>
.\"
.\" Permission to use, copy, modify, and/or distribute this software for any
.\" purpose with or without fee is hereby granted, provided that the above
.\" copyright notice and this permission notice appear in all copies.
.\"
.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR AND CONTRIBUTORS DISCLAIM
.\" ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
.\" WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL AUTHOR AND
.\" CONTRIBUTORS BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
.\" DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
.\" PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
.\" ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
.\" THIS SOFTWARE.
.\"
.Dd February 26, 2013
.Dt CPP 1
.Os
.Sh NAME
.Nm cpp
.Nd C preprocessor
.Sh SYNOPSIS
.Nm
.Op Fl ACEMPtVv
.Op Fl D Ar macro Ns Oo = Ns Ar value Oc
.Op Fl d Ar flags
.Op Fl I Ar path
.Op Fl i Ar file
.Op Fl S Ar path
.Op Fl U Ar macro
.Op Ar infile | -
.Op Ar outfile
.Sh DESCRIPTION
The
.Nm
utility is a macro preprocessor used by the
.Xr pcc 1
compiler.
It is mainly used to include header files,
expand macro definitions,
discard comments,
and perform conditional compilation.
.Nm
is written to comply with the
.St -isoC-99
specification.
.Pp
The
.Ar infile
input file is optional.
If not provided or the file name is
.Qq -
(dash),
.Nm
reads its initial file from standard input.
The
.Ar outfile
output file is also optional, with output written to standard
output if not provided.
.Pp
The options are as follows:
.Bl -tag -width Ds
.It Fl A
For assembler-with-cpp input: treat non-directive lines starting
with a # as comments.
.It Fl C
Do not discard comments.
.It Fl D Ar macro Ns Oo = Ns Ar value Oc
Create a macro definition before processing any input, as if a
.Lp
.Dl #define Ar macro Ar value
.Lp
directive had appeared in the source.
If
.Ar value
is not set on the command-line, then a value of 1 is used.
.It Fl d Ar flags
Modify output according to
.Ar flags ,
which can be a list of character flags.
The following flags are currently supported:
.Bl -tag -width ".Sy M"
.It Sy M
Do not process any input, but output a list of
.Dq #define
statements for all defined macros other than builtin macros
.Pq see below .
.El
.Lp
any unknown flags are ignored.
.It Fl E
Modify the exit code, if there were any warnings.
.It Fl I Ar path
Add
.Ar path
to the list of directories searched by the
.Dq #include
directive.
This may be used to override system include directories
.Pq see Fl S No option .
.Fl I
may be specified multiple times and is cumulative.
.It Fl i Ar file
Include a file before processing any input, as if a
.Lp
.Dl #include Qo Ar file Qc
.Lp
directive had appeared in the source.
.Fl i
may be specified multiple times to include several files.
.It Fl M
Instead of producing a processed C code file, output a list
of dependencies for
.Xr make 1 ,
detailing the files that need to be processed when compiling
the input.
.It Fl P
Inhibit generation of line markers.  This is sometimes useful when
running the preprocessor on something other than C code.
.It Fl S Ar path
Add
.Ar path
to the list of system directories searched by the
.Dq #include
directive.
The
.Fl S
option may be specified multiple times and is cumulative.
.It Fl t
Traditional cpp syntax.
Do not define the
.Dv __TIME__ ,
.Dv __DATE__ ,
.Dv __STDC__ ,
and
.Dv __STDC_VERSION__
macros.
.It Fl U Ar macro
Undefine a macro before processing any input, as if a
.Lp
.Dl #undef Ar macro
.Lp
directive had appeared in the source.
.It Fl V
Verbose debugging output.
.Fl V
can be repeated for greater detail.
.Po
This is only available if the
.Nm
program was built with
.Dv PCC_DEBUG
defined, which is the default
.Pc .
.It Fl v
Display version.
.El
.Pp
The
.Fl D ,
.Fl i
and
.Fl U
options are processed in the order that they appear on the command
line, before any input is read but after the command line options
have been scanned.
.Pp
Files referenced by the
.Dq #include
directive as
.Qq ... ,
are first looked for in the current directory, then as per
.Aq ...
files, which are first looked for in the list of
directories provided by any
.Fl I
options, then in the list of system directories provided by any
.Fl S
options.
Note that
.Nm
does not define any include directories by default; if no
.Fl I
or
.Fl S
options are given, then only the current directory will be
searched and no system files will be found.
.Ss Builtin Macros
A few macros are interpreted inside the
.Nm cpp
program:
.Bl -diag
.It __DATE__
Expands to a quoted string literal containing the date in the form
.Qq Mmm dd yyyy ,
where the names of the months are the same as those generated by the
.Xr asctime 3
function, and the first character of dd is a space character if
the value is less than 10.
.It __FILE__
Expands to a quoted string literal containing the presumed name of
the current source file.
When reading source from standard input, it expands to
.Qq Aq stdin .
.It __LINE__
Expands to an integer constant representing the presumed line number
of the source line containing the macro.
.It __STDC__
Expands to the integer constant
.Dq 1 ,
meaning that the compiler conforms to
.St -isoC .
.It __STDC_VERSION__
Expands to the integer constant
.Dq 199901L ,
indicating that
.Nm
conforms to
.St -isoC-99 .
.It __TIME__
Expands to a quoted string literal containing the time in the form
.Qq hh:mm:ss
as generated by the
.Xr asctime 3
function.
.El
.Pp
Also see the
.Fl t
option.
.Sh EXIT STATUS
The
.Nm
utility exits with one of the following values:
.Lp
.Bl -tag -width Ds -offset indent -compact
.It 0
Successfully finished.
.It 1
An error occurred.
.It 2
The
.Fl E
option was given, and warnings were issued.
.El
.Sh SEE ALSO
.Xr as 1 ,
.Xr ccom 1 ,
.Xr make 1 ,
.Xr pcc 1 ,
.Xr asctime 3
.Sh HISTORY
The
.Nm
command comes from the original Portable C Compiler by
.An "S. C. Johnson" ,
written in the late 70's.
The code originates from the V6 preprocessor with some additions
from V7 cpp and ansi/c99 support.
.Pp
A lot of the PCC code was rewritten by
.An "Anders Magnusson" .
.Pp
This product includes software developed or owned by Caldera
International, Inc.


================================================
FILE: initrd/usr/share/man/man1/p++.1
================================================
.\"	$Id: cc.1,v 1.45 2016/10/10 11:27:49 ragge Exp $
.\"
.\" Copyright (c) 2007 Jeremy C. Reed <reed@reedmedia.net>
.\"
.\" Permission to use, copy, modify, and/or distribute this software for any
.\" purpose with or without fee is hereby granted, provided that the above
.\" copyright notice and this permission notice appear in all copies.
.\"
.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR AND CONTRIBUTORS DISCLAIM
.\" ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
.\" WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL AUTHOR AND
.\" CONTRIBUTORS BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
.\" DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
.\" PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
.\" ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
.\" THIS SOFTWARE.
.\"
.Dd June 20, 2014
.Dt CC 1
.Os
.Sh NAME
.Nm cc
.Nd front-end to the C compiler
.Sh SYNOPSIS
.Nm
.Op Fl cEgkMPSstvX
.Op Fl ansi
.Op Fl B Ns Ar prefix
.Op Fl D Ar macro Ns Oo = Ns Ar value Oc
.Op Fl d Ns Ar flags
.Op Fl f Ns Ar feature
.Op Fl I Ar path
.Op Fl include Ar file
.Op Fl isystem Ar path
.Op Fl L Ns Ar path
.Op Fl m Ns Ar option
.Op Fl nodefaultlibs
.Op Fl nostartfiles
.Op Fl nostdinc
.Op Fl nostdlib
.Op Fl O Ns Oo Ar level Oc
.Op Fl o Ar outfile
.Op Fl pg
.Op Fl pthread
.Op Fl shared
.Op Fl static
.Op Fl std= Ns Ar standard
.Op Fl U Ar macro
.Op Fl Wa Ns , Ns Ar options
.Op Fl Wc Ns , Ns Ar options
.Op Fl Wl Ns , Ns Ar options
.Op Fl Wp Ns , Ns Ar options
.Op Fl x Ar language
.Op Fl z Ar keyword
.Op Ar
.Sh DESCRIPTION
The
.Nm
utility provides a front-end to the
.Dq portable C compiler .
Multiple files may be given on the command line.
Unrecognized options are sent directly to
.Xr ld 1 .
.Pp
.\" Brief description of its syntax:
Filenames that end with
.Sy \&.c
are passed via
.Xr cpp 1
\(->
.Xr ccom 1
\(->
.Xr as 1
\(->
.Xr ld 1 .
.Pp
Filenames that end with
.Sy \&.i
are passed via
.Xr ccom 1
\(->
.Xr as 1
\(->
.Xr ld 1 .
.Pp
Filenames that end with
.Sy \&.s
are passed via
.Xr as 1
\(->
.Xr ld 1 .
.Pp
Filenames that end with
.Sy \&.S
are passed via
.Xr cpp 1
\(->
.Xr as 1
\(->
.Xr ld 1 .
.Pp
Filenames that end with
.Sy \&.o
are passed directly to
.Xr ld 1 .
.Pp
.\"
The options are as follows:
.Bl -tag -width Ds
.It Fl ansi
Synonym for
.Fl std=c89 .
.It Fl B Ns Ar prefix
Define alternate prefix path for
.Xr cpp 1 ,
.Xr ccom 1 ,
.Xr as 1 ,
or
.Xr ld 1
executables.
.\" TODO: provide an example of -B
.It Fl C
Passed to the
.Xr cpp 1
preprocessor to not discard comments.
.It Fl c
Stop after generating object code with
.Xr as 1 .
Do not link.
The resulting object output is saved
as a filename with a
.Dq \&.o
suffix unless
.Fl o
option is used.
Note: cannot be combined with
.Fl o
if multiple files are given.
.It Fl D Ar macro Ns Oo = Ns Ar value Oc
Passed to the
.Xr cpp 1
preprocessor to define
.Ar macro
with an optional
.Ar value .
.It Fl d Ns Ar flags
Debug options.
.Ar flags
is a string of characters, which signify the following actions.
.Bl -tag -width ".Sy M"
.It Sy M
Cause the preprocessor to output a list of macro definitions.
.El
.Lp
any unknown flags are ignored.
.It Fl E
Stop after preprocessing with
.Xr cpp 1 .
Do not compile, assemble, or link.
Output is sent to standard output unless the
.Fl o
option is used.
.It Fl ffreestanding
Assume a freestanding environment.
.It Fl fPIC
Generate PIC code.
.\" TODO: document about avoiding machine-specific maximum size?
.It Fl fpic
Tells C compiler to generate PIC code
and tells assembler that PIC code has been generated.
.\" TODO: document difference between PIC and pic
.It Fl funsigned-char
Tell the compiler to treat
.Sq char
types as if they were unsigned unless explicitly defined otherwise.
.Fl fsigned-char
can be used to signify the opposite behaviour.
The default for the
.Sq char
type depends on the compiler target architecture.
.It Fl fstack-protector
Tell the compiler to wrap functions with code which checks at
runtime that a stack overflow has not occurred.
When stack protection is in effect, the
.Dv __SSP__
macro will be defined.
.\" other -f GCC compatibility flags are ignored for now
.It Fl g
Send
.Fl g
flag to
.Xr ccom 1
to create debug output.
Debug information output can be disabled with
.Fl g0 .
.It Fl I Ar path
Passed to the
.Xr cpp 1
preprocessor to add header search directory to override system defaults.
.It Fl include Ar file
Tells the
.Xr cpp 1
preprocessor to include the
.Ar file
during preprocessing.
.It Fl isystem Ar path
Defines
.Ar path
as a system header directory for the
.Xr cpp 1
preprocessor.
.It Fl k
Generate PIC code.
See
.Fl fpic
option.
.It Fl L Ns Ar path
Passed to the linker, to add
.Ar path
to the list of directories searched for shared libraries.
.It Fl M
Pass
.Fl M
flag to
.Xr cpp 1
to generate dependencies for
.Xr make 1 .
.It Fl m Ns Ar option
Target-dependent options.
Multiple
.Fl m
options can be given, the following are supported:
.Bl -tag -width PowerPC
.It ARM
\-mlittle-endian \-mbig-endian \-mfpe=fpa \-mfpe=vpf \-msoft-float \-march=armv1 \-march=armv2 \-march=armv2a \-march=armv3 \-march=armv4 \-march=armv4t \-march=armv4tej \-march=armv5 \-march=armv6 \-march=armv6t2 \-march=armv6kz \-march=armv6k \-march=armv7
.It HPPA
.It i386
.It MIPS
\-mlittle-endian \-mbig-endian \-mhard-float \-msoft-float
.It PDP-10
.It PowerPC
.It Sparc64
.It VAX
.El
.It Fl nodefaultlibs
Do not link with the system default libraries (libc, etc.)
.It Fl nostartfiles
Do not link with the system startup files (crt0.c, etc.)
.It Fl nostdinc
Do not use the system include paths (/usr/include, etc.)
.It Fl nostdlib
Do not link with the system default libraries or startup files.
.It Fl O Ns Oo Ar level Oc
Enable compiler optimizations.
Currently, for levels higher than zero,
this defines
.Dv __OPTIMIZE__
in the
.Xr cpp 1
preprocessor, and passes
.Fl xdce ,
.Fl xdeljumps ,
.Fl xtemps
and
.Fl xinline
to
.Xr ccom 1 .
If no level is given the optimization level is
.Fl O1 .
Optimizations can be disabled using
.Fl O0 .
In situations where multiple optimization flags are given, the last flag is the
one used.
.It Fl o Ar outfile
Save result to
.Ar outfile .
.It Fl P
Inhibit generation of line markers in preprocessor output.
This is sometimes useful when running the preprocessor on something other than C code.
.It Fl pg
Enable profiling on the generated executable.
.It Fl pthread
Defines the
.Dv _PTHREADS
preprocessor identifier for
.Xr cpp 1 , and
adds
.Fl lpthread
to the
.Xr ld 1
linker arguments.
.It Fl S
Stop after compilation by
.Xr ccom 1 .
Do not assemble and do not link.
The resulting assembler-language output is saved
as a filename with a
.Dq \&.s
suffix unless the
.Fl o
option is used.
Note: cannot be combined with
.Fl o
if multiple files are given.
.It Fl s
Passed to
.Xr ld 1
to remove all symbol table and relocation information from the generated
executable.
This option is silently ignored if
.Nm
does not invoke the linker.
.It Fl shared
Create a shared object of the result.
Tells the linker not to generate an executable.
.It Fl static
Do not use dynamic linkage.
By default, it will link using the dynamic linker options
and/or shared objects for the platform.
.It Fl std= Ns Ar standard
Compile to the specified
.Ar standard .
Accepted values for
.Ar standard
are
.Ar c89 ,
.Ar c99 ,
.Ar gnu89 ,
.Ar gnu99 ,
.Ar gnu9x ,
and
.Ar c11 .
.It Fl t
Passed to
.Xr cpp 1
to suppress some default macro definitions and enable use
of traditional C preprocessor syntax.
.It Fl U Ar macro
Passes to the
.Xr cpp 1
preprocessor to remove the initial macro definition.
.It Fl v
Outputs the version of
.Nm
and shows commands as they are run with their command line arguments.
.It Fl ###
As per
.Fl v
except that the commands are not run, and the arguments will be quoted
if they contain unusual characters or spaces.
.It Fl Wa Ns , Ns Ar options
Comma separated list of options for the assembler.
.It Fl Wc Ns , Ns Ar options
Comma separated list of options for the compiler.
.It Fl Wl Ns , Ns Ar options
Comma separated list of options for the linker.
.It Fl Wp Ns , Ns Ar options
Comma separated list of options for the preprocessor.
.It Fl X
Don't remove temporary files on exit.
.It Fl x Ar language
GCC compatibility option; specify the language in use rather than
interpreting the filename extension.
Currently known language values are
.Sy none ,
.Sy c ,
.Sy c++ ,
.Sy assembler
and
.Sy assembler-with-cpp .
Any unknown
.Fl x
options are passed to
.Xr ccom 1 .
.It Fl z Ar keyword
Passed to
.Xr ld 1 .
Please refer to the documentation of your linker for acceptable values of
.Ar keyword .
.El
.Ss Predefined Macros
A few
macros are predefined by
.Nm
when sent to
.Xr cpp 1 .
.Bl -diag
.It __PCC__
Set to the major version of
.Xr pcc 1 .
These macros can be used to select code based on
.Xr pcc 1
compatibility.
See the
.Fl v
option.
.It __PCC_MINOR__
Set to the minor version.
.It __PCC_MINORMINOR__
Set to the minor-minor version \(em the number after the minor version.
.It _PTHREADS
Defined when
.Fl pthread
switch is used.
.It __ASSEMBLER__
Defined when input files have a .S suffix, or if the
.Fl x Ns assembler-with-cpp
option is specified.
.El
.Pp
Also system- and/or machine-dependent macros may also be predefined;
for example:
.Dv __NetBSD__ ,
.Dv __ELF__ ,
and
.Dv __i386__ .
.Sh SEE ALSO
.Xr as 1 ,
.Xr ccom 1 ,
.Xr cpp 1 ,
.Xr ld 1
.Sh HISTORY
The
.Nm
command comes from the original Portable C Compiler by
.An "S. C. Johnson" ,
written in the late 70's.
.Pp
This product includes software developed or owned by Caldera
International, Inc.


================================================
FILE: initrd/usr/share/man/man1/pcc.1
================================================
.\"	$Id: cc.1,v 1.45 2016/10/10 11:27:49 ragge Exp $
.\"
.\" Copyright (c) 2007 Jeremy C. Reed <reed@reedmedia.net>
.\"
.\" Permission to use, copy, modify, and/or distribute this software for any
.\" purpose with or without fee is hereby granted, provided that the above
.\" copyright notice and this permission notice appear in all copies.
.\"
.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR AND CONTRIBUTORS DISCLAIM
.\" ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
.\" WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL AUTHOR AND
.\" CONTRIBUTORS BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
.\" DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
.\" PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
.\" ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
.\" THIS SOFTWARE.
.\"
.Dd June 20, 2014
.Dt CC 1
.Os
.Sh NAME
.Nm cc
.Nd front-end to the C compiler
.Sh SYNOPSIS
.Nm
.Op Fl cEgkMPSstvX
.Op Fl ansi
.Op Fl B Ns Ar prefix
.Op Fl D Ar macro Ns Oo = Ns Ar value Oc
.Op Fl d Ns Ar flags
.Op Fl f Ns Ar feature
.Op Fl I Ar path
.Op Fl include Ar file
.Op Fl isystem Ar path
.Op Fl L Ns Ar path
.Op Fl m Ns Ar option
.Op Fl nodefaultlibs
.Op Fl nostartfiles
.Op Fl nostdinc
.Op Fl nostdlib
.Op Fl O Ns Oo Ar level Oc
.Op Fl o Ar outfile
.Op Fl pg
.Op Fl pthread
.Op Fl shared
.Op Fl static
.Op Fl std= Ns Ar standard
.Op Fl U Ar macro
.Op Fl Wa Ns , Ns Ar options
.Op Fl Wc Ns , Ns Ar options
.Op Fl Wl Ns , Ns Ar options
.Op Fl Wp Ns , Ns Ar options
.Op Fl x Ar language
.Op Fl z Ar keyword
.Op Ar
.Sh DESCRIPTION
The
.Nm
utility provides a front-end to the
.Dq portable C compiler .
Multiple files may be given on the command line.
Unrecognized options are sent directly to
.Xr ld 1 .
.Pp
.\" Brief description of its syntax:
Filenames that end with
.Sy \&.c
are passed via
.Xr cpp 1
\(->
.Xr ccom 1
\(->
.Xr as 1
\(->
.Xr ld 1 .
.Pp
Filenames that end with
.Sy \&.i
are passed via
.Xr ccom 1
\(->
.Xr as 1
\(->
.Xr ld 1 .
.Pp
Filenames that end with
.Sy \&.s
are passed via
.Xr as 1
\(->
.Xr ld 1 .
.Pp
Filenames that end with
.Sy \&.S
are passed via
.Xr cpp 1
\(->
.Xr as 1
\(->
.Xr ld 1 .
.Pp
Filenames that end with
.Sy \&.o
are passed directly to
.Xr ld 1 .
.Pp
.\"
The options are as follows:
.Bl -tag -width Ds
.It Fl ansi
Synonym for
.Fl std=c89 .
.It Fl B Ns Ar prefix
Define alternate prefix path for
.Xr cpp 1 ,
.Xr ccom 1 ,
.Xr as 1 ,
or
.Xr ld 1
executables.
.\" TODO: provide an example of -B
.It Fl C
Passed to the
.Xr cpp 1
preprocessor to not discard comments.
.It Fl c
Stop after generating object code with
.Xr as 1 .
Do not link.
The resulting object output is saved
as a filename with a
.Dq \&.o
suffix unless
.Fl o
option is used.
Note: cannot be combined with
.Fl o
if multiple files are given.
.It Fl D Ar macro Ns Oo = Ns Ar value Oc
Passed to the
.Xr cpp 1
preprocessor to define
.Ar macro
with an optional
.Ar value .
.It Fl d Ns Ar flags
Debug options.
.Ar flags
is a string of characters, which signify the following actions.
.Bl -tag -width ".Sy M"
.It Sy M
Cause the preprocessor to output a list of macro definitions.
.El
.Lp
any unknown flags are ignored.
.It Fl E
Stop after preprocessing with
.Xr cpp 1 .
Do not compile, assemble, or link.
Output is sent to standard output unless the
.Fl o
option is used.
.It Fl ffreestanding
Assume a freestanding environment.
.It Fl fPIC
Generate PIC code.
.\" TODO: document about avoiding machine-specific maximum size?
.It Fl fpic
Tells C compiler to generate PIC code
and tells assembler that PIC code has been generated.
.\" TODO: document difference between PIC and pic
.It Fl funsigned-char
Tell the compiler to treat
.Sq char
types as if they were unsigned unless explicitly defined otherwise.
.Fl fsigned-char
can be used to signify the opposite behaviour.
The default for the
.Sq char
type depends on the compiler target architecture.
.It Fl fstack-protector
Tell the compiler to wrap functions with code which checks at
runtime that a stack overflow has not occurred.
When stack protection is in effect, the
.Dv __SSP__
macro will be defined.
.\" other -f GCC compatibility flags are ignored for now
.It Fl g
Send
.Fl g
flag to
.Xr ccom 1
to create debug output.
Debug information output can be disabled with
.Fl g0 .
.It Fl I Ar path
Passed to the
.Xr cpp 1
preprocessor to add header search directory to override system defaults.
.It Fl include Ar file
Tells the
.Xr cpp 1
preprocessor to include the
.Ar file
during preprocessing.
.It Fl isystem Ar path
Defines
.Ar path
as a system header directory for the
.Xr cpp 1
preprocessor.
.It Fl k
Generate PIC code.
See
.Fl fpic
option.
.It Fl L Ns Ar path
Passed to the linker, to add
.Ar path
to the list of directories searched for shared libraries.
.It Fl M
Pass
.Fl M
flag to
.Xr cpp 1
to generate dependencies for
.Xr make 1 .
.It Fl m Ns Ar option
Target-dependent options.
Multiple
.Fl m
options can be given, the following are supported:
.Bl -tag -width PowerPC
.It ARM
\-mlittle-endian \-mbig-endian \-mfpe=fpa \-mfpe=vpf \-msoft-float \-march=armv1 \-march=armv2 \-march=armv2a \-march=armv3 \-march=armv4 \-march=armv4t \-march=armv4tej \-march=armv5 \-march=armv6 \-march=armv6t2 \-march=armv6kz \-march=armv6k \-march=armv7
.It HPPA
.It i386
.It MIPS
\-mlittle-endian \-mbig-endian \-mhard-float \-msoft-float
.It PDP-10
.It PowerPC
.It Sparc64
.It VAX
.El
.It Fl nodefaultlibs
Do not link with the system default libraries (libc, etc.)
.It Fl nostartfiles
Do not link with the system startup files (crt0.c, etc.)
.It Fl nostdinc
Do not use the system include paths (/usr/include, etc.)
.It Fl nostdlib
Do not link with the system default libraries or startup files.
.It Fl O Ns Oo Ar level Oc
Enable compiler optimizations.
Currently, for levels higher than zero,
this defines
.Dv __OPTIMIZE__
in the
.Xr cpp 1
preprocessor, and passes
.Fl xdce ,
.Fl xdeljumps ,
.Fl xtemps
and
.Fl xinline
to
.Xr ccom 1 .
If no level is given the optimization level is
.Fl O1 .
Optimizations can be disabled using
.Fl O0 .
In situations where multiple optimization flags are given, the last flag is the
one used.
.It Fl o Ar outfile
Save result to
.Ar outfile .
.It Fl P
Inhibit generation of line markers in preprocessor output.
This is sometimes useful when running the preprocessor on something other than C code.
.It Fl pg
Enable profiling on the generated executable.
.It Fl pthread
Defines the
.Dv _PTHREADS
preprocessor identifier for
.Xr cpp 1 , and
adds
.Fl lpthread
to the
.Xr ld 1
linker arguments.
.It Fl S
Stop after compilation by
.Xr ccom 1 .
Do not assemble and do not link.
The resulting assembler-language output is saved
as a filename with a
.Dq \&.s
suffix unless the
.Fl o
option is used.
Note: cannot be combined with
.Fl o
if multiple files are given.
.It Fl s
Passed to
.Xr ld 1
to remove all symbol table and relocation information from the generated
executable.
This option is silently ignored if
.Nm
does not invoke the linker.
.It Fl shared
Create a shared object of the result.
Tells the linker not to generate an executable.
.It Fl static
Do not use dynamic linkage.
By default, it will link using the dynamic linker options
and/or shared objects for the platform.
.It Fl std= Ns Ar standard
Compile to the specified
.Ar standard .
Accepted values for
.Ar standard
are
.Ar c89 ,
.Ar c99 ,
.Ar gnu89 ,
.Ar gnu99 ,
.Ar gnu9x ,
and
.Ar c11 .
.It Fl t
Passed to
.Xr cpp 1
to suppress some default macro definitions and enable use
of traditional C preprocessor syntax.
.It Fl U Ar macro
Passes to the
.Xr cpp 1
preprocessor to remove the initial macro definition.
.It Fl v
Outputs the version of
.Nm
and shows commands as they are run with their command line arguments.
.It Fl ###
As per
.Fl v
except that the commands are not run, and the arguments will be quoted
if they contain unusual characters or spaces.
.It Fl Wa Ns , Ns Ar options
Comma separated list of options for the assembler.
.It Fl Wc Ns , Ns Ar options
Comma separated list of options for the compiler.
.It Fl Wl Ns , Ns Ar options
Comma separated list of options for the linker.
.It Fl Wp Ns , Ns Ar options
Comma separated list of options for the preprocessor.
.It Fl X
Don't remove temporary files on exit.
.It Fl x Ar language
GCC compatibility option; specify the language in use rather than
interpreting the filename extension.
Currently known language values are
.Sy none ,
.Sy c ,
.Sy c++ ,
.Sy assembler
and
.Sy assembler-with-cpp .
Any unknown
.Fl x
options are passed to
.Xr ccom 1 .
.It Fl z Ar keyword
Passed to
.Xr ld 1 .
Please refer to the documentation of your linker for acceptable values of
.Ar keyword .
.El
.Ss Predefined Macros
A few
macros are predefined by
.Nm
when sent to
.Xr cpp 1 .
.Bl -diag
.It __PCC__
Set to the major version of
.Xr pcc 1 .
These macros can be used to select code based on
.Xr pcc 1
compatibility.
See the
.Fl v
option.
.It __PCC_MINOR__
Set to the minor version.
.It __PCC_MINORMINOR__
Set to the minor-minor version \(em the number after the minor version.
.It _PTHREADS
Defined when
.Fl pthread
switch is used.
.It __ASSEMBLER__
Defined when input files have a .S suffix, or if the
.Fl x Ns assembler-with-cpp
option is specified.
.El
.Pp
Also system- and/or machine-dependent macros may also be predefined;
for example:
.Dv __NetBSD__ ,
.Dv __ELF__ ,
and
.Dv __i386__ .
.Sh SEE ALSO
.Xr as 1 ,
.Xr ccom 1 ,
.Xr cpp 1 ,
.Xr ld 1
.Sh HISTORY
The
.Nm
command comes from the original Portable C Compiler by
.An "S. C. Johnson" ,
written in the late 70's.
.Pp
This product includes software developed or owned by Caldera
International, Inc.


================================================
FILE: initrd/usr/share/man/man1/pcpp.1
================================================
.\"	$Id: cc.1,v 1.45 2016/10/10 11:27:49 ragge Exp $
.\"
.\" Copyright (c) 2007 Jeremy C. Reed <reed@reedmedia.net>
.\"
.\" Permission to use, copy, modify, and/or distribute this software for any
.\" purpose with or without fee is hereby granted, provided that the above
.\" copyright notice and this permission notice appear in all copies.
.\"
.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR AND CONTRIBUTORS DISCLAIM
.\" ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
.\" WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL AUTHOR AND
.\" CONTRIBUTORS BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
.\" DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
.\" PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
.\" ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
.\" THIS SOFTWARE.
.\"
.Dd June 20, 2014
.Dt CC 1
.Os
.Sh NAME
.Nm cc
.Nd front-end to the C compiler
.Sh SYNOPSIS
.Nm
.Op Fl cEgkMPSstvX
.Op Fl ansi
.Op Fl B Ns Ar prefix
.Op Fl D Ar macro Ns Oo = Ns Ar value Oc
.Op Fl d Ns Ar flags
.Op Fl f Ns Ar feature
.Op Fl I Ar path
.Op Fl include Ar file
.Op Fl isystem Ar path
.Op Fl L Ns Ar path
.Op Fl m Ns Ar option
.Op Fl nodefaultlibs
.Op Fl nostartfiles
.Op Fl nostdinc
.Op Fl nostdlib
.Op Fl O Ns Oo Ar level Oc
.Op Fl o Ar outfile
.Op Fl pg
.Op Fl pthread
.Op Fl shared
.Op Fl static
.Op Fl std= Ns Ar standard
.Op Fl U Ar macro
.Op Fl Wa Ns , Ns Ar options
.Op Fl Wc Ns , Ns Ar options
.Op Fl Wl Ns , Ns Ar options
.Op Fl Wp Ns , Ns Ar options
.Op Fl x Ar language
.Op Fl z Ar keyword
.Op Ar
.Sh DESCRIPTION
The
.Nm
utility provides a front-end to the
.Dq portable C compiler .
Multiple files may be given on the command line.
Unrecognized options are sent directly to
.Xr ld 1 .
.Pp
.\" Brief description of its syntax:
Filenames that end with
.Sy \&.c
are passed via
.Xr cpp 1
\(->
.Xr ccom 1
\(->
.Xr as 1
\(->
.Xr ld 1 .
.Pp
Filenames that end with
.Sy \&.i
are passed via
.Xr ccom 1
\(->
.Xr as 1
\(->
.Xr ld 1 .
.Pp
Filenames that end with
.Sy \&.s
are passed via
.Xr as 1
\(->
.Xr ld 1 .
.Pp
Filenames that end with
.Sy \&.S
are passed via
.Xr cpp 1
\(->
.Xr as 1
\(->
.Xr ld 1 .
.Pp
Filenames that end with
.Sy \&.o
are passed directly to
.Xr ld 1 .
.Pp
.\"
The options are as follows:
.Bl -tag -width Ds
.It Fl ansi
Synonym for
.Fl std=c89 .
.It Fl B Ns Ar prefix
Define alternate prefix path for
.Xr cpp 1 ,
.Xr ccom 1 ,
.Xr as 1 ,
or
.Xr ld 1
executables.
.\" TODO: provide an example of -B
.It Fl C
Passed to the
.Xr cpp 1
preprocessor to not discard comments.
.It Fl c
Stop after generating object code with
.Xr as 1 .
Do not link.
The resulting object output is saved
as a filename with a
.Dq \&.o
suffix unless
.Fl o
option is used.
Note: cannot be combined with
.Fl o
if multiple files are given.
.It Fl D Ar macro Ns Oo = Ns Ar value Oc
Passed to the
.Xr cpp 1
preprocessor to define
.Ar macro
with an optional
.Ar value .
.It Fl d Ns Ar flags
Debug options.
.Ar flags
is a string of characters, which signify the following actions.
.Bl -tag -width ".Sy M"
.It Sy M
Cause the preprocessor to output a list of macro definitions.
.El
.Lp
any unknown flags are ignored.
.It Fl E
Stop after preprocessing with
.Xr cpp 1 .
Do not compile, assemble, or link.
Output is sent to standard output unless the
.Fl o
option is used.
.It Fl ffreestanding
Assume a freestanding environment.
.It Fl fPIC
Generate PIC code.
.\" TODO: document about avoiding machine-specific maximum size?
.It Fl fpic
Tells C compiler to generate PIC code
and tells assembler that PIC code has been generated.
.\" TODO: document difference between PIC and pic
.It Fl funsigned-char
Tell the compiler to treat
.Sq char
types as if they were unsigned unless explicitly defined otherwise.
.Fl fsigned-char
can be used to signify the opposite behaviour.
The default for the
.Sq char
type depends on the compiler target architecture.
.It Fl fstack-protector
Tell the compiler to wrap functions with code which checks at
runtime that a stack overflow has not occurred.
When stack protection is in effect, the
.Dv __SSP__
macro will be defined.
.\" other -f GCC compatibility flags are ignored for now
.It Fl g
Send
.Fl g
flag to
.Xr ccom 1
to create debug output.
Debug information output can be disabled with
.Fl g0 .
.It Fl I Ar path
Passed to the
.Xr cpp 1
preprocessor to add header search directory to override system defaults.
.It Fl include Ar file
Tells the
.Xr cpp 1
preprocessor to include the
.Ar file
during preprocessing.
.It Fl isystem Ar path
Defines
.Ar path
as a system header directory for the
.Xr cpp 1
preprocessor.
.It Fl k
Generate PIC code.
See
.Fl fpic
option.
.It Fl L Ns Ar path
Passed to the linker, to add
.Ar path
to the list of directories searched for shared libraries.
.It Fl M
Pass
.Fl M
flag to
.Xr cpp 1
to generate dependencies for
.Xr make 1 .
.It Fl m Ns Ar option
Target-dependent options.
Multiple
.Fl m
options can be given, the following are supported:
.Bl -tag -width PowerPC
.It ARM
\-mlittle-endian \-mbig-endian \-mfpe=fpa \-mfpe=vpf \-msoft-float \-march=armv1 \-march=armv2 \-march=armv2a \-march=armv3 \-march=armv4 \-march=armv4t \-march=armv4tej \-march=armv5 \-march=armv6 \-march=armv6t2 \-march=armv6kz \-march=armv6k \-march=armv7
.It HPPA
.It i386
.It MIPS
\-mlittle-endian \-mbig-endian \-mhard-float \-msoft-float
.It PDP-10
.It PowerPC
.It Sparc64
.It VAX
.El
.It Fl nodefaultlibs
Do not link with the system default libraries (libc, etc.)
.It Fl nostartfiles
Do not link with the system startup files (crt0.c, etc.)
.It Fl nostdinc
Do not use the system include paths (/usr/include, etc.)
.It Fl nostdlib
Do not link with the system default libraries or startup files.
.It Fl O Ns Oo Ar level Oc
Enable compiler optimizations.
Currently, for levels higher than zero,
this defines
.Dv __OPTIMIZE__
in the
.Xr cpp 1
preprocessor, and passes
.Fl xdce ,
.Fl xdeljumps ,
.Fl xtemps
and
.Fl xinline
to
.Xr ccom 1 .
If no level is given the optimization level is
.Fl O1 .
Optimizations can be disabled using
.Fl O0 .
In situations where multiple optimization flags are given, the last flag is the
one used.
.It Fl o Ar outfile
Save result to
.Ar outfile .
.It Fl P
Inhibit generation of line markers in preprocessor output.
This is sometimes useful when running the preprocessor on something other than C code.
.It Fl pg
Enable profiling on the generated executable.
.It Fl pthread
Defines the
.Dv _PTHREADS
preprocessor identifier for
.Xr cpp 1 , and
adds
.Fl lpthread
to the
.Xr ld 1
linker arguments.
.It Fl S
Stop after compilation by
.Xr ccom 1 .
Do not assemble and do not link.
The resulting assembler-language output is saved
as a filename with a
.Dq \&.s
suffix unless the
.Fl o
option is used.
Note: cannot be combined with
.Fl o
if multiple files are given.
.It Fl s
Passed to
.Xr ld 1
to remove all symbol table and relocation information from the generated
executable.
This option is silently ignored if
.Nm
does not invoke the linker.
.It Fl shared
Create a shared object of the result.
Tells the linker not to generate an executable.
.It Fl static
Do not use dynamic linkage.
By default, it will link using the dynamic linker options
and/or shared objects for the platform.
.It Fl std= Ns Ar standard
Compile to the specified
.Ar standard .
Accepted values for
.Ar standard
are
.Ar c89 ,
.Ar c99 ,
.Ar gnu89 ,
.Ar gnu99 ,
.Ar gnu9x ,
and
.Ar c11 .
.It Fl t
Passed to
.Xr cpp 1
to suppress some default macro definitions and enable use
of traditional C preprocessor syntax.
.It Fl U Ar macro
Passes to the
.Xr cpp 1
preprocessor to remove the initial macro definition.
.It Fl v
Outputs the version of
.Nm
and shows commands as they are run with their command line arguments.
.It Fl ###
As per
.Fl v
except that the commands are not run, and the arguments will be quoted
if they contain unusual characters or spaces.
.It Fl Wa Ns , Ns Ar options
Comma separated list of options for the assembler.
.It Fl Wc Ns , Ns Ar options
Comma separated list of options for the compiler.
.It Fl Wl Ns , Ns Ar options
Comma separated list of options for the linker.
.It Fl Wp Ns , Ns Ar options
Comma separated list of options for the preprocessor.
.It Fl X
Don't remove temporary files on exit.
.It Fl x Ar language
GCC compatibility option; specify the language in use rather than
interpreting the filename extension.
Currently known language values are
.Sy none ,
.Sy c ,
.Sy c++ ,
.Sy assembler
and
.Sy assembler-with-cpp .
Any unknown
.Fl x
options are passed to
.Xr ccom 1 .
.It Fl z Ar keyword
Passed to
.Xr ld 1 .
Please refer to the documentation of your linker for acceptable values of
.Ar keyword .
.El
.Ss Predefined Macros
A few
macros are predefined by
.Nm
when sent to
.Xr cpp 1 .
.Bl -diag
.It __PCC__
Set to the major version of
.Xr pcc 1 .
These macros can be used to select code based on
.Xr pcc 1
compatibility.
See the
.Fl v
option.
.It __PCC_MINOR__
Set to the minor version.
.It __PCC_MINORMINOR__
Set to the minor-minor version \(em the number after the minor version.
.It _PTHREADS
Defined when
.Fl pthread
switch is used.
.It __ASSEMBLER__
Defined when input files have a .S suffix, or if the
.Fl x Ns assembler-with-cpp
option is specified.
.El
.Pp
Also system- and/or machine-dependent macros may also be predefined;
for example:
.Dv __NetBSD__ ,
.Dv __ELF__ ,
and
.Dv __i386__ .
.Sh SEE ALSO
.Xr as 1 ,
.Xr ccom 1 ,
.Xr cpp 1 ,
.Xr ld 1
.Sh HISTORY
The
.Nm
command comes from the original Portable C Compiler by
.An "S. C. Johnson" ,
written in the late 70's.
.Pp
This product includes software developed or owned by Caldera
International, Inc.


================================================
FILE: initrd/usr/test.c
================================================
#include <stdio.h>

int main()
{
    puts("Hello, World!\n");
}


================================================
FILE: iso/boot/grub/grub.cfg
================================================
set timeout=5
set default=0

menuentry "Aquila" {
	multiboot /kernel.elf.gz earlycon=ttyS0
	module /initrd.img.gz
	boot
}


================================================
FILE: kernel/Makefile
================================================
export

PDIR := $(SRCDIR)/kernel

#
# Add include pathes to CFLAGS & ASFLAGS
#

CFLAGS += \
	-I. \
	-I$(PDIR)/arch/$(ARCH_DIR)/platform/$(PLATFORM_DIR)/include \
	-I$(PDIR)/arch/$(ARCH_DIR)/include \
	-I$(PDIR)/include \
	-I$(PDIR)

ASFLAGS += \
	-I. \
	-I$(PDIR)/arch/$(ARCH_DIR)/platform/$(PLATFORM_DIR)/include \
	-I$(PDIR)/arch/$(ARCH_DIR)/include \
	-I$(PDIR)/include \
	-I$(PDIR)

dirs-y = core/ fs/ dev/ sys/ mm/ net/

all: $(dirs-y) arch/

.PHONY: $(dirs-y)
$(dirs-y): $(patsubst %/,%/Makefile, $(dirs-y))
	@$(ECHO) "  MK      " kernel/$@
	@$(MAKE) -C $@ $(param)

.PHONY: arch/
arch/: $(dirs-y) arch/Makefile
	@$(ECHO) "  MK      " kernel/$@
	@$(MAKE) -C $@ $(param)

.PHONY: install
install: all
	@$(ECHO) "Installing kernel-$(VERSION).$(ARCH) into $(DESTDIR)/boot/kernel"
	@$(MKDIR) -p $(DESTDIR)/boot
	@$(CP) arch/$(ARCH)/kernel-$(VERSION).$(ARCH) $(DESTDIR)/boot/kernel

.PHONY: clean
clean: param = clean
clean: $(dirs-y) arch/



================================================
FILE: kernel/README.md
================================================
# AquilaOS Kernel

### Source tree structure
- arch/     - all arch. dependent code
- configs/  - configurations used during build
- core/     - system components that do not fit anywhere else
- dev/      - kdev and supported devices
- fs/       - vfs and supported filesystems
- include/  - generic include headers
- mm/       - arch independent memory management
- scripts/  - scripts used during build
- sys/      - core system components (processes, threads, scheduler, etc...)



================================================
FILE: kernel/arch/Build.mk
================================================
dirs-$(ARCH_NONE)   += none/
dirs-$(ARCH_I386)   += i386/
dirs-$(ARCH_X86_64) += x86_64/
dirs-$(ARCH_ARM)    += arm/


================================================
FILE: kernel/arch/Makefile
================================================
include Build.mk

CWD != realpath --relative-to=$(SRCDIR) .

all: builtin.o $(elf)

builtin.o: $(obj-y) $(dirs-y)
	@$(ECHO) "  LD      " $(CWD)/builtin.o
	@$(LD) $(LDFLAGS) -r $(obj-y) $(patsubst %/,%/builtin.o, $(dirs-y)) -o $(BUILDDIR)/$(CWD)/builtin.o

.PHONY: $(dirs-y)
$(dirs-y): $(patsubst %/,%/Makefile, $(dirs-y))
	@$(ECHO) "  MK      " $(CWD)/$@
	@$(MAKE) -C $@ $(param)

%.o:%.c
	@$(ECHO) "  CC      " $(CWD)/$@
	@$(CC) $(CFLAGS) -c $< -o $@

%.o:%.S
	@$(ECHO) "  AS      " $(CWD)/$@
	@$(AS) $(ASFLAGS) -c $< -o $@

.PHONY: clean
clean: param = clean
clean: $(dirs-y)
	@$(ECHO) "  RM      " $(obj-y) $(elf) builtin.o
	@$(RM) $(obj-y) $(elf) builtin.o


================================================
FILE: kernel/arch/arm/Build.mk
================================================
obj-y  += none.o
elf    += kernel-$(VERSION).$(ARCH)

kernel-$(VERSION).$(ARCH): builtin.o
	@echo -e "  ELF     " $@;
	@$(LD) $(LDFLAGS) -Tkernel.$(ARCH).ld -lgcc -o $@


================================================
FILE: kernel/arch/arm/include/core/types.h
================================================
#ifndef _NONE_CORE_TYPES_H
#define _NONE_CORE_TYPES_H

typedef uintptr_t paddr_t;
typedef uintptr_t vaddr_t;

#include_next <core/types.h>

#endif /* _NONE_CORE_TYPES_H */


================================================
FILE: kernel/arch/arm/include/cpu/io.h
================================================
#ifndef _NONE_CPU_IO_H
#define _NONE_CPU_IO_H

#include_next <cpu/io.h>

static inline uint8_t io_in8(struct ioaddr *io, uintptr_t off)
{
    return 0;
}

static inline uint16_t io_in16(struct ioaddr *io, uintptr_t off)
{
    return 0;
}

static inline uint32_t io_in32(struct ioaddr *io, uintptr_t off)
{
    return 0;
}

static inline void io_out8(struct ioaddr *io, uintptr_t off, uint8_t val)
{
}

static inline void io_out16(struct ioaddr *io, uintptr_t off, uint16_t val)
{
}

static inline void io_out32(struct ioaddr *io, uintptr_t off, uint32_t val)
{
}

#endif /* ! _NONE_CPU_IO_H */


================================================
FILE: kernel/arch/arm/include/mm/mm.h
================================================
#ifndef _NONE_MM_MM_H
#define _NONE_MM_MM_H

#define USER_STACK_BASE 0
#define PAGE_SIZE   (0x1000)
#define PAGE_MASK   (PAGE_SIZE - 1)

#define ARCH_KVMEM_BASE 100
#define ARCH_KVMEM_NODES_SIZE   0

#define LMA(n)  (n)
#define VMA(n)  (n)

#include_next <mm/mm.h>

#endif  /* _NONE_MM_MM_H */


================================================
FILE: kernel/arch/arm/kernel.arm.ld
================================================
ENTRY(_start)
INPUT(builtin.o ../../core/builtin.o ../../fs/builtin.o ../../dev/builtin.o ../../sys/builtin.o ../../mm/builtin.o ../../net/builtin.o)
OUTPUT(kernel.elf)

SECTIONS {

    LMA = 0x80010000;
    . = LMA;

    .boot.text : ALIGN(0x1000) {
        *boot*.o(.text*)
        *boot*.o(.rodata*)
    }

    .boot.data : ALIGN(0x1000) {
        *boot*.o(.data)
    }

    .boot.bss (NOLOAD) : ALIGN(0x1000) {
        *boot*.o(*)
    }

    boot_end = .;

    _VMA = .;

    .text : AT(ADDR(.text) - _VMA) ALIGN(0x1000) {
        *(.text*)
        *(.rodata*)
    }

    .__minit : AT(ADDR(.__minit) - _VMA) ALIGN(0x1000) {
        __minit = .;
        *(.__minit*)
        __minit_end = .;
    }
    
    .data : AT(ADDR(.data) - _VMA) ALIGN(0x1000) {
        *(.data)
    }
    
    .bss : AT(ADDR(.bss) - _VMA) ALIGN(0x1000) {
        *(.bss)
    }
    
    /DISCARD/ : {
        *(.*)
    }
    
    kernel_end = . - _VMA;
}


================================================
FILE: kernel/arch/arm/none.c
================================================


================================================
FILE: kernel/arch/i386/Build.mk
================================================
dirs-y += boot/
dirs-y += cpu/
dirs-y += earlycon/
dirs-y += mm/
dirs-y += sys/
dirs-y += platform/

elf    += kernel-$(VERSION).$(ARCH)

kernel-$(VERSION).$(ARCH): builtin.o
	@echo "  ELF     " $(CWD)/$@;
	@$(LD) $(LDFLAGS) -T kernel.$(ARCH).ld -o $@


================================================
FILE: kernel/arch/i386/Makefile
================================================
include Build.mk

CWD != realpath --relative-to=$(SRCDIR) .

all: builtin.o $(elf)

builtin.o: $(obj-y) $(dirs-y)
	@$(ECHO) "  LD      " $(CWD)/builtin.o;
	@$(LD) $(LDFLAGS) -r $(obj-y) $(patsubst %/,%/builtin.o, $(dirs-y)) -o builtin.o; 

.PHONY: $(dirs-y)
$(dirs-y): $(patsubst %/,%/Makefile, $(dirs-y))
	@$(ECHO) "  MK      " $(CWD)/$@;
	@$(MAKE) -C $@ $(param)

%.o:%.c
	@$(ECHO) "  CC      " $(CWD)/$@;
	@$(CC) $(CFLAGS) -c $< -o $@

%.o:%.S
	@$(ECHO) "  AS      " $(CWD)/$@;
	@$(AS) $(ASFLAGS) -c $< -o $@

.PHONY: clean
clean: param = clean
clean: $(dirs-y)
	@$(ECHO) "  RM      " $(obj-y) $(elf) builtin.o
	@$(RM) $(obj-y) $(elf) builtin.o


================================================
FILE: kernel/arch/i386/boot/Build.mk
================================================
obj-$(X86_MULTIBOOT) += multiboot.o
obj-$(ARCH_X86_64)   += x86_64_bootstrap.o
obj-y += init.o
obj-y += sys.o


================================================
FILE: kernel/arch/i386/boot/Makefile
================================================
include Build.mk

CWD != realpath --relative-to=$(SRCDIR) .

all: builtin.o $(elf)

builtin.o: $(obj-y) $(dirs-y)
	@$(ECHO) "  LD      " $(CWD)/builtin.o;
	@$(LD) $(LDFLAGS) -r $(obj-y) $(patsubst %/,%/builtin.o, $(dirs-y)) -o builtin.o; 

.PHONY: $(dirs-y)
$(dirs-y): $(patsubst %/,%/Makefile, $(dirs-y))
	@$(ECHO) "  MK      " $(CWD)/$@;
	@$(MAKE) -C $@ $(param)

%.o:%.c
	@$(ECHO) "  CC      " $(CWD)/$@;
	@$(CC) $(CFLAGS) -c $< -o $@

%.o:%.S
	@$(ECHO) "  AS      " $(CWD)/$@;
	@$(AS) $(ASFLAGS) -c $< -o $@

.PHONY: clean
clean: param = clean
clean: $(dirs-y)
	@$(ECHO) "  RM      " $(obj-y) $(elf) builtin.o
	@$(RM) $(obj-y) $(elf) builtin.o


================================================
FILE: kernel/arch/i386/boot/init.c
================================================
/**********************************************************************
 *                  Early initalization of the kernel
 *                   (Switch to higher half kernel)
 *
 *
 *  This file is part of AquilaOS and is released under the terms of
 *  GNU GPLv3 - See LICENSE.
 *
 *  Copyright (C) Mohamed Anwar
 */

#include <core/system.h>
#include <core/string.h>
#include <cpu/cpu.h>
#include <mm/mm.h>
#include <boot/multiboot.h>
#include <boot/boot.h>

/* Minimalistic Paging structure for BSP */
#if ARCH_BITS==32
volatile uint32_t _BSP_PD[1024]  __aligned(PAGE_SIZE);
#else
volatile uint64_t _BSP_PD[512]   __aligned(PAGE_SIZE);
volatile uint64_t _BSP_PDPT[512] __aligned(PAGE_SIZE);
volatile uint64_t _BSP_PML4[512] __aligned(PAGE_SIZE);
#endif

#define P   _BV(0)
#define RW  _BV(1)
#define PCD _BV(4)

extern char kernel_end;
char scratch[1024 * 1024] __aligned(PAGE_SIZE); /* 1 MiB scratch area */

static inline void enable_paging(uintptr_t page_directory)
{
    write_cr3(page_directory);
#if ARCH_BITS==32
    uint32_t cr0 = read_cr0();
    write_cr0(cr0 | CR0_PG);
#endif
}

static void switch_to_higher_half(void)
{
    uint32_t i;
    uintptr_t entries;

    /* zero out paging structure */
    memset((void *) _BSP_PD, 0, sizeof(_BSP_PD));

#if ARCH_BITS==64
    memset((void *) _BSP_PDPT, 0, sizeof(_BSP_PDPT));
    memset((void *) _BSP_PML4, 0, sizeof(_BSP_PML4));
#endif

    /* entries count required to map the kernel */
    entries = ((uintptr_t)(&kernel_end) + KERNEL_HEAP_SIZE + TABLE_MASK) / TABLE_SIZE;

#if ARCH_BITS==32
    uint32_t *_BSP_PT = (uint32_t *) scratch;

    /* identity map pages */
    for (i = 0; i < entries * 1024; ++i)
        _BSP_PT[i] = (i * PAGE_SIZE) | P | RW;

    /* map the lower-half */
    for (i = 0; i < entries; ++i)
        _BSP_PD[i] = ((uint32_t) _BSP_PT + i * PAGE_SIZE) | P | RW;

    /* map the upper-half */
    for (i = 0; i < entries; ++i)
        _BSP_PD[768 + i] = ((uint32_t) _BSP_PT + i * PAGE_SIZE) | P | RW;

    /* Enable paging using Bootstrap Processor Page Directory */
    extern void enable_paging(uint32_t);
    enable_paging((uint32_t) _BSP_PD);
#else
    uint64_t *_BSP_PT = (uint64_t *) scratch;

    /* identity map pages */
    for (i = 0; i < entries * 512; ++i)
        _BSP_PT[i] = (i * PAGE_SIZE) | P | RW;

    /* map the lower-half */
    for (i = 0; i < entries; ++i)
        _BSP_PD[i] = ((uint64_t) _BSP_PT + i * PAGE_SIZE) | P | RW;

    _BSP_PDPT[0] = (uint64_t) _BSP_PD   | P | RW;
    _BSP_PML4[0] = (uint64_t) _BSP_PDPT | P | RW;

    /* map the upper-half */
    _BSP_PML4[256] = (uint64_t) _BSP_PDPT | P | RW;

    /* Enable paging using Bootstrap Processor PML4 */
    enable_paging((uint64_t) _BSP_PML4);
#endif
}

void x86_bootstrap()
{
    /* We assume that GrUB loaded a valid GDT */
    /* Then we map the kernel to the higher half */
    switch_to_higher_half();

    /* Now we make SP in the higher half */
#if ARCH_BITS==32
    //asm volatile("add %0, %%esp"::"g"(VMA((uintptr_t) 0)):"esp");
    extern void early_init_fix_stack(uintptr_t);
    early_init_fix_stack(VMA((uintptr_t) 0));
#else
    asm volatile("add %0, %%rsp"::"r"(VMA((uintptr_t) 0)):"rsp");
#endif

    /* Ready to get out of here */
    extern void x86_cpu_init(void);
    x86_cpu_init();

    /* Why would we ever get back here? however we should be precautious */
    for (;;)
        asm volatile ("hlt;");
}


================================================
FILE: kernel/arch/i386/boot/multiboot.S
================================================
/**********************************************************************
 *                      Multiboot support
 *
 *
 *  This file is part of AquilaOS and is released under the terms of
 *  GNU GPLv3 - See LICENSE.
 *
 *  Copyright (C) Mohamed Anwar
 */

#include <config.h>
#define ASM_FILE
#include <boot/multiboot.h>

/*
 *  Multiboot definitions
 */

#if MULTIBOOT_GFX
#define MULTIBOOT_GFX_ENABLE    MULTIBOOT_VIDEO_MODE
#else
#define MULTIBOOT_GFX_ENABLE    0
#endif

#define MULTIBOOT_FLAGS  MULTIBOOT_PAGE_ALIGN | MULTIBOOT_MEMORY_INFO | MULTIBOOT_GFX_ENABLE
#define MULTIBOOT_CHKSUM -(MULTIBOOT_HEADER_MAGIC + MULTIBOOT_FLAGS)

/*
 *  Multiboot lookup header
 */

/* struct multiboot_header */
.align 8
.long MULTIBOOT_HEADER_MAGIC    /* magic */
.long MULTIBOOT_FLAGS           /* flags */
.long MULTIBOOT_CHKSUM          /* checksum */
.long 0                         /* header_addr */
.long 0                         /* heload_addr */
.long 0                         /* heload_end_addr */
.long 0                         /* hebss_end_addr */
.long 0                         /* heentry_addr */

.long 0                         /* mode_type */
.long 1024                      /* mowidth */
.long 768                       /* moheight */
.long 32                        /* modepth */

/*
 * Entry point of the bootloader
 */

.global _start
_start:
    movl %eax, (multiboot_signature)
    movl %ebx, (multiboot_info)

    and  $-16, %esp /* Align stack to 16 byte */

    mov  $0, %ebp

    cli

#if ARCH_BITS==32
    .extern x86_bootstrap
    call x86_bootstrap
#else
    .extern x86_64_bootstrap
    call x86_64_bootstrap
#endif
    jmp .

.global multiboot_signature
.global multiboot_info

multiboot_signature: .long 0
multiboot_info: .long 0

/* vim: ft=gas:
*/


================================================
FILE: kernel/arch/i386/boot/sys.S
================================================
.global early_init_fix_stack
early_init_fix_stack:
    mov 4(%esp), %eax
    add %eax, %esp
    mov $0, %ebp
    ret


================================================
FILE: kernel/arch/i386/boot/x86_64_bootstrap.S
================================================
.code32
.global x86_64_bootstrap
x86_64_bootstrap:

    /* Set up basic identity paging
     * PML4 -> 0x0FF000
     * PDPT -> 0x0FE000
     * PD   -> 0x0FD000
     */

    /* Zero out 0xFE000 -> 0x100000 */
    mov $0xFE000, %edi
    mov $0x2000, %ecx
    xor %eax, %eax
    rep stosb

    /* Setup PDPT */
    mov $0x0FD000, %edi
    mov $0x200, %ecx    /* 512 entries */
    mov $0x83, %eax
    
    .__pdpt:
        movl %eax, 0(%edi)
        add $0x4, %edi
        movl $0, 0(%edi)
        add $0x4, %edi
        add $0x200000, %eax
        dec %ecx
        jnz .__pdpt

    /* Page Directory */
    movl $0xFE000, %edi
    movl $0xFD000 | 3, 0(%edi)

    /* PML4 */
    movl $0xFF000, %edi
    movl $0xFE000 | 3, 0(%edi)

    /* Set PAE and PGE */
    movl $0xA0, %eax
    mov %eax, %cr4

    /* Point CR3 to PML4 */
    movl %edi, %cr3

    /* Set LME */
    mov $0xC0000080, %ecx
    rdmsr
    or $0x100, %eax
    wrmsr

    /* Enable paging and protection */
    mov %cr0, %eax
    or $0x80000001, %eax
    mov %eax, %cr0

    /* Set up basic 64-bit GDT */
    lgdt __x86_64_bootstrap_gdt_p

    ljmp $0x8, $__x86_64_longmode

.align 4
__x86_64_bootstrap_gdt:
    /* NULL segment */
    .quad 0x0000000000000000
    /* XR_CODE, DPL0, L segment */
    .quad 0x00AF9A000000FFFF
    /* WR_DATA, DPL0, L segment */
    .quad 0x00AF92000000FFFF

.align 4
__x86_64_bootstrap_gdt_p:
    .word . - __x86_64_bootstrap_gdt - 1
    .long __x86_64_bootstrap_gdt

.code64
__x86_64_longmode:
    mov $0x10, %ax
    mov %ax, %ds
    mov %ax, %es
    mov %ax, %fs
    mov %ax, %gs
    mov %ax, %ss

    .extern early_init
    call early_init
    
    hlt
    jmp .

/* vim: ft=gas:
 */


================================================
FILE: kernel/arch/i386/cpu/Build.mk
================================================
obj-y += init.o
obj-y += gdt.o
obj-y += idt.o
obj-y += isr.o
#obj-y += smp.o
obj-y += fpu.o
obj-y += cpu.o
obj-y += arith.o
obj-y += trace.o


================================================
FILE: kernel/arch/i386/cpu/Makefile
================================================
include Build.mk

CWD != realpath --relative-to=$(SRCDIR) .

all: builtin.o $(elf)

builtin.o: $(obj-y) $(dirs-y)
	@$(ECHO) "  LD      " $(CWD)/builtin.o;
	@$(LD) $(LDFLAGS) -r $(obj-y) $(patsubst %/,%/builtin.o, $(dirs-y)) -o builtin.o; 

.PHONY: $(dirs-y)
$(dirs-y): $(patsubst %/,%/Makefile, $(dirs-y))
	@$(ECHO) "  MK      " $(CWD)/$@;
	@$(MAKE) -C $@ $(param)

%.o:%.c
	@$(ECHO) "  CC      " $(CWD)/$@;
	@$(CC) $(CFLAGS) -c $< -o $@

%.o:%.S
	@$(ECHO) "  AS      " $(CWD)/$@;
	@$(AS) $(ASFLAGS) -c $< -o $@

.PHONY: clean
clean: param = clean
clean: $(dirs-y)
	@$(ECHO) "  RM      " $(obj-y) $(elf) builtin.o
	@$(RM) $(obj-y) $(elf) builtin.o


================================================
FILE: kernel/arch/i386/cpu/arith.c
================================================
/*
 * https://www.ida.liu.se/~TDIU25/pintos/src/lib/arithmetic.c
 */

#include <stdint.h>

/* Uses x86 DIVL instruction to divide 64-bit N by 32-bit D to
     yield a 32-bit quotient.  Returns the quotient.
     Traps with a divide error (#DE) if the quotient does not fit
     in 32 bits. */
static inline uint32_t divl(uint64_t n, uint32_t d)
{
    uint32_t n1 = n >> 32;
    uint32_t n0 = n;
    uint32_t q, r;

    asm ("divl %4"
             : "=d" (r), "=a" (q)
             : "0" (n1), "1" (n0), "rm" (d));

    return q;
}

/* Returns the number of leading zero bits in X,
     which must be nonzero. */
static int nlz(uint32_t x) 
{
    int n = 0;
    if (x <= 0x0000FFFF) {
        n += 16;
        x <<= 16; 
    }

    if (x <= 0x00FFFFFF) {
        n += 8;
        x <<= 8; 
    }

    if (x <= 0x0FFFFFFF) {
        n += 4;
        x <<= 4;
    }

    if (x <= 0x3FFFFFFF) {
        n += 2;
        x <<= 2; 
    }

    if (x <= 0x7FFFFFFF)
        n++;

    return n;
}

/* Divides unsigned 64-bit N by unsigned 64-bit D and returns the
     quotient. */
static uint64_t udiv64(uint64_t n, uint64_t d)
{
    if ((d >> 32) == 0) {
        /* Proof of correctness:
         * Let n, d, b, n1, and n0 be defined as in this function.
         * Let [x] be the "floor" of x.  Let T = b[n1/d].  Assume d
         * nonzero.  Then:
         *   [n/d] = [n/d] - T + T
         *         = [n/d - T] + T                      by (1) below
         *         = [(b*n1 + n0)/d - T] + T            by definition of n
         *         = [(b*n1 + n0)/d - dT/d] + T
         *         = [(b(n1 - d[n1/d]) + n0)/d] + T
         *         = [(b[n1 % d] + n0)/d] + T,          by definition of %
         * which is the expression calculated below.
         *
         * (1) Note that for any real x, integer i: [x] + i = [x + i].
         *
         * To prevent divl() from trapping, [(b[n1 % d] + n0)/d] must
         * be less than b.    Assume that [n1 % d] and n0 take their
         * respective maximum values of d - 1 and b - 1:
         *   [(b(d - 1) + (b - 1))/d] < b
         *   <=> [(bd - 1)/d] < b
         *   <=> [b - 1/d] < b
         * which is a tautology.
         *
         * Therefore, this code is correct and will not trap.
         */

        uint64_t b = 1ULL << 32;
        uint32_t n1 = n >> 32;
        uint32_t n0 = n; 
        uint32_t d0 = d;

        return divl(b * (n1 % d0) + n0, d0) + b * (n1 / d0); 
    } else {
        /* Based on the algorithm and proof available from
         * http://www.hackersdelight.org/revisions.pdf.
         */
        if (n < d) {
            return 0;
        } else {
            uint32_t d1 = d >> 32;
            int s = nlz(d1);
            uint64_t q = divl(n >> 1, (d << s) >> 32) >> (31 - s);
            return n - (q - 1) * d < d ? q - 1 : q; 
        }
    }
}

/* Divides unsigned 64-bit N by unsigned 64-bit D and returns the
     remainder. */
static uint32_t umod64(uint64_t n, uint64_t d)
{
    return n - d * udiv64(n, d);
}

/* Divides signed 64-bit N by signed 64-bit D and returns the
     quotient. */
static int64_t sdiv64(int64_t n, int64_t d)
{
    uint64_t n_abs = n >= 0 ? (uint64_t) n : -(uint64_t) n;
    uint64_t d_abs = d >= 0 ? (uint64_t) d : -(uint64_t) d;
    uint64_t q_abs = udiv64 (n_abs, d_abs);
    return (n < 0) == (d < 0) ? (int64_t) q_abs : -(int64_t) q_abs;
}

/* Divides signed 64-bit N by signed 64-bit D and returns the
     remainder. */
static int32_t smod64(int64_t n, int64_t d)
{
    return n - d * sdiv64(n, d);
}

/* These are the routines that GCC calls. */

long long __divdi3(long long n, long long d);
long long __moddi3(long long n, long long d);
unsigned long long __udivdi3(unsigned long long n, unsigned long long d);
unsigned long long __umoddi3(unsigned long long n, unsigned long long d);

/* Signed 64-bit division. */
long long __divdi3(long long n, long long d) 
{
    return sdiv64(n, d);
}

/* Signed 64-bit remainder. */
long long __moddi3(long long n, long long d) 
{
    return smod64 (n, d);
}

/* Unsigned 64-bit division. */
unsigned long long __udivdi3(unsigned long long n, unsigned long long d) 
{
    return udiv64 (n, d);
}

/* Unsigned 64-bit remainder. */
unsigned long long __umoddi3(unsigned long long n, unsigned long long d) 
{
    return umod64 (n, d);
}


================================================
FILE: kernel/arch/i386/cpu/cpu.S
================================================
#include <config.h>

.global x86_cpuid_check
x86_cpuid_check:
#if ARCH_BITS==32
    pushf
    pushf
    xorl $1 << 21, (%esp)
    popf
    pushf
    pop %eax
    xorl (%esp), %eax
    andl $1 << 21, %eax
    popf
    ret
#else
    /* TODO */
#endif

/*
 * ISRs -- Interrupt Service Routines
 */

.global __x86_isr_int_num, __x86_isr_err_num
__x86_isr_int_num: .long 0
__x86_isr_err_num: .long 0

.macro ISR_NOERR v
.global __x86_isr\v
__x86_isr\v:
    cli
#if ARCH_BITS==32
    movl $0,  (__x86_isr_err_num)
    movl $\v, (__x86_isr_int_num)
#else
    movl $0,  __x86_isr_err_num(%rip)
    movl $\v, __x86_isr_int_num(%rip)
#endif
    jmp isr_handler
.endm

.macro ISR_ERR v
.global __x86_isr\v
__x86_isr\v:
    cli
#if ARCH_BITS==32
    popl (__x86_isr_err_num)
    movl $\v, (__x86_isr_int_num)
    jmp isr_handler
#else
    push %rbx
    movq 8(%rsp), %rbx
    movl %ebx, __x86_isr_err_num(%rip)
    pop  %rbx
    add  $8, %rsp
    movl $\v, __x86_isr_int_num(%rip)
    jmp isr_handler
#endif
.endm

.macro push_context
#if ARCH_BITS==32
    push %eax
    push %edx
    push %ecx
    push %ebx
    push %ebp
    push %esi
    push %edi
#else
    push %rax
    push %rdx
    push %rcx
    push %rbx
    push %rbp
    push %rsi
    push %rdi
    push %r8
    push %r9
    push %r10
    push %r11
    push %r12
    push %r13
    push %r14
    push %r15
#endif
.endm
    
.macro pop_context
#if ARCH_BITS==32
    pop %edi
    pop %esi
    pop %ebp
    pop %ebx
    pop %ecx
    pop %edx
    pop %eax
#else
    pop %r15
    pop %r14
    pop %r13
    pop %r12
    pop %r11
    pop %r10
    pop %r9
    pop %r8
    pop %rdi
    pop %rsi
    pop %rbp
    pop %rbx
    pop %rcx
    pop %rdx
    pop %rax
#endif
.endm

/* Refer to 
 * - Intel 64 and IA-32 Architectures Software Developer’s Manual
 * - Volume 3: System Programming Guide
 * - Table 6-1. Protected-Mode Exceptions and Interrupts
 */

ISR_NOERR 0
ISR_NOERR 1
ISR_NOERR 2
ISR_NOERR 3
ISR_NOERR 4
ISR_NOERR 5
ISR_NOERR 6
ISR_NOERR 7
ISR_ERR   8
ISR_NOERR 9
ISR_ERR   10
ISR_ERR   11
ISR_ERR   12
ISR_ERR   13
ISR_ERR   14
ISR_NOERR 15
ISR_NOERR 16
ISR_ERR   17
ISR_NOERR 18
ISR_NOERR 19
ISR_NOERR 20
ISR_NOERR 21
ISR_NOERR 22
ISR_NOERR 23
ISR_NOERR 24
ISR_NOERR 25
ISR_NOERR 26
ISR_NOERR 27
ISR_NOERR 28
ISR_NOERR 29
ISR_NOERR 30
ISR_NOERR 31
ISR_NOERR 128

.extern __x86_isr
isr_handler:
#if ARCH_BITS==32
    push_context
    push %esp
    mov $0, %ebp
    call __x86_isr
    pop %eax
    pop_context
    iret
#else
    push_context
    mov %rsp, %rdi
    call __x86_isr
    pop_context
    iretq
#endif

/*
 * IRQs -- external interrupt requists (from PIC)
 */
.macro IRQ n, i
.global __x86_irq\n
__x86_irq\n:
#if ARCH_BITS==32
    cli
    movl $\i, (__x86_isr_int_num)
    jmp irq_stub
#else
    cli
    movl $\i, __x86_isr_int_num(%rip)
    jmp irq_stub
#endif
.endm

IRQ 0, 32
IRQ 1, 33
IRQ 2, 34
IRQ 3, 35
IRQ 4, 36
IRQ 5, 37
IRQ 6, 38
IRQ 7, 39
IRQ 8, 40
IRQ 9, 41
IRQ 10, 42
IRQ 11, 43
IRQ 12, 44
IRQ 13, 45
IRQ 14, 46
IRQ 15, 47


.extern __x86_irq_handler
irq_stub:
#if ARCH_BITS==32
    push_context
    push %esp
    call __x86_irq_handler
    pop %eax
    pop_context
    iret
#else
    push_context
    mov %rsp, %rdi
    call __x86_irq_handler
    pop_context
    iretq
#endif

.global x86_jump_user
x86_jump_user:  /* eax, eip, cs, eflags, esp, ss */
#if ARCH_BITS==32
    pop  %eax   /* Caller return address */
    mov  $0x20 | 0x3, %ax
    movw %ax, %ds
    movw %ax, %es
    movw %ax, %fs
    movw %ax, %gs
    pop  %eax   /* eax for sys_fork return */
    iret
#else
    pop  %rax   /* Caller return address */
    /* set segments */
    mov  $0x20 | 0x3, %ax
    movw %ax, %ds
    movw %ax, %es
    movw %ax, %fs
    movw %ax, %gs
    mov  %rdi, %rax   /* rax for sys_fork return */
    /* push registers */
    pushq %r9    /* ss */
    pushq %r8    /* rsp */
    pushq %rcx   /* rflags */
    pushq %rdx   /* cs */
    pushq %rsi   /* rip */
    iretq
#endif

.global x86_read_ip
x86_read_ip:
#if ARCH_BITS==32
    mov (%esp), %eax
#else
    mov (%rsp), %rax
#endif
    ret

.global x86_goto
x86_goto:
#if ARCH_BITS==32
    pop %ebx    /* Caller return address */
    pop %ebx    /* eip */
    pop %ebp
    pop %esp
    mov $-1, %eax /* Return -1 -> Done switching */
    jmp *%ebx
#else
    pop %rbx        /* Caller return address */
    mov %rdi, %rbx  /* rip */
    mov %rsi, %rbp
    mov %rdx, %rsp
    mov $-1, %rax /* Return -1 -> Done switching */
    jmp *%rbx
#endif


.extern internal_arch_sleep
.global x86_sleep
x86_sleep:
    push_context
    call internal_arch_sleep
    pop_context
    ret

.global x86_fork_return
x86_fork_return:
#if ARCH_BITS==32
    pop_context
    iret
#else
    pop_context
    iretq
#endif

.global return_from_signal
return_from_signal:
    mov 4(%esp), %edi
    mov %edi, %esp    /* Fix stack pointer */
    pop_context
    iret

.align 8
gdt_pointer:
    .word 0
#if ARCH_BITS==32
    .long 0
#else
    .quad 0
#endif

.global x86_lgdt
x86_lgdt:
#if ARCH_BITS==32
    movw 4(%esp), %ax
    movl 8(%esp), %ebx
    movw %ax, (gdt_pointer)
    movl %ebx, (gdt_pointer + 2)
    lgdt (gdt_pointer)
    ljmp $0x8, $1f
#else
    movw %di, gdt_pointer(%rip)
    movq %rsi, (gdt_pointer + 2)(%rip)
    lgdt gdt_pointer(%rip)
#endif
1:
    movl $0x10, %eax
    movl %eax, %ds
    movl %eax, %es
    movl %eax, %fs
    movl %eax, %gs
    movl %eax, %ss
    ret

.global x86_lidt
x86_lidt:
#if ARCH_BITS==32
    movl 4(%esp), %eax
    lidt (%eax)
#else
    lidt (%rdi)
#endif
    ret

.global x86_ltr
x86_ltr:
#if ARCH_BITS==32
    movl 4(%esp), %eax
    ltr %ax
#else
    ltr %di
#endif
    ret

/* vim: ft=gas:
 */


================================================
FILE: kernel/arch/i386/cpu/cpu.h
================================================
#ifndef _CPU_SYS_H
#define _CPU_SYS_H

#include <core/system.h>

void x86_lgdt(uint16_t, uintptr_t);
void x86_lidt(uintptr_t);
void x86_ltr(uintptr_t);

#endif /* ! _CPU_SYS_H */


================================================
FILE: kernel/arch/i386/cpu/fpu.c
================================================
#include <core/system.h>
#include <core/panic.h>
#include <core/assert.h>
#include <core/arch.h>
#include <cpu/cpu.h>
#include <sys/proc.h>
#include <sys/sched.h>

MALLOC_DEFINE(M_X86_FPU, "x86-fpu", "x86 FPU context");

static char fpu_context[512] __aligned(16);
struct thread *last_fpu_thread = NULL;

void x86_fpu_enable(void)
{
    asm volatile("clts");
    write_cr0((read_cr0() & ~CR0_EM) | CR0_MP);
}

void x86_fpu_disable(void)
{
    write_cr0(read_cr0() | CR0_EM);
}

void x86_fpu_init(void)
{
    assert_alignof(fpu_context, 16);
    asm volatile("fninit");
}

static inline void fpu_save(void)
{
    asm volatile("fxsave (%0)"::"r"(fpu_context):"memory");
}

static inline void fpu_restore(void)
{
    asm volatile("fxrstor (%0)"::"r"(fpu_context):"memory");
}

void x86_fpu_trap(void)
{
    x86_fpu_enable();

    struct x86_thread *arch = curthread->arch;

    if (!last_fpu_thread) {   /* Initialize */
        x86_fpu_init();
        arch->fpu_enabled = 1;
    } else if (curthread != last_fpu_thread) {
        struct x86_thread *_arch = last_fpu_thread->arch;

        if (!_arch->fpu_context) {  /* Lazy allocate */
            _arch->fpu_context = kmalloc(512, &M_X86_FPU, 0);

            if (!_arch->fpu_context) {
                /* TODO */
            }
        }

        fpu_save();
        memcpy(_arch->fpu_context, fpu_context, 512);

        if (arch->fpu_enabled) {    /* Restore context */
            memcpy(fpu_context, arch->fpu_context, 512);
            fpu_restore();
        } else {
            x86_fpu_init();
            arch->fpu_enabled = 1;
        }
    }

    last_fpu_thread = curthread;
}


================================================
FILE: kernel/arch/i386/cpu/gdt.c
================================================
/**********************************************************************
 *              Global Descriptor Table (GDT)
 *
 *
 *  This file is part of Aquila OS and is released under the terms of
 *  GNU GPLv3 - See LICENSE.
 *
 *  Copyright (C) Mohamed Anwar
 */


#include <core/system.h>
#include <core/panic.h>
#include <core/assert.h>
#include <core/string.h>

#include "cpu.h"

#if ARCH_BITS==32
static struct {
    uint32_t link;
    uint32_t sp;
    uint32_t ss;
    uint32_t _[23]; /* To know the actuall fields, consult Intel Manuals */
} __packed tss_entry __aligned(8);
#else
static struct {
    uint32_t _;
    uint64_t sp;
    uint32_t __[23]; /* To know the actuall fields, consult Intel Manuals */
} __packed tss_entry __aligned(8);
#endif

#define TSS_BASE    ((uintptr_t) &tss_entry)
#define TSS_LIMIT   (sizeof(tss_entry) - 1)

#define RW_DATA 0x2
#define XR_CODE 0xA
#define TSS_AVL 0x9

#define BASE  0
#define LIMIT -1

#define DPL0 0
#define DPL3 3

#if ARCH_BITS==32
#define L   0
#define D   1
#else
#define L   1
#define D   0
#endif

static struct gdt_entry {
    uint32_t limit_lo : 16; /* Segment Limit 15:00 */
    uint32_t base_lo  : 16; /* Base Address 15:00 */

    uint32_t base_mid : 8;  /* Base Address 23:16 */
    uint32_t type     : 4;  /* Segment Type */
    uint32_t s        : 1;  /* Descriptor type (0=system, 1=code) */
    uint32_t dpl      : 2;  /* Descriptor Privellage Level */
    uint32_t p        : 1;  /* Segment present */

    uint32_t limit_hi : 4;  /* Segment Limit 19:16 */
    uint32_t avl      : 1;  /* Avilable for use by system software */
    uint32_t l        : 1;  /* Long mode segment (64-bit only) */
    uint32_t db       : 1;  /* Default operation size / upper Bound */
    uint32_t g        : 1;  /* Granularity */
    uint32_t base_hi  : 8;  /* Base Address 31:24 */
} __aligned(8) gdt[256] = {
    /* Null Segment */
    {0},

    /* Code Segment - Kernel */
    {LIMIT, BASE, BASE, XR_CODE, 1, DPL0, 1, LIMIT, 0, L, D, 1, BASE},

    /* Data Segment - Kernel */
    {LIMIT, BASE, BASE, RW_DATA, 1, DPL0, 1, LIMIT, 0, L, D, 1, BASE},

    /* Code Segment - User */
    {LIMIT, BASE, BASE, XR_CODE, 1, DPL3, 1, LIMIT, 0, L, D, 1, BASE},

    /* Data Segment - User */
    {LIMIT, BASE, BASE, RW_DATA, 1, DPL3, 1, LIMIT, 0, L, D, 1, BASE},
};

void x86_gdt_setup(void)
{
    assert_sizeof(gdt, 8*256);
    assert_alignof(&gdt, 8);
    x86_lgdt(sizeof(gdt) - 1, (uintptr_t) &gdt);
}

void x86_tss_setup(uintptr_t sp)
{
    assert_sizeof(tss_entry, 104);
    assert_alignof(&tss_entry, 8);

#if ARCH_BITS==32
    tss_entry.ss = 0x10;
#endif
    tss_entry.sp = sp;

    /* TSS Segment */
#if 0
    gdt[5] = (struct gdt_entry){TSS_LIMIT & 0xFFFF, TSS_BASE & 0xFFFF,
        (TSS_BASE >> 16) & 0xFF, TSS_AVL, 0, DPL3, 1,
        (TSS_LIMIT >> 16) & 0xF, 0, 0, 0, 0, (TSS_BASE >> 24 & 0xFF)};
#endif
    gdt[5].limit_lo = TSS_LIMIT & 0xFFFF;
    gdt[5].base_lo  = TSS_BASE & 0xFFFF;
    gdt[5].base_mid = (TSS_BASE >> 16) & 0xFF;
    gdt[5].type     = TSS_AVL;
    gdt[5].s        = 0;
    gdt[5].dpl      = DPL3;
    gdt[5].p        = 1;
    gdt[5].limit_hi = (TSS_LIMIT >> 16) & 0xF;
    gdt[5].avl      = 0;
    gdt[5].l        = 0;
    gdt[5].db       = 0;
    gdt[5].g        = 0;
    gdt[5].base_hi  = (TSS_BASE >> 24 & 0xFF);

#if ARCH_BITS==64
    uint32_t *base_high = (uint32_t *) &gdt[6];
    *base_high = TSS_BASE >> 32;
#endif

    x86_ltr(0x28 | DPL3);
}

void x86_kernel_stack_set(uintptr_t sp)
{
    tss_entry.sp = sp;
}


================================================
FILE: kernel/arch/i386/cpu/idt.c
================================================
/**********************************************************************
 *              Interrupt Descriptor Table (IDT)
 *
 *
 *  This file is part of Aquila OS and is released under the terms of
 *  GNU GPLv3 - See LICENSE.
 *
 *  Copyright (C) Mohamed Anwar 
 */

#include <core/system.h>
#include "cpu.h"

#if __pragma_pack
#pragma pack(1)
#endif
static struct idt_entry {
    uint32_t offset_lo : 16;    /* offset 0:15 */
    uint32_t selector  : 16;    /* Code segment selector */
    uint32_t _unused   : 8;     /* Unused, should be set to 0 */
    uint32_t flags     : 5;     /* Always set to 01110 */
    uint32_t dpl       : 2;     /* Descriptor privellage level */
    uint32_t p         : 1;     /* Present */
    uint16_t offset_hi : 16;    /* offset 16:31 */
#if ARCH_BITS==64
    uint32_t offset_ext: 32;    /* offset 32:63 */
    uint32_t           : 32;    /* reserved */
#endif
} __packed idt[256];

struct idt_ptr {
    uint16_t limit;
    uintptr_t base;
} __packed idt_pointer;
#if __pragma_pack
#pragma pack()
#endif

#define DPL0 0
#define DPL3 3

/* Sets Interrupt gates in Kernel Code Segment */
void x86_idt_gate_set(uint32_t id, uintptr_t offset)
{
    idt[id].offset_lo  = (offset >> 0x00) & 0xFFFF;
    idt[id].offset_hi  = (offset >> 0x10) & 0xFFFF;
#if ARCH_BITS==64
    idt[id].offset_ext = (offset >> 0x20) & 0xFFFFFFFF;
#endif

    idt[id].selector   = 0x8;
    idt[id].p          = 1;
    idt[id].dpl        = DPL0;
    idt[id].flags      = 0x0E;
}

/* Sets Interrupt gates in User Code Segment */
void x86_idt_gate_user_set(uint32_t id, uintptr_t offset)
{
    idt[id].offset_lo  = (offset >> 0x00) & 0xFFFF;
    idt[id].offset_hi  = (offset >> 0x10) & 0xFFFF;
#if ARCH_BITS==64
    idt[id].offset_ext = (offset >> 0x20) & 0xFFFFFFFF;
#endif

    idt[id].selector   = 0x8;
    idt[id].p          = 1;
    idt[id].dpl        = DPL3;
    idt[id].flags      = 0x0E;
}

void x86_idt_setup()
{
    idt_pointer.limit = sizeof(idt) - 1;
    idt_pointer.base  = (uintptr_t) &idt;
    x86_lidt((uintptr_t) &idt_pointer);
}


================================================
FILE: kernel/arch/i386/cpu/init.c
================================================
/**********************************************************************
 *                  Initalization of the kernel
 *           (Setup CPU structures and memory managment)
 *
 *
 *  This file is part of AquilaOS and is released under the terms of
 *  GNU GPLv3 - See LICENSE.
 *
 *  Copyright (C) Mohamed Anwar
 */

#include <boot/boot.h>
#include <boot/multiboot.h>
#include <console/earlycon.h>
#include <core/kargs.h>
#include <core/platform.h>
#include <core/printk.h>
#include <core/string.h>
#include <cpu/cpu.h>
#include <ds/bitmap.h>
#include <mm/mm.h>
#include <mm/vm.h>
#include <video/vbe.h>

struct x86_cpu cpus[32];
int cpus_count;
struct boot *__kboot;

void x86_cpu_init(void)
{
    earlycon_init();
    printk("x86: Welcome to AquilaOS!\n");

    printk("x86: installing GDT\n");
    x86_gdt_setup();
    x86_tss_setup(VMA(0x100000ULL));

    printk("x86: installing IDT\n");
    x86_idt_setup();

    printk("x86: installing ISRs\n");
    x86_isr_setup();

    printk("x86: processing multiboot info block at %p\n", (uintptr_t) multiboot_info);
    struct boot *boot = process_multiboot_info((multiboot_info_t *)(uintptr_t) multiboot_info);
    __kboot = boot;

    mm_setup(boot);
    kvmem_setup();

    /* parse command line */
    kargs_parse(boot->cmdline);

    /* reinit early console */
    earlycon_reinit();

    platform_init();

    extern void kmain(struct boot *);
    kmain(boot);
}


================================================
FILE: kernel/arch/i386/cpu/isr.c
================================================
/**********************************************************************
 *              Interrupt Service Routines (ISRs)
 *
 *
 *  This file is part of AquilaOS and is released under the terms of
 *  GNU GPLv3 - See LICENSE.
 *
 *  Copyright (C) Mohamed Anwar
 */

#include <core/system.h>
#include <core/arch.h>

#include <core/panic.h>
#include <core/string.h>
#include <cpu/cpu.h>
#include <sys/sched.h>
#include <mm/mm.h>

extern void __x86_isr0 (void);
extern void __x86_isr1 (void);
extern void __x86_isr2 (void);
extern void __x86_isr3 (void);
extern void __x86_isr4 (void);
extern void __x86_isr5 (void);
extern void __x86_isr6 (void);
extern void __x86_isr7 (void);
extern void __x86_isr8 (void);
extern void __x86_isr9 (void);
extern void __x86_isr10(void);
extern void __x86_isr11(void);
extern void __x86_isr12(void);
extern void __x86_isr13(void);
extern void __x86_isr14(void);
extern void __x86_isr15(void);
extern void __x86_isr16(void);
extern void __x86_isr17(void);
extern void __x86_isr18(void);
extern void __x86_isr19(void);
extern void __x86_isr20(void);
extern void __x86_isr21(void);
extern void __x86_isr22(void);
extern void __x86_isr23(void);
extern void __x86_isr24(void);
extern void __x86_isr25(void);
extern void __x86_isr26(void);
extern void __x86_isr27(void);
extern void __x86_isr28(void);
extern void __x86_isr29(void);
extern void __x86_isr30(void);
extern void __x86_isr31(void);
extern void __x86_isr128(void);

/* Refer to 
 * - Intel 64 and IA-32 Architectures Software Developer’s Manual
 * - Volume 3: System Programming Guide
 * - Table 6-1. Protected-Mode Exceptions and Interrupts
 */

static const char *int_msg[32] = {
    /* 0x00 */ "#DE: Divide Error",
    /* 0x01 */ "#DB: Debug Exception",
    /* 0x02 */ "NMI Interrupt",
    /* 0x03 */ "#BP: Breakpoint",
    /* 0x04 */ "#OF: Overflow",
    /* 0x05 */ "#BR: BOUND Range Exceeded",
    /* 0x06 */ "#UD: Invalid Opcode (Undefined Opcode)",
    /* 0x07 */ "#NM: Device Not Available (No Math Coprocessor)",
    /* 0x08 */ "#DF: Double Fault",
    /* 0x09 */ "Coprocessor Segment Overrun (reserved)",
    /* 0x0a */ "#TS: Invalid TSS",
    /* 0x0b */ "#NP: Segment Not Present",
    /* 0x0C */ "#SS: Stack-Segment Fault",
    /* 0x0D */ "#GP: General Protection",
    /* 0x0E */ "#PF: Page Fault",
    /* 0x0F */ "Reserved",
    /* 0x10 */ "#MF: x87 FPU Floating-Point Error (Math Fault)",
    /* 0x11 */ "#AC: Alignment Check",
    /* 0x12 */ "#MC: Machine Check",
    /* 0x13 */ "#XM: SIMD Floating-Point Exception",
    /* 0x14 */ "#VE: Virtualization Exception",
    /* 0x15 */ "Reserved",
    /* 0x16 */ "Reserved",
    /* 0x17 */ "Reserved",
    /* 0x18 */ "Reserved",
    /* 0x19 */ "Reserved",
    /* 0x1A */ "Reserved",
    /* 0x1B */ "Reserved",
    /* 0x1C */ "Reserved",
    /* 0x1D */ "Reserved",
    /* 0x1E */ "Reserved",
    /* 0x1F */ "Reserved"
};

void __x86_isr(struct x86_regs *regs)
{
    extern uint32_t __x86_isr_int_num;
    extern uint32_t __x86_isr_err_num;

    if (__x86_isr_int_num == 0xE && curthread) { /* Page Fault */
        struct x86_thread *arch = curthread->arch;
        //arch->regs = regs;

#if ARCH_BITS==32
        if (regs->eip == 0x0FFF) {  /* Signal return */
#else
        if (regs->rip == 0x0FFF) {  /* Signal return */
#endif
            /* Fix kstack and regs pointers*/
            arch->regs = (struct x86_regs *) arch->kstack;
            arch->kstack += sizeof(struct x86_regs); 
            x86_kernel_stack_set(arch->kstack);

            extern void return_from_signal(uintptr_t) __attribute__((noreturn));
            return_from_signal((uintptr_t) arch->regs);
        }

#if 0
        const char *name = curthread->owner->name;
        if (name && !strcmp(name, "/bin/fbterm")) {
            x86_dump_registers(regs);
            printk("page = %p\n", read_cr2());
            for (;;);
        }
#endif

        //x86_dump_registers(regs);
        uintptr_t addr = read_cr2();

        arch_mm_page_fault(addr, __x86_isr_err_num);
        return;
    }

    if (__x86_isr_int_num == 0x07) {  /* FPU Trap */
        x86_fpu_trap();
        return;
    }
    
    if (__x86_isr_int_num == 0x80) {  /* syscall */
        struct x86_thread *arch = curthread->arch;
        arch->regs = regs;
        //asm volatile ("sti");
        arch_syscall(regs);
        return;
    }


    if (__x86_isr_int_num < 32) {
        const char *msg = int_msg[__x86_isr_int_num];
        printk("Recieved interrupt %d [err=%d]: %s\n", __x86_isr_int_num, __x86_isr_err_num, msg);

        if (__x86_isr_int_num == 0x0E) { /* Page Fault */
            printk("CR2 = %p\n", read_cr2());
        }
        x86_dump_registers(regs);
        panic("Kernel Exception");
    } else {
        printk("Unhandled interrupt %d\n", __x86_isr_int_num);
        panic("Kernel Exception");
    }
}

void x86_isr_setup(void)
{   
    x86_idt_gate_set(0x00, (uintptr_t) __x86_isr0);
    x86_idt_gate_set(0x01, (uintptr_t) __x86_isr1);
    x86_idt_gate_set(0x02, (uintptr_t) __x86_isr2);
    x86_idt_gate_set(0x03, (uintptr_t) __x86_isr3);
    x86_idt_gate_set(0x04, (uintptr_t) __x86_isr4);
    x86_idt_gate_set(0x05, (uintptr_t) __x86_isr5);
    x86_idt_gate_set(0x06, (uintptr_t) __x86_isr6);
    x86_idt_gate_set(0x07, (uintptr_t) __x86_isr7);
    x86_idt_gate_set(0x08, (uintptr_t) __x86_isr8);
    x86_idt_gate_set(0x09, (uintptr_t) __x86_isr9);
    x86_idt_gate_set(0x0A, (uintptr_t) __x86_isr10);
    x86_idt_gate_set(0x0B, (uintptr_t) __x86_isr11);
    x86_idt_gate_set(0x0C, (uintptr_t) __x86_isr12);
    x86_idt_gate_set(0x0D, (uintptr_t) __x86_isr13);
    x86_idt_gate_set(0x0E, (uintptr_t) __x86_isr14);
    x86_idt_gate_set(0x0F, (uintptr_t) __x86_isr15);
    x86_idt_gate_set(0x10, (uintptr_t) __x86_isr16);
    x86_idt_gate_set(0x11, (uintptr_t) __x86_isr17);
    x86_idt_gate_set(0x12, (uintptr_t) __x86_isr18);
    x86_idt_gate_set(0x13, (uintptr_t) __x86_isr19);
    x86_idt_gate_set(0x14, (uintptr_t) __x86_isr20);
    x86_idt_gate_set(0x15, (uintptr_t) __x86_isr21);
    x86_idt_gate_set(0x16, (uintptr_t) __x86_isr22);
    x86_idt_gate_set(0x17, (uintptr_t) __x86_isr23);
    x86_idt_gate_set(0x18, (uintptr_t) __x86_isr24);
    x86_idt_gate_set(0x19, (uintptr_t) __x86_isr25);
    x86_idt_gate_set(0x1A, (uintptr_t) __x86_isr26);
    x86_idt_gate_set(0x1B, (uintptr_t) __x86_isr27);
    x86_idt_gate_set(0x1C, (uintptr_t) __x86_isr28);
    x86_idt_gate_set(0x1D, (uintptr_t) __x86_isr29);
    x86_idt_gate_set(0x1E, (uintptr_t) __x86_isr30);
    x86_idt_gate_set(0x1F, (uintptr_t) __x86_isr31);
    x86_idt_gate_user_set(0x80, (uintptr_t) __x86_isr128);
}


================================================
FILE: kernel/arch/i386/cpu/smp.S
================================================
.code16

.global trampoline
trampoline:
    movw $0x1400, %ax
    movw %ax, %ds
    lgdt %ds:(0x00)
    movl %cr0, %eax
    orl $1, %eax
    movl %eax, %cr0
    ljmp $0x8,$pmode_trampoline - trampoline

.code32


.extern gdt_pointer
.extern x86_ap_init
.global pmode_trampoline
pmode_trampoline:
    movw $0x10, %ax
    movw %ax, %ds
    movw %ax, %ss
    movw %ax, %es
    incl (ap_done)
    movl $0x8000, %esp
    lgdtl (gdt_pointer)
    //ljmp $0x8,$x86_ap_init

.global trampoline_end
trampoline_end:

.global ap_done
ap_done: .long 0


================================================
FILE: kernel/arch/i386/cpu/trace.c
================================================
#include <core/system.h>
#include <core/printk.h>
#include <boot/boot.h>

struct stack_frame {
    struct stack_frame *bp;
    uintptr_t ip;
};

extern struct boot *__kboot;

int __printing_trace = 0;

void arch_stack_trace()
{
#if 1
    __printing_trace = 1;

    struct stack_frame *stk = NULL;

    asm volatile ("movl %%ebp, %0":"=r"(stk));

    printk("stack trace:\n");

    const char *strs = (const char *) __kboot->strtab->sh_addr;

    for (int frame = 0; stk && frame < 20; ++frame) {

        /* find symbol */
        struct elf32_sym *sym = (struct elf32_sym *) __kboot->symtab->sh_addr;

        int found = 0;

        for (size_t i = 0; i < __kboot->symnum; ++i) {
            if (ELF32_ST_TYPE(sym->st_info) == STT_FUNC) {
                if (stk->ip > sym->st_value && stk->ip < sym->st_value + sym->st_size) {
                    found = 1;
                    break;
                }
            }
            ++sym;
        }

        if (found) {
            off_t off = stk->ip - sym->st_value;
            printk("  [%p] %s+0x%x\n", stk->ip, strs + sym->st_name, off);
        } else {
            printk("  [%p]\n", stk->ip);
        }

        stk = stk->bp;
    }
#endif
}


================================================
FILE: kernel/arch/i386/earlycon/Build.mk
================================================
obj-y += uart.o
obj-y += vga.o
obj-y += earlycon.o
obj-y += fb.o


================================================
FILE: kernel/arch/i386/earlycon/Makefile
================================================
include Build.mk

CWD != realpath --relative-to=$(SRCDIR) .

all: builtin.o $(elf)

builtin.o: $(obj-y) $(dirs-y)
	@$(ECHO) "  LD      " $(CWD)/builtin.o;
	@$(LD) $(LDFLAGS) -r $(obj-y) $(patsubst %/,%/builtin.o, $(dirs-y)) -o builtin.o; 

.PHONY: $(dirs-y)
$(dirs-y): $(patsubst %/,%/Makefile, $(dirs-y))
	@$(ECHO) "  MK      " $(CWD)/$@;
	@$(MAKE) -C $@ $(param)

%.o:%.c
	@$(ECHO) "  CC      " $(CWD)/$@;
	@$(CC) $(CFLAGS) -c $< -o $@

%.o:%.S
	@$(ECHO) "  AS      " $(CWD)/$@;
	@$(AS) $(ASFLAGS) -c $< -o $@

.PHONY: clean
clean: param = clean
clean: $(dirs-y)
	@$(ECHO) "  RM      " $(obj-y) $(elf) builtin.o
	@$(RM) $(obj-y) $(elf) builtin.o


================================================
FILE: kernel/arch/i386/earlycon/earlycon.c
================================================
#include <core/kargs.h>
#include <core/string.h>
#include <console/earlycon.h>

static struct earlycon *earlycon;

extern struct earlycon earlycon_uart;
extern struct earlycon earlycon_vga;
extern struct earlycon earlycon_fb;

int earlycon_puts(char *s)
{
    return earlycon->puts(s);
}

int earlycon_putc(char c)
{
    return earlycon->putc(c);
}

void earlycon_init()
{
    earlycon = &earlycon_uart;
    earlycon->init();
}

void earlycon_reinit()
{
    const char *arg_earlycon;
    earlycon = &earlycon_fb; /* default */

    if (!kargs_get("earlycon", &arg_earlycon)) {
        if (!strcmp(arg_earlycon, "ttyS0"))
            earlycon = &earlycon_uart;
        else if (!strcmp(arg_earlycon, "vga"))
            earlycon = &earlycon_vga;
        else if (!strcmp(arg_earlycon, "fb"))
            earlycon = &earlycon_fb;
    }

    earlycon->init();
}


================================================
FILE: kernel/arch/i386/earlycon/fb.c
================================================
#include <core/system.h>
#include <core/string.h>
#include <console/earlycon.h>
#include <cpu/io.h>
#include <mm/vm.h>

#include "font.h"

static uintptr_t fb_paddr, fb_init = 0;
static uint32_t fb_xres, fb_yres, fb_depth,
                fb_scanline, fb_row = 0, fb_col = 0,
                fb_rows = 25, fb_cols = 80, fb_size;

static struct vm_entry fb_vmr = {
    .base = 0xE8000000,
};

static char *vmem   = (char *) 0xE8000000;
static char *cursor = (char *) 0xE8000000;

void earlycon_fb_register(uintptr_t paddr, uint32_t scanline, uint32_t yres, uint32_t xres, uint32_t depth)
{
    //printk("earlycon_fb_register(paddr=%p, scanline=%d, yres=%d, xres=%d, depth=%d)\n",
    //        paddr, scanline, yres, xres, depth);
    fb_paddr    = paddr;
    fb_scanline = scanline;
    fb_yres     = yres;
    fb_xres     = xres;
    fb_depth    = depth;
    fb_size     = yres * scanline * depth / 8;
}

static void earlycon_fb_scroll(int n)
{
    size_t size = n * 16 * fb_scanline;
    memcpy(vmem, vmem + size, fb_size - size);
    memset(vmem + fb_size - size, 0, size);
}

static void fb_putc(int row, int col, char c)
{
    cursor = vmem + row * 16 * fb_scanline + col * 8 * fb_depth / 8;

    char *base = cursor;

    for (int i = 0; i < 16; ++i) {
        for (int j = 0; j < 8; ++j) {
            char b = 0;

            if (vga_font[(unsigned) c * 16 + i] & (1 << (7 - j)))
                b = 0xA0;

            cursor[0] = b;
            cursor[1] = b;
            cursor[2] = b;
            cursor[3] = b;

            cursor += 4;
        }

        cursor += fb_scanline - 8 * 4;
    }
}

static int earlycon_fb_putc(char c)
{
    if (!fb_init)
        return -1;

    if ((unsigned) c < 128) {
        if (c == '\n') {
            fb_col = 0;
            fb_row++;

            if (fb_row >= fb_rows) {
                earlycon_fb_scroll(1);
                fb_row = fb_rows - 1;
            }
            return 1;
        }

        fb_putc(fb_row, fb_col, c);
        ++fb_col;

        if (fb_col >= fb_cols) {
            fb_col = 0;
            fb_row++;

            if (fb_row >= fb_rows) {
                earlycon_fb_scroll(1);
                fb_row = fb_rows - 1;
            }
        }

        return 1;
    }

    return 0;
}

static int earlycon_fb_puts(char *s)
{
    while (*s)
        earlycon_fb_putc(*s++);

    return 0;
}

static void earlycon_fb_init()
{
    fb_vmr.paddr = fb_paddr;
    fb_vmr.size  = fb_size;
    fb_vmr.flags = VM_KRW | VM_NOCACHE;

    vm_map(&kvm_space, &fb_vmr);
    fb_init = 1;

    fb_cols = fb_xres / 8;
    fb_rows = fb_yres / 16;
}

struct earlycon earlycon_fb = {
    .init = earlycon_fb_init,
    .putc = earlycon_fb_putc,
    .puts = earlycon_fb_puts,
};


================================================
FILE: kernel/arch/i386/earlycon/font.h
================================================
/* from linux/drivers/video/font-8x16.c */

/**********************************************/
/*                                            */
/*       Font file generated by cpi2fnt       */
/*                                            */
/**********************************************/

unsigned char vga_font[] = {
	/* 0 0x00 '^@' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 1 0x01 '^A' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x7e, /* 01111110 */
	0x81, /* 10000001 */
	0xa5, /* 10100101 */
	0x81, /* 10000001 */
	0x81, /* 10000001 */
	0xbd, /* 10111101 */
	0x99, /* 10011001 */
	0x81, /* 10000001 */
	0x81, /* 10000001 */
	0x7e, /* 01111110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 2 0x02 '^B' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x7e, /* 01111110 */
	0xff, /* 11111111 */
	0xdb, /* 11011011 */
	0xff, /* 11111111 */
	0xff, /* 11111111 */
	0xc3, /* 11000011 */
	0xe7, /* 11100111 */
	0xff, /* 11111111 */
	0xff, /* 11111111 */
	0x7e, /* 01111110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 3 0x03 '^C' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x6c, /* 01101100 */
	0xfe, /* 11111110 */
	0xfe, /* 11111110 */
	0xfe, /* 11111110 */
	0xfe, /* 11111110 */
	0x7c, /* 01111100 */
	0x38, /* 00111000 */
	0x10, /* 00010000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 4 0x04 '^D' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x10, /* 00010000 */
	0x38, /* 00111000 */
	0x7c, /* 01111100 */
	0xfe, /* 11111110 */
	0x7c, /* 01111100 */
	0x38, /* 00111000 */
	0x10, /* 00010000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 5 0x05 '^E' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x18, /* 00011000 */
	0x3c, /* 00111100 */
	0x3c, /* 00111100 */
	0xe7, /* 11100111 */
	0xe7, /* 11100111 */
	0xe7, /* 11100111 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x3c, /* 00111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 6 0x06 '^F' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x18, /* 00011000 */
	0x3c, /* 00111100 */
	0x7e, /* 01111110 */
	0xff, /* 11111111 */
	0xff, /* 11111111 */
	0x7e, /* 01111110 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x3c, /* 00111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 7 0x07 '^G' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x18, /* 00011000 */
	0x3c, /* 00111100 */
	0x3c, /* 00111100 */
	0x18, /* 00011000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 8 0x08 '^H' */
	0xff, /* 11111111 */
	0xff, /* 11111111 */
	0xff, /* 11111111 */
	0xff, /* 11111111 */
	0xff, /* 11111111 */
	0xff, /* 11111111 */
	0xe7, /* 11100111 */
	0xc3, /* 11000011 */
	0xc3, /* 11000011 */
	0xe7, /* 11100111 */
	0xff, /* 11111111 */
	0xff, /* 11111111 */
	0xff, /* 11111111 */
	0xff, /* 11111111 */
	0xff, /* 11111111 */
	0xff, /* 11111111 */

	/* 9 0x09 '^I' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x3c, /* 00111100 */
	0x66, /* 01100110 */
	0x42, /* 01000010 */
	0x42, /* 01000010 */
	0x66, /* 01100110 */
	0x3c, /* 00111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 10 0x0a '^J' */
	0xff, /* 11111111 */
	0xff, /* 11111111 */
	0xff, /* 11111111 */
	0xff, /* 11111111 */
	0xff, /* 11111111 */
	0xc3, /* 11000011 */
	0x99, /* 10011001 */
	0xbd, /* 10111101 */
	0xbd, /* 10111101 */
	0x99, /* 10011001 */
	0xc3, /* 11000011 */
	0xff, /* 11111111 */
	0xff, /* 11111111 */
	0xff, /* 11111111 */
	0xff, /* 11111111 */
	0xff, /* 11111111 */

	/* 11 0x0b '^K' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x1e, /* 00011110 */
	0x0e, /* 00001110 */
	0x1a, /* 00011010 */
	0x32, /* 00110010 */
	0x78, /* 01111000 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0x78, /* 01111000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 12 0x0c '^L' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x3c, /* 00111100 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x3c, /* 00111100 */
	0x18, /* 00011000 */
	0x7e, /* 01111110 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 13 0x0d '^M' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x3f, /* 00111111 */
	0x33, /* 00110011 */
	0x3f, /* 00111111 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x70, /* 01110000 */
	0xf0, /* 11110000 */
	0xe0, /* 11100000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 14 0x0e '^N' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x7f, /* 01111111 */
	0x63, /* 01100011 */
	0x7f, /* 01111111 */
	0x63, /* 01100011 */
	0x63, /* 01100011 */
	0x63, /* 01100011 */
	0x63, /* 01100011 */
	0x67, /* 01100111 */
	0xe7, /* 11100111 */
	0xe6, /* 11100110 */
	0xc0, /* 11000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 15 0x0f '^O' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0xdb, /* 11011011 */
	0x3c, /* 00111100 */
	0xe7, /* 11100111 */
	0x3c, /* 00111100 */
	0xdb, /* 11011011 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 16 0x10 '^P' */
	0x00, /* 00000000 */
	0x80, /* 10000000 */
	0xc0, /* 11000000 */
	0xe0, /* 11100000 */
	0xf0, /* 11110000 */
	0xf8, /* 11111000 */
	0xfe, /* 11111110 */
	0xf8, /* 11111000 */
	0xf0, /* 11110000 */
	0xe0, /* 11100000 */
	0xc0, /* 11000000 */
	0x80, /* 10000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 17 0x11 '^Q' */
	0x00, /* 00000000 */
	0x02, /* 00000010 */
	0x06, /* 00000110 */
	0x0e, /* 00001110 */
	0x1e, /* 00011110 */
	0x3e, /* 00111110 */
	0xfe, /* 11111110 */
	0x3e, /* 00111110 */
	0x1e, /* 00011110 */
	0x0e, /* 00001110 */
	0x06, /* 00000110 */
	0x02, /* 00000010 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 18 0x12 '^R' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x18, /* 00011000 */
	0x3c, /* 00111100 */
	0x7e, /* 01111110 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x7e, /* 01111110 */
	0x3c, /* 00111100 */
	0x18, /* 00011000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 19 0x13 '^S' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x00, /* 00000000 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 20 0x14 '^T' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x7f, /* 01111111 */
	0xdb, /* 11011011 */
	0xdb, /* 11011011 */
	0xdb, /* 11011011 */
	0x7b, /* 01111011 */
	0x1b, /* 00011011 */
	0x1b, /* 00011011 */
	0x1b, /* 00011011 */
	0x1b, /* 00011011 */
	0x1b, /* 00011011 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 21 0x15 '^U' */
	0x00, /* 00000000 */
	0x7c, /* 01111100 */
	0xc6, /* 11000110 */
	0x60, /* 01100000 */
	0x38, /* 00111000 */
	0x6c, /* 01101100 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0x6c, /* 01101100 */
	0x38, /* 00111000 */
	0x0c, /* 00001100 */
	0xc6, /* 11000110 */
	0x7c, /* 01111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 22 0x16 '^V' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xfe, /* 11111110 */
	0xfe, /* 11111110 */
	0xfe, /* 11111110 */
	0xfe, /* 11111110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 23 0x17 '^W' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x18, /* 00011000 */
	0x3c, /* 00111100 */
	0x7e, /* 01111110 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x7e, /* 01111110 */
	0x3c, /* 00111100 */
	0x18, /* 00011000 */
	0x7e, /* 01111110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 24 0x18 '^X' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x18, /* 00011000 */
	0x3c, /* 00111100 */
	0x7e, /* 01111110 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 25 0x19 '^Y' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x7e, /* 01111110 */
	0x3c, /* 00111100 */
	0x18, /* 00011000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 26 0x1a '^Z' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x18, /* 00011000 */
	0x0c, /* 00001100 */
	0xfe, /* 11111110 */
	0x0c, /* 00001100 */
	0x18, /* 00011000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 27 0x1b '^[' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x30, /* 00110000 */
	0x60, /* 01100000 */
	0xfe, /* 11111110 */
	0x60, /* 01100000 */
	0x30, /* 00110000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 28 0x1c '^\' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xc0, /* 11000000 */
	0xc0, /* 11000000 */
	0xc0, /* 11000000 */
	0xfe, /* 11111110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 29 0x1d '^]' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x28, /* 00101000 */
	0x6c, /* 01101100 */
	0xfe, /* 11111110 */
	0x6c, /* 01101100 */
	0x28, /* 00101000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 30 0x1e '^^' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x10, /* 00010000 */
	0x38, /* 00111000 */
	0x38, /* 00111000 */
	0x7c, /* 01111100 */
	0x7c, /* 01111100 */
	0xfe, /* 11111110 */
	0xfe, /* 11111110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 31 0x1f '^_' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xfe, /* 11111110 */
	0xfe, /* 11111110 */
	0x7c, /* 01111100 */
	0x7c, /* 01111100 */
	0x38, /* 00111000 */
	0x38, /* 00111000 */
	0x10, /* 00010000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 32 0x20 ' ' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 33 0x21 '!' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x18, /* 00011000 */
	0x3c, /* 00111100 */
	0x3c, /* 00111100 */
	0x3c, /* 00111100 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x00, /* 00000000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 34 0x22 '"' */
	0x00, /* 00000000 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x24, /* 00100100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 35 0x23 '#' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x6c, /* 01101100 */
	0x6c, /* 01101100 */
	0xfe, /* 11111110 */
	0x6c, /* 01101100 */
	0x6c, /* 01101100 */
	0x6c, /* 01101100 */
	0xfe, /* 11111110 */
	0x6c, /* 01101100 */
	0x6c, /* 01101100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 36 0x24 '$' */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x7c, /* 01111100 */
	0xc6, /* 11000110 */
	0xc2, /* 11000010 */
	0xc0, /* 11000000 */
	0x7c, /* 01111100 */
	0x06, /* 00000110 */
	0x06, /* 00000110 */
	0x86, /* 10000110 */
	0xc6, /* 11000110 */
	0x7c, /* 01111100 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 37 0x25 '%' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xc2, /* 11000010 */
	0xc6, /* 11000110 */
	0x0c, /* 00001100 */
	0x18, /* 00011000 */
	0x30, /* 00110000 */
	0x60, /* 01100000 */
	0xc6, /* 11000110 */
	0x86, /* 10000110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 38 0x26 '&' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x38, /* 00111000 */
	0x6c, /* 01101100 */
	0x6c, /* 01101100 */
	0x38, /* 00111000 */
	0x76, /* 01110110 */
	0xdc, /* 11011100 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0x76, /* 01110110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 39 0x27 ''' */
	0x00, /* 00000000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x60, /* 01100000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 40 0x28 '(' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x0c, /* 00001100 */
	0x18, /* 00011000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x18, /* 00011000 */
	0x0c, /* 00001100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 41 0x29 ')' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x30, /* 00110000 */
	0x18, /* 00011000 */
	0x0c, /* 00001100 */
	0x0c, /* 00001100 */
	0x0c, /* 00001100 */
	0x0c, /* 00001100 */
	0x0c, /* 00001100 */
	0x0c, /* 00001100 */
	0x18, /* 00011000 */
	0x30, /* 00110000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 42 0x2a '*' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x66, /* 01100110 */
	0x3c, /* 00111100 */
	0xff, /* 11111111 */
	0x3c, /* 00111100 */
	0x66, /* 01100110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 43 0x2b '+' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x7e, /* 01111110 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 44 0x2c ',' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x30, /* 00110000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 45 0x2d '-' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xfe, /* 11111110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 46 0x2e '.' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 47 0x2f '/' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x02, /* 00000010 */
	0x06, /* 00000110 */
	0x0c, /* 00001100 */
	0x18, /* 00011000 */
	0x30, /* 00110000 */
	0x60, /* 01100000 */
	0xc0, /* 11000000 */
	0x80, /* 10000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 48 0x30 '0' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x38, /* 00111000 */
	0x6c, /* 01101100 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xd6, /* 11010110 */
	0xd6, /* 11010110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0x6c, /* 01101100 */
	0x38, /* 00111000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 49 0x31 '1' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x18, /* 00011000 */
	0x38, /* 00111000 */
	0x78, /* 01111000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x7e, /* 01111110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 50 0x32 '2' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x7c, /* 01111100 */
	0xc6, /* 11000110 */
	0x06, /* 00000110 */
	0x0c, /* 00001100 */
	0x18, /* 00011000 */
	0x30, /* 00110000 */
	0x60, /* 01100000 */
	0xc0, /* 11000000 */
	0xc6, /* 11000110 */
	0xfe, /* 11111110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 51 0x33 '3' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x7c, /* 01111100 */
	0xc6, /* 11000110 */
	0x06, /* 00000110 */
	0x06, /* 00000110 */
	0x3c, /* 00111100 */
	0x06, /* 00000110 */
	0x06, /* 00000110 */
	0x06, /* 00000110 */
	0xc6, /* 11000110 */
	0x7c, /* 01111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 52 0x34 '4' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x0c, /* 00001100 */
	0x1c, /* 00011100 */
	0x3c, /* 00111100 */
	0x6c, /* 01101100 */
	0xcc, /* 11001100 */
	0xfe, /* 11111110 */
	0x0c, /* 00001100 */
	0x0c, /* 00001100 */
	0x0c, /* 00001100 */
	0x1e, /* 00011110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 53 0x35 '5' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xfe, /* 11111110 */
	0xc0, /* 11000000 */
	0xc0, /* 11000000 */
	0xc0, /* 11000000 */
	0xfc, /* 11111100 */
	0x06, /* 00000110 */
	0x06, /* 00000110 */
	0x06, /* 00000110 */
	0xc6, /* 11000110 */
	0x7c, /* 01111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 54 0x36 '6' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x38, /* 00111000 */
	0x60, /* 01100000 */
	0xc0, /* 11000000 */
	0xc0, /* 11000000 */
	0xfc, /* 11111100 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0x7c, /* 01111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 55 0x37 '7' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xfe, /* 11111110 */
	0xc6, /* 11000110 */
	0x06, /* 00000110 */
	0x06, /* 00000110 */
	0x0c, /* 00001100 */
	0x18, /* 00011000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 56 0x38 '8' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x7c, /* 01111100 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0x7c, /* 01111100 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0x7c, /* 01111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 57 0x39 '9' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x7c, /* 01111100 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0x7e, /* 01111110 */
	0x06, /* 00000110 */
	0x06, /* 00000110 */
	0x06, /* 00000110 */
	0x0c, /* 00001100 */
	0x78, /* 01111000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 58 0x3a ':' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 59 0x3b ';' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x30, /* 00110000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 60 0x3c '<' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x06, /* 00000110 */
	0x0c, /* 00001100 */
	0x18, /* 00011000 */
	0x30, /* 00110000 */
	0x60, /* 01100000 */
	0x30, /* 00110000 */
	0x18, /* 00011000 */
	0x0c, /* 00001100 */
	0x06, /* 00000110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 61 0x3d '=' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x7e, /* 01111110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x7e, /* 01111110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 62 0x3e '>' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x60, /* 01100000 */
	0x30, /* 00110000 */
	0x18, /* 00011000 */
	0x0c, /* 00001100 */
	0x06, /* 00000110 */
	0x0c, /* 00001100 */
	0x18, /* 00011000 */
	0x30, /* 00110000 */
	0x60, /* 01100000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 63 0x3f '?' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x7c, /* 01111100 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0x0c, /* 00001100 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x00, /* 00000000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 64 0x40 '@' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x7c, /* 01111100 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xde, /* 11011110 */
	0xde, /* 11011110 */
	0xde, /* 11011110 */
	0xdc, /* 11011100 */
	0xc0, /* 11000000 */
	0x7c, /* 01111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 65 0x41 'A' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x10, /* 00010000 */
	0x38, /* 00111000 */
	0x6c, /* 01101100 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xfe, /* 11111110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 66 0x42 'B' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xfc, /* 11111100 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x7c, /* 01111100 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0xfc, /* 11111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 67 0x43 'C' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x3c, /* 00111100 */
	0x66, /* 01100110 */
	0xc2, /* 11000010 */
	0xc0, /* 11000000 */
	0xc0, /* 11000000 */
	0xc0, /* 11000000 */
	0xc0, /* 11000000 */
	0xc2, /* 11000010 */
	0x66, /* 01100110 */
	0x3c, /* 00111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 68 0x44 'D' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xf8, /* 11111000 */
	0x6c, /* 01101100 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x6c, /* 01101100 */
	0xf8, /* 11111000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 69 0x45 'E' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xfe, /* 11111110 */
	0x66, /* 01100110 */
	0x62, /* 01100010 */
	0x68, /* 01101000 */
	0x78, /* 01111000 */
	0x68, /* 01101000 */
	0x60, /* 01100000 */
	0x62, /* 01100010 */
	0x66, /* 01100110 */
	0xfe, /* 11111110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 70 0x46 'F' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xfe, /* 11111110 */
	0x66, /* 01100110 */
	0x62, /* 01100010 */
	0x68, /* 01101000 */
	0x78, /* 01111000 */
	0x68, /* 01101000 */
	0x60, /* 01100000 */
	0x60, /* 01100000 */
	0x60, /* 01100000 */
	0xf0, /* 11110000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 71 0x47 'G' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x3c, /* 00111100 */
	0x66, /* 01100110 */
	0xc2, /* 11000010 */
	0xc0, /* 11000000 */
	0xc0, /* 11000000 */
	0xde, /* 11011110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0x66, /* 01100110 */
	0x3a, /* 00111010 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 72 0x48 'H' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xfe, /* 11111110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 73 0x49 'I' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x3c, /* 00111100 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x3c, /* 00111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 74 0x4a 'J' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x1e, /* 00011110 */
	0x0c, /* 00001100 */
	0x0c, /* 00001100 */
	0x0c, /* 00001100 */
	0x0c, /* 00001100 */
	0x0c, /* 00001100 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0x78, /* 01111000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 75 0x4b 'K' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xe6, /* 11100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x6c, /* 01101100 */
	0x78, /* 01111000 */
	0x78, /* 01111000 */
	0x6c, /* 01101100 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0xe6, /* 11100110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 76 0x4c 'L' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xf0, /* 11110000 */
	0x60, /* 01100000 */
	0x60, /* 01100000 */
	0x60, /* 01100000 */
	0x60, /* 01100000 */
	0x60, /* 01100000 */
	0x60, /* 01100000 */
	0x62, /* 01100010 */
	0x66, /* 01100110 */
	0xfe, /* 11111110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 77 0x4d 'M' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xc6, /* 11000110 */
	0xee, /* 11101110 */
	0xfe, /* 11111110 */
	0xfe, /* 11111110 */
	0xd6, /* 11010110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 78 0x4e 'N' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xc6, /* 11000110 */
	0xe6, /* 11100110 */
	0xf6, /* 11110110 */
	0xfe, /* 11111110 */
	0xde, /* 11011110 */
	0xce, /* 11001110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 79 0x4f 'O' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x7c, /* 01111100 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0x7c, /* 01111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 80 0x50 'P' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xfc, /* 11111100 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x7c, /* 01111100 */
	0x60, /* 01100000 */
	0x60, /* 01100000 */
	0x60, /* 01100000 */
	0x60, /* 01100000 */
	0xf0, /* 11110000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 81 0x51 'Q' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x7c, /* 01111100 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xd6, /* 11010110 */
	0xde, /* 11011110 */
	0x7c, /* 01111100 */
	0x0c, /* 00001100 */
	0x0e, /* 00001110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 82 0x52 'R' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xfc, /* 11111100 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x7c, /* 01111100 */
	0x6c, /* 01101100 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0xe6, /* 11100110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 83 0x53 'S' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x7c, /* 01111100 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0x60, /* 01100000 */
	0x38, /* 00111000 */
	0x0c, /* 00001100 */
	0x06, /* 00000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0x7c, /* 01111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 84 0x54 'T' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x7e, /* 01111110 */
	0x7e, /* 01111110 */
	0x5a, /* 01011010 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x3c, /* 00111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 85 0x55 'U' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0x7c, /* 01111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 86 0x56 'V' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0x6c, /* 01101100 */
	0x38, /* 00111000 */
	0x10, /* 00010000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 87 0x57 'W' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xd6, /* 11010110 */
	0xd6, /* 11010110 */
	0xd6, /* 11010110 */
	0xfe, /* 11111110 */
	0xee, /* 11101110 */
	0x6c, /* 01101100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 88 0x58 'X' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0x6c, /* 01101100 */
	0x7c, /* 01111100 */
	0x38, /* 00111000 */
	0x38, /* 00111000 */
	0x7c, /* 01111100 */
	0x6c, /* 01101100 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 89 0x59 'Y' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x3c, /* 00111100 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x3c, /* 00111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 90 0x5a 'Z' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xfe, /* 11111110 */
	0xc6, /* 11000110 */
	0x86, /* 10000110 */
	0x0c, /* 00001100 */
	0x18, /* 00011000 */
	0x30, /* 00110000 */
	0x60, /* 01100000 */
	0xc2, /* 11000010 */
	0xc6, /* 11000110 */
	0xfe, /* 11111110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 91 0x5b '[' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x3c, /* 00111100 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x3c, /* 00111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 92 0x5c '\' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x80, /* 10000000 */
	0xc0, /* 11000000 */
	0xe0, /* 11100000 */
	0x70, /* 01110000 */
	0x38, /* 00111000 */
	0x1c, /* 00011100 */
	0x0e, /* 00001110 */
	0x06, /* 00000110 */
	0x02, /* 00000010 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 93 0x5d ']' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x3c, /* 00111100 */
	0x0c, /* 00001100 */
	0x0c, /* 00001100 */
	0x0c, /* 00001100 */
	0x0c, /* 00001100 */
	0x0c, /* 00001100 */
	0x0c, /* 00001100 */
	0x0c, /* 00001100 */
	0x0c, /* 00001100 */
	0x3c, /* 00111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 94 0x5e '^' */
	0x10, /* 00010000 */
	0x38, /* 00111000 */
	0x6c, /* 01101100 */
	0xc6, /* 11000110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 95 0x5f '_' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xff, /* 11111111 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 96 0x60 '`' */
	0x00, /* 00000000 */
	0x30, /* 00110000 */
	0x18, /* 00011000 */
	0x0c, /* 00001100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 97 0x61 'a' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x78, /* 01111000 */
	0x0c, /* 00001100 */
	0x7c, /* 01111100 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0x76, /* 01110110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 98 0x62 'b' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xe0, /* 11100000 */
	0x60, /* 01100000 */
	0x60, /* 01100000 */
	0x78, /* 01111000 */
	0x6c, /* 01101100 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x7c, /* 01111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 99 0x63 'c' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x7c, /* 01111100 */
	0xc6, /* 11000110 */
	0xc0, /* 11000000 */
	0xc0, /* 11000000 */
	0xc0, /* 11000000 */
	0xc6, /* 11000110 */
	0x7c, /* 01111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 100 0x64 'd' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x1c, /* 00011100 */
	0x0c, /* 00001100 */
	0x0c, /* 00001100 */
	0x3c, /* 00111100 */
	0x6c, /* 01101100 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0x76, /* 01110110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 101 0x65 'e' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x7c, /* 01111100 */
	0xc6, /* 11000110 */
	0xfe, /* 11111110 */
	0xc0, /* 11000000 */
	0xc0, /* 11000000 */
	0xc6, /* 11000110 */
	0x7c, /* 01111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 102 0x66 'f' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x1c, /* 00011100 */
	0x36, /* 00110110 */
	0x32, /* 00110010 */
	0x30, /* 00110000 */
	0x78, /* 01111000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x78, /* 01111000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 103 0x67 'g' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x76, /* 01110110 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0x7c, /* 01111100 */
	0x0c, /* 00001100 */
	0xcc, /* 11001100 */
	0x78, /* 01111000 */
	0x00, /* 00000000 */

	/* 104 0x68 'h' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xe0, /* 11100000 */
	0x60, /* 01100000 */
	0x60, /* 01100000 */
	0x6c, /* 01101100 */
	0x76, /* 01110110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0xe6, /* 11100110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 105 0x69 'i' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x00, /* 00000000 */
	0x38, /* 00111000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x3c, /* 00111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 106 0x6a 'j' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x06, /* 00000110 */
	0x06, /* 00000110 */
	0x00, /* 00000000 */
	0x0e, /* 00001110 */
	0x06, /* 00000110 */
	0x06, /* 00000110 */
	0x06, /* 00000110 */
	0x06, /* 00000110 */
	0x06, /* 00000110 */
	0x06, /* 00000110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x3c, /* 00111100 */
	0x00, /* 00000000 */

	/* 107 0x6b 'k' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xe0, /* 11100000 */
	0x60, /* 01100000 */
	0x60, /* 01100000 */
	0x66, /* 01100110 */
	0x6c, /* 01101100 */
	0x78, /* 01111000 */
	0x78, /* 01111000 */
	0x6c, /* 01101100 */
	0x66, /* 01100110 */
	0xe6, /* 11100110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 108 0x6c 'l' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x38, /* 00111000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x18, /* 00011000 */
	0x3c, /* 00111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 109 0x6d 'm' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xec, /* 11101100 */
	0xfe, /* 11111110 */
	0xd6, /* 11010110 */
	0xd6, /* 11010110 */
	0xd6, /* 11010110 */
	0xd6, /* 11010110 */
	0xc6, /* 11000110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 110 0x6e 'n' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xdc, /* 11011100 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 111 0x6f 'o' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x7c, /* 01111100 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0x7c, /* 01111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 112 0x70 'p' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xdc, /* 11011100 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x66, /* 01100110 */
	0x7c, /* 01111100 */
	0x60, /* 01100000 */
	0x60, /* 01100000 */
	0xf0, /* 11110000 */
	0x00, /* 00000000 */

	/* 113 0x71 'q' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x76, /* 01110110 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0x7c, /* 01111100 */
	0x0c, /* 00001100 */
	0x0c, /* 00001100 */
	0x1e, /* 00011110 */
	0x00, /* 00000000 */

	/* 114 0x72 'r' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xdc, /* 11011100 */
	0x76, /* 01110110 */
	0x66, /* 01100110 */
	0x60, /* 01100000 */
	0x60, /* 01100000 */
	0x60, /* 01100000 */
	0xf0, /* 11110000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 115 0x73 's' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x7c, /* 01111100 */
	0xc6, /* 11000110 */
	0x60, /* 01100000 */
	0x38, /* 00111000 */
	0x0c, /* 00001100 */
	0xc6, /* 11000110 */
	0x7c, /* 01111100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 116 0x74 't' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x10, /* 00010000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0xfc, /* 11111100 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x30, /* 00110000 */
	0x36, /* 00110110 */
	0x1c, /* 00011100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 117 0x75 'u' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0xcc, /* 11001100 */
	0x76, /* 01110110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 118 0x76 'v' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0x6c, /* 01101100 */
	0x38, /* 00111000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 119 0x77 'w' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xd6, /* 11010110 */
	0xd6, /* 11010110 */
	0xd6, /* 11010110 */
	0xfe, /* 11111110 */
	0x6c, /* 01101100 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 120 0x78 'x' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xc6, /* 11000110 */
	0x6c, /* 01101100 */
	0x38, /* 00111000 */
	0x38, /* 00111000 */
	0x38, /* 00111000 */
	0x6c, /* 01101100 */
	0xc6, /* 11000110 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */

	/* 121 0x79 'y' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0xc6, /* 11000110 */
	0x7e, /* 01111110 */
	0x06, /* 00000110 */
	0x0c, /* 00001100 */
	0xf8, /* 11111000 */
	0x00, /* 00000000 */

	/* 122 0x7a 'z' */
	0x00, /* 00000000 */
	0x00, /* 00000000 */
	0x0
Download .txt
gitextract__96k71ly/

├── .gitignore
├── .gitlab-ci.yml
├── .travis.yml
├── LICENSE
├── Makefile
├── README.md
├── configs/
│   ├── clang.mk
│   ├── gcc.mk
│   ├── i386-pc.mk
│   ├── i386-quark.mk
│   ├── none.mk
│   ├── pcc.mk
│   └── x86_64-pc.mk
├── initrd/
│   ├── Makefile
│   ├── etc/
│   │   ├── font.tf
│   │   ├── hostname
│   │   ├── motd
│   │   ├── passwd
│   │   └── rc.init
│   ├── init/
│   │   ├── Makefile
│   │   └── init.c
│   └── usr/
│       ├── bin/
│       │   ├── p++
│       │   ├── pcc
│       │   └── pcpp
│       ├── libexec/
│       │   ├── ccom
│       │   ├── cpp
│       │   └── cxxcom
│       ├── share/
│       │   └── man/
│       │       └── man1/
│       │           ├── ccom.1
│       │           ├── cpp.1
│       │           ├── p++.1
│       │           ├── pcc.1
│       │           └── pcpp.1
│       └── test.c
├── iso/
│   └── boot/
│       └── grub/
│           └── grub.cfg
├── kernel/
│   ├── Makefile
│   ├── README.md
│   ├── arch/
│   │   ├── Build.mk
│   │   ├── Makefile
│   │   ├── arm/
│   │   │   ├── Build.mk
│   │   │   ├── include/
│   │   │   │   ├── core/
│   │   │   │   │   └── types.h
│   │   │   │   ├── cpu/
│   │   │   │   │   └── io.h
│   │   │   │   └── mm/
│   │   │   │       └── mm.h
│   │   │   ├── kernel.arm.ld
│   │   │   └── none.c
│   │   ├── i386/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   ├── boot/
│   │   │   │   ├── Build.mk
│   │   │   │   ├── Makefile
│   │   │   │   ├── init.c
│   │   │   │   ├── multiboot.S
│   │   │   │   ├── sys.S
│   │   │   │   └── x86_64_bootstrap.S
│   │   │   ├── cpu/
│   │   │   │   ├── Build.mk
│   │   │   │   ├── Makefile
│   │   │   │   ├── arith.c
│   │   │   │   ├── cpu.S
│   │   │   │   ├── cpu.h
│   │   │   │   ├── fpu.c
│   │   │   │   ├── gdt.c
│   │   │   │   ├── idt.c
│   │   │   │   ├── init.c
│   │   │   │   ├── isr.c
│   │   │   │   ├── smp.S
│   │   │   │   └── trace.c
│   │   │   ├── earlycon/
│   │   │   │   ├── Build.mk
│   │   │   │   ├── Makefile
│   │   │   │   ├── earlycon.c
│   │   │   │   ├── fb.c
│   │   │   │   ├── font.h
│   │   │   │   ├── uart.c
│   │   │   │   └── vga.c
│   │   │   ├── include/
│   │   │   │   ├── boot/
│   │   │   │   │   ├── boot.h
│   │   │   │   │   └── multiboot.h
│   │   │   │   ├── config.h
│   │   │   │   ├── core/
│   │   │   │   │   ├── _string.h
│   │   │   │   │   ├── arch.h
│   │   │   │   │   ├── panic.h
│   │   │   │   │   ├── platform.h
│   │   │   │   │   └── system.h
│   │   │   │   ├── cpu/
│   │   │   │   │   ├── cpu.h
│   │   │   │   │   ├── cpuid.h
│   │   │   │   │   ├── io.h
│   │   │   │   │   ├── msr.h
│   │   │   │   │   ├── pit.h
│   │   │   │   │   └── sdt.h
│   │   │   │   ├── mm/
│   │   │   │   │   ├── mm.h
│   │   │   │   │   └── pmap.h
│   │   │   │   └── platform/
│   │   │   │       └── misc.h
│   │   │   ├── kernel.i386.ld
│   │   │   ├── kernel.x86_64.ld
│   │   │   ├── mm/
│   │   │   │   ├── Build.mk
│   │   │   │   ├── Makefile
│   │   │   │   ├── frame_utils.h
│   │   │   │   ├── i386.c
│   │   │   │   ├── i386.h
│   │   │   │   ├── mm.c
│   │   │   │   ├── page_utils.h
│   │   │   │   ├── x86_64.c
│   │   │   │   └── x86_64.h
│   │   │   ├── platform/
│   │   │   │   ├── Build.mk
│   │   │   │   ├── Makefile
│   │   │   │   ├── misc/
│   │   │   │   │   ├── Build.mk
│   │   │   │   │   ├── Makefile
│   │   │   │   │   ├── acpi.c
│   │   │   │   │   ├── cmos.c
│   │   │   │   │   ├── hpet.c
│   │   │   │   │   ├── i8042.c
│   │   │   │   │   ├── pic.c
│   │   │   │   │   └── pit.c
│   │   │   │   ├── pc/
│   │   │   │   │   ├── Build.mk
│   │   │   │   │   ├── Makefile
│   │   │   │   │   ├── init.c
│   │   │   │   │   └── reboot.c
│   │   │   │   └── quark/
│   │   │   │       ├── Build.mk
│   │   │   │       ├── include/
│   │   │   │       │   └── chipset/
│   │   │   │       │       ├── legacy_bridge.h
│   │   │   │       │       ├── root_complex.h
│   │   │   │       │       └── system.h
│   │   │   │       ├── init.c
│   │   │   │       └── legacy/
│   │   │   │           ├── Build.mk
│   │   │   │           ├── bridge.c
│   │   │   │           ├── interrupt.c
│   │   │   │           └── root_complex.c
│   │   │   └── sys/
│   │   │       ├── Build.mk
│   │   │       ├── Makefile
│   │   │       ├── execve.c
│   │   │       ├── fork.c
│   │   │       ├── proc.c
│   │   │       ├── sched.c
│   │   │       ├── signal.c
│   │   │       ├── sys.h
│   │   │       ├── syscall.c
│   │   │       └── thread.c
│   │   └── none/
│   │       ├── Build.mk
│   │       ├── include/
│   │       │   ├── core/
│   │       │   │   └── types.h
│   │       │   ├── cpu/
│   │       │   │   └── io.h
│   │       │   └── mm/
│   │       │       └── mm.h
│   │       ├── kernel.none.ld
│   │       └── none.c
│   ├── core/
│   │   ├── Build.mk
│   │   ├── Makefile
│   │   ├── kargs.c
│   │   ├── main.c
│   │   ├── module.c
│   │   ├── printk.c
│   │   ├── snprintf.c
│   │   └── time.c
│   ├── dev/
│   │   ├── Build.mk
│   │   ├── Makefile
│   │   ├── ata/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   ├── ata.c
│   │   │   ├── ata.h
│   │   │   └── pio.c
│   │   ├── fb/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   ├── fbdev/
│   │   │   │   ├── Build.mk
│   │   │   │   ├── Makefile
│   │   │   │   └── fbdev.c
│   │   │   └── vesa/
│   │   │       ├── Build.mk
│   │   │       ├── Makefile
│   │   │       └── vesa.c
│   │   ├── fdc/
│   │   │   ├── Build.mk
│   │   │   ├── fdc.c
│   │   │   ├── fdc_82077AA.c
│   │   │   └── fdc_82077AA.h
│   │   ├── kbd/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   ├── kbd.c
│   │   │   └── ps2kbd.c
│   │   ├── kdev.c
│   │   ├── mem/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   ├── kmsg.c
│   │   │   ├── memdev.c
│   │   │   ├── memdev.h
│   │   │   ├── null.c
│   │   │   └── zero.c
│   │   ├── mouse/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   └── ps2mouse.c
│   │   ├── pci/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   └── pci.c
│   │   ├── rd/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   └── ramdisk.c
│   │   └── tty/
│   │       ├── Build.mk
│   │       ├── Makefile
│   │       ├── console/
│   │       │   ├── Build.mk
│   │       │   ├── Makefile
│   │       │   └── console.c
│   │       ├── generic.c
│   │       ├── pty/
│   │       │   ├── Build.mk
│   │       │   ├── Makefile
│   │       │   └── pty.c
│   │       ├── tty.c
│   │       └── uart/
│   │           ├── 8250/
│   │           │   ├── 8250.c
│   │           │   ├── Build.mk
│   │           │   └── Makefile
│   │           ├── Build.mk
│   │           ├── Makefile
│   │           └── uart.c
│   ├── fs/
│   │   ├── Build.mk
│   │   ├── Makefile
│   │   ├── bcache.c
│   │   ├── close.c
│   │   ├── devfs/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   └── devfs.c
│   │   ├── devpts/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   └── devpts.c
│   │   ├── ext2/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   ├── block.c
│   │   │   ├── dentry.c
│   │   │   ├── ext2.c
│   │   │   ├── ext2.h
│   │   │   ├── inode.c
│   │   │   ├── super.c
│   │   │   └── vops.c
│   │   ├── fops.c
│   │   ├── initramfs/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   ├── cpio/
│   │   │   │   ├── Build.mk
│   │   │   │   ├── Makefile
│   │   │   │   ├── cpio.c
│   │   │   │   └── cpio.h
│   │   │   └── initramfs.c
│   │   ├── ioctl.c
│   │   ├── lookup.c
│   │   ├── minix/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   ├── block.c
│   │   │   ├── dentry.c
│   │   │   ├── inode.c
│   │   │   ├── minix.c
│   │   │   ├── minix.h
│   │   │   ├── super.c
│   │   │   └── vops.c
│   │   ├── mknod.c
│   │   ├── mount.c
│   │   ├── pipe.c
│   │   ├── posix/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   ├── close.c
│   │   │   ├── helpers.c
│   │   │   ├── ioctl.c
│   │   │   ├── lseek.c
│   │   │   ├── open.c
│   │   │   ├── read.c
│   │   │   ├── readdir.c
│   │   │   ├── trunc.c
│   │   │   └── write.c
│   │   ├── procfs/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   └── procfs.c
│   │   ├── pseudofs/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   └── pseudofs.c
│   │   ├── read.c
│   │   ├── readdir.c
│   │   ├── rofs.c
│   │   ├── stat.c
│   │   ├── sync.c
│   │   ├── tmpfs/
│   │   │   ├── Build.mk
│   │   │   ├── Makefile
│   │   │   └── tmpfs.c
│   │   ├── trunc.c
│   │   ├── unlink.c
│   │   ├── vcache.c
│   │   ├── vfs.c
│   │   ├── vm_object.c
│   │   ├── vops.c
│   │   └── write.c
│   ├── include/
│   │   ├── bits/
│   │   │   ├── dirent.h
│   │   │   ├── errno.h
│   │   │   ├── fcntl.h
│   │   │   ├── mman.h
│   │   │   └── utsname.h
│   │   ├── boot/
│   │   │   └── boot.h
│   │   ├── config.h
│   │   ├── console/
│   │   │   └── earlycon.h
│   │   ├── core/
│   │   │   ├── arch.h
│   │   │   ├── assert.h
│   │   │   ├── kargs.h
│   │   │   ├── module.h
│   │   │   ├── panic.h
│   │   │   ├── printk.h
│   │   │   ├── qsort.h
│   │   │   ├── string.h
│   │   │   ├── system.h
│   │   │   ├── time.h
│   │   │   └── types.h
│   │   ├── cpu/
│   │   │   ├── cpu.h
│   │   │   └── io.h
│   │   ├── dev/
│   │   │   ├── console.h
│   │   │   ├── dev.h
│   │   │   ├── fbdev.h
│   │   │   ├── kbd.h
│   │   │   ├── pci.h
│   │   │   ├── ramdev.h
│   │   │   ├── tty.h
│   │   │   ├── ttydev.h
│   │   │   └── uart.h
│   │   ├── ds/
│   │   │   ├── bitmap.h
│   │   │   ├── buddy.h
│   │   │   ├── ds.dox
│   │   │   ├── hashmap.h
│   │   │   ├── queue.h
│   │   │   └── ringbuf.h
│   │   ├── fs/
│   │   │   ├── bcache.h
│   │   │   ├── devfs.h
│   │   │   ├── devpts.h
│   │   │   ├── initramfs.h
│   │   │   ├── ioctl.h
│   │   │   ├── mbr.h
│   │   │   ├── pipe.h
│   │   │   ├── posix.h
│   │   │   ├── pseudofs.h
│   │   │   ├── rofs.h
│   │   │   ├── stat.h
│   │   │   ├── termios.h
│   │   │   ├── tmpfs.h
│   │   │   ├── vcache.h
│   │   │   └── vfs.h
│   │   ├── mm/
│   │   │   ├── buddy.h
│   │   │   ├── heap.h
│   │   │   ├── kvmem.h
│   │   │   ├── mm.h
│   │   │   ├── pmap.h
│   │   │   └── vm.h
│   │   ├── net/
│   │   │   └── socket.h
│   │   ├── stdarg.h
│   │   ├── stddef.h
│   │   ├── stdint.h
│   │   ├── sys/
│   │   │   ├── binfmt.h
│   │   │   ├── elf.h
│   │   │   ├── proc.h
│   │   │   ├── sched.h
│   │   │   ├── signal.h
│   │   │   ├── syscall.h
│   │   │   └── thread.h
│   │   └── video/
│   │       ├── vbe.h
│   │       └── vesa.h
│   ├── mm/
│   │   ├── Build.mk
│   │   ├── Makefile
│   │   ├── buddy.c
│   │   ├── fault.c
│   │   ├── kvmem.c
│   │   ├── mm.c
│   │   ├── vm_anon.c
│   │   ├── vm_entry.c
│   │   ├── vm_object.c
│   │   ├── vm_space.c
│   │   └── vmm.c
│   ├── net/
│   │   ├── Build.mk
│   │   ├── Makefile
│   │   ├── socket.c
│   │   └── unix/
│   │       ├── Build.mk
│   │       ├── Makefile
│   │       ├── unix.c
│   │       └── unix.h
│   └── sys/
│       ├── Build.mk
│       ├── Makefile
│       ├── binfmt/
│       │   ├── Build.mk
│       │   ├── Makefile
│       │   ├── binfmt.c
│       │   └── elf.c
│       ├── execve.c
│       ├── fork.c
│       ├── proc.c
│       ├── sched.c
│       ├── signal.c
│       ├── syscall.c
│       └── thread.c
├── loader/
│   ├── grub-legacy/
│   │   └── boot/
│   │       └── grub/
│   │           └── menu.lst
│   └── grub2/
│       └── boot/
│           └── grub/
│               └── grub.cfg
└── system/
    ├── Makefile
    ├── aqbox/
    │   ├── Build.mk
    │   ├── Makefile
    │   ├── aqbox.c
    │   ├── extra/
    │   │   ├── Build.mk
    │   │   ├── Makefile
    │   │   ├── bim.c
    │   │   ├── clear.c
    │   │   ├── mknod.c
    │   │   ├── mktemp.c
    │   │   ├── readmbr.c
    │   │   ├── stat.c
    │   │   ├── truncate.c
    │   │   └── vmstat.c
    │   ├── include/
    │   │   ├── aq_applets.h
    │   │   └── aqbox.h
    │   ├── posix/
    │   │   ├── Build.mk
    │   │   ├── Makefile
    │   │   ├── cat.c
    │   │   ├── date.c
    │   │   ├── echo.c
    │   │   ├── env.c
    │   │   ├── kill.c
    │   │   ├── ls.c
    │   │   ├── mkdir.c
    │   │   ├── ps.c
    │   │   ├── pwd.c
    │   │   ├── sh.c
    │   │   ├── touch.c
    │   │   ├── uname.c
    │   │   └── unlink.c
    │   └── sys/
    │       ├── Build.mk
    │       ├── Makefile
    │       ├── getty.c
    │       ├── login.c
    │       ├── mount.c
    │       └── reboot.c
    ├── fbterm/
    │   ├── Build.mk
    │   ├── Makefile
    │   ├── aqkb.c
    │   ├── fb.c
    │   ├── fbterm.c
    │   ├── font.c
    │   ├── include/
    │   │   ├── aqkb.h
    │   │   ├── config.h
    │   │   ├── fb.h
    │   │   ├── fbterm.h
    │   │   ├── tinyfont.h
    │   │   ├── vterm.h
    │   │   └── vterm_keycodes.h
    │   ├── libvterm/
    │   │   ├── Build.mk
    │   │   ├── Makefile
    │   │   ├── encoding/
    │   │   │   ├── DECdrawing.inc
    │   │   │   ├── DECdrawing.tbl
    │   │   │   ├── uk.inc
    │   │   │   └── uk.tbl
    │   │   ├── encoding.c
    │   │   ├── keyboard.c
    │   │   ├── mouse.c
    │   │   ├── parser.c
    │   │   ├── pen.c
    │   │   ├── rect.h
    │   │   ├── screen.c
    │   │   ├── state.c
    │   │   ├── unicode.c
    │   │   ├── utf8.h
    │   │   ├── vterm.c
    │   │   └── vterm_internal.h
    │   └── nanojpeg.c
    ├── kilo/
    │   ├── Build.mk
    │   ├── LICENSE
    │   ├── Makefile
    │   ├── README.md
    │   └── kilo.c
    └── scripts/
        └── gen.pl
Download .txt
SYMBOL INDEX (2223 symbols across 260 files)

FILE: initrd/init/init.c
  function log_init (line 12) | int log_init()
  function _log (line 17) | int _log(int level, const char *fmt, ...)
  function run (line 30) | int run(char **argv)
  function signal_handler (line 46) | void signal_handler(int sig)
  function main (line 58) | int main(int argc, char **argv)

FILE: initrd/usr/test.c
  function main (line 3) | int main()

FILE: kernel/arch/arm/include/core/types.h
  type paddr_t (line 4) | typedef uintptr_t paddr_t;
  type vaddr_t (line 5) | typedef uintptr_t vaddr_t;

FILE: kernel/arch/arm/include/cpu/io.h
  function io_in8 (line 6) | static inline uint8_t io_in8(struct ioaddr *io, uintptr_t off)
  function io_in16 (line 11) | static inline uint16_t io_in16(struct ioaddr *io, uintptr_t off)
  function io_in32 (line 16) | static inline uint32_t io_in32(struct ioaddr *io, uintptr_t off)
  function io_out8 (line 21) | static inline void io_out8(struct ioaddr *io, uintptr_t off, uint8_t val)
  function io_out16 (line 25) | static inline void io_out16(struct ioaddr *io, uintptr_t off, uint16_t val)
  function io_out32 (line 29) | static inline void io_out32(struct ioaddr *io, uintptr_t off, uint32_t val)

FILE: kernel/arch/i386/boot/init.c
  function enable_paging (line 35) | static inline void enable_paging(uintptr_t page_directory)
  function switch_to_higher_half (line 44) | static void switch_to_higher_half(void)
  function x86_bootstrap (line 100) | void x86_bootstrap()

FILE: kernel/arch/i386/cpu/arith.c
  function divl (line 11) | static inline uint32_t divl(uint64_t n, uint32_t d)
  function nlz (line 26) | static int nlz(uint32_t x)
  function udiv64 (line 57) | static uint64_t udiv64(uint64_t n, uint64_t d)
  function umod64 (line 108) | static uint32_t umod64(uint64_t n, uint64_t d)
  function sdiv64 (line 115) | static int64_t sdiv64(int64_t n, int64_t d)
  function smod64 (line 125) | static int32_t smod64(int64_t n, int64_t d)
  function __divdi3 (line 138) | long long __divdi3(long long n, long long d)
  function __moddi3 (line 144) | long long __moddi3(long long n, long long d)
  function __udivdi3 (line 150) | unsigned long long __udivdi3(unsigned long long n, unsigned long long d)
  function __umoddi3 (line 156) | unsigned long long __umoddi3(unsigned long long n, unsigned long long d)

FILE: kernel/arch/i386/cpu/fpu.c
  type thread (line 12) | struct thread
  function x86_fpu_enable (line 14) | void x86_fpu_enable(void)
  function x86_fpu_disable (line 20) | void x86_fpu_disable(void)
  function x86_fpu_init (line 25) | void x86_fpu_init(void)
  function fpu_save (line 31) | static inline void fpu_save(void)
  function fpu_restore (line 36) | static inline void fpu_restore(void)
  function x86_fpu_trap (line 41) | void x86_fpu_trap(void)

FILE: kernel/arch/i386/cpu/gdt.c
  type gdt_entry (line 55) | struct gdt_entry {
  function x86_gdt_setup (line 88) | void x86_gdt_setup(void)
  function x86_tss_setup (line 95) | void x86_tss_setup(uintptr_t sp)
  function x86_kernel_stack_set (line 133) | void x86_kernel_stack_set(uintptr_t sp)

FILE: kernel/arch/i386/cpu/idt.c
  type idt_entry (line 17) | struct idt_entry {
  type idt_ptr (line 31) | struct idt_ptr {
  function x86_idt_gate_set (line 43) | void x86_idt_gate_set(uint32_t id, uintptr_t offset)
  function x86_idt_gate_user_set (line 58) | void x86_idt_gate_user_set(uint32_t id, uintptr_t offset)
  function x86_idt_setup (line 72) | void x86_idt_setup()

FILE: kernel/arch/i386/cpu/init.c
  type x86_cpu (line 25) | struct x86_cpu
  type boot (line 27) | struct boot
  function x86_cpu_init (line 29) | void x86_cpu_init(void)

FILE: kernel/arch/i386/cpu/isr.c
  type x86_regs (line 95) | struct x86_regs
  type x86_thread (line 101) | struct x86_thread
  type x86_regs (line 110) | struct x86_regs
  type x86_regs (line 111) | struct x86_regs
  type x86_thread (line 140) | struct x86_thread
  function x86_isr_setup (line 163) | void x86_isr_setup(void)

FILE: kernel/arch/i386/cpu/trace.c
  type stack_frame (line 5) | struct stack_frame {
  type boot (line 10) | struct boot
  function arch_stack_trace (line 14) | void arch_stack_trace()

FILE: kernel/arch/i386/earlycon/earlycon.c
  type earlycon (line 5) | struct earlycon
  type earlycon (line 7) | struct earlycon
  type earlycon (line 8) | struct earlycon
  type earlycon (line 9) | struct earlycon
  function earlycon_puts (line 11) | int earlycon_puts(char *s)
  function earlycon_putc (line 16) | int earlycon_putc(char c)
  function earlycon_init (line 21) | void earlycon_init()
  function earlycon_reinit (line 27) | void earlycon_reinit()

FILE: kernel/arch/i386/earlycon/fb.c
  type vm_entry (line 14) | struct vm_entry
  function earlycon_fb_register (line 21) | void earlycon_fb_register(uintptr_t paddr, uint32_t scanline, uint32_t y...
  function earlycon_fb_scroll (line 33) | static void earlycon_fb_scroll(int n)
  function fb_putc (line 40) | static void fb_putc(int row, int col, char c)
  function earlycon_fb_putc (line 65) | static int earlycon_fb_putc(char c)
  function earlycon_fb_puts (line 101) | static int earlycon_fb_puts(char *s)
  function earlycon_fb_init (line 109) | static void earlycon_fb_init()
  type earlycon (line 122) | struct earlycon

FILE: kernel/arch/i386/earlycon/uart.c
  type ioaddr (line 10) | struct ioaddr
  type ioaddr (line 15) | struct ioaddr
  function serial_init (line 29) | static void serial_init(void)
  function serial_tx_empty (line 43) | static int serial_tx_empty(void)
  function serial_chr (line 48) | static int serial_chr(char chr)
  function serial_str (line 60) | static int serial_str(char *str)
  function earlycon_uart_puts (line 72) | static int earlycon_uart_puts(char *s)
  function earlycon_uart_putc (line 77) | static int earlycon_uart_putc(char c)
  function earlycon_uart_init (line 82) | static void earlycon_uart_init(void)
  type earlycon (line 93) | struct earlycon

FILE: kernel/arch/i386/earlycon/vga.c
  type ioaddr (line 9) | struct ioaddr
  function earlycon_vga_scroll (line 14) | static void earlycon_vga_scroll(int n)
  function earlycon_vga_putc (line 26) | static int earlycon_vga_putc(char c)
  function earlycon_vga_puts (line 44) | static int earlycon_vga_puts(char *s)
  function earlycon_vga_init (line 55) | static void earlycon_vga_init()
  type earlycon (line 67) | struct earlycon

FILE: kernel/arch/i386/include/boot/boot.h
  function get_multiboot_mmap_count (line 13) | static inline int get_multiboot_mmap_count(multiboot_info_t *info)
  function build_multiboot_mmap (line 29) | static inline void
  function build_multiboot_modules (line 50) | static inline void
  type boot (line 64) | struct boot
  type boot (line 66) | struct boot
  type elf32_shdr (line 72) | struct elf32_shdr
  type elf32_shdr (line 75) | struct elf32_shdr
  type elf32_shdr (line 76) | struct elf32_shdr
  type elf32_shdr (line 79) | struct elf32_shdr
  type elf32_sym (line 85) | struct elf32_sym
  type vbe_info_block (line 105) | struct vbe_info_block
  type vbe_info_block (line 105) | struct vbe_info_block
  type mode_info_block (line 106) | struct mode_info_block
  type mode_info_block (line 106) | struct mode_info_block
  type fbdev_vesa (line 123) | struct fbdev_vesa
  type vbe_info_block (line 124) | struct vbe_info_block
  type mode_info_block (line 125) | struct mode_info_block

FILE: kernel/arch/i386/include/boot/multiboot.h
  type multiboot_header (line 97) | struct multiboot_header
  type multiboot_aout_symbol_table (line 123) | struct multiboot_aout_symbol_table
  type multiboot_aout_symbol_table_t (line 130) | typedef struct multiboot_aout_symbol_table multiboot_aout_symbol_table_t;
  type multiboot_elf_section_header_table (line 133) | struct multiboot_elf_section_header_table
  type multiboot_elf_section_header_table_t (line 140) | typedef struct multiboot_elf_section_header_table multiboot_elf_section_...
  type multiboot_info (line 142) | struct multiboot_info
  type multiboot_info_t (line 192) | typedef struct multiboot_info multiboot_info_t;
  type multiboot_mmap_entry (line 194) | struct multiboot_mmap_entry
  type multiboot_mmap_t (line 203) | typedef struct multiboot_mmap_entry multiboot_mmap_t;
  type multiboot_mod_list (line 205) | struct multiboot_mod_list
  type multiboot_module_t (line 217) | typedef struct multiboot_mod_list multiboot_module_t;

FILE: kernel/arch/i386/include/core/_string.h
  function strncmp (line 45) | static inline int strncmp(const char *s1, const char *s2, size_t n)
  function strcmp (line 78) | static inline int strcmp(const char *s1, const char *s2)
  function strlen (line 84) | static inline int strlen(const char *s)
  function free_tokens (line 151) | static inline void free_tokens(char **ptr)

FILE: kernel/arch/i386/include/core/arch.h
  type x86_thread (line 10) | struct x86_thread {
  type x86_regs (line 38) | struct x86_regs
  function arch_interrupts_enable (line 45) | static inline void arch_interrupts_enable(void)
  function arch_interrupts_disable (line 50) | static inline void arch_interrupts_disable(void)

FILE: kernel/arch/i386/include/cpu/cpu.h
  type x86_regs (line 7) | struct x86_regs {
  function x86_dump_registers (line 20) | static inline void x86_dump_registers(struct x86_regs *regs)
  type x86_cpu (line 60) | struct x86_cpu {
  function read_cr0 (line 76) | static inline uintptr_t read_cr0(void)
  function read_cr1 (line 87) | static inline uintptr_t read_cr1(void)
  function read_cr2 (line 98) | static inline uintptr_t read_cr2(void)
  function read_cr3 (line 109) | static inline uintptr_t read_cr3(void)
  function read_cr4 (line 120) | static inline uintptr_t read_cr4(void)
  function write_cr0 (line 131) | static inline void write_cr0(uintptr_t val)
  function write_cr1 (line 140) | static inline void write_cr1(uintptr_t val)
  function write_cr2 (line 149) | static inline void write_cr2(uintptr_t val)
  function write_cr3 (line 158) | static inline void write_cr3(uintptr_t val)
  function write_cr4 (line 167) | static inline void write_cr4(uintptr_t val)

FILE: kernel/arch/i386/include/cpu/cpuid.h
  type x86_cpuid_features (line 12) | struct x86_cpuid_features {
  function x86_cpuid_features (line 49) | static inline int x86_cpuid_features(struct x86_cpuid_features *features)
  function x86_cpuid_vendor (line 64) | static inline int x86_cpuid_vendor(union x86_cpuid_vendor *vendor)

FILE: kernel/arch/i386/include/cpu/io.h
  type ioaddr (line 69) | struct ioaddr {
  type ioaddr (line 74) | struct ioaddr
  function io_in8 (line 90) | static inline uint8_t io_in8(struct ioaddr *io, uintptr_t off)
  function io_in16 (line 106) | static inline uint16_t io_in16(struct ioaddr *io, uintptr_t off)
  function io_in32 (line 122) | static inline uint32_t io_in32(struct ioaddr *io, uintptr_t off)
  function io_out8 (line 138) | static inline void io_out8(struct ioaddr *io, uintptr_t off, uint8_t val)
  function io_out16 (line 152) | static inline void io_out16(struct ioaddr *io, uintptr_t off, uint16_t val)
  function io_out32 (line 166) | static inline void io_out32(struct ioaddr *io, uintptr_t off, uint32_t val)

FILE: kernel/arch/i386/include/cpu/msr.h
  function msr_read (line 6) | static inline uint64_t msr_read(uint32_t msr)
  function msr_write (line 13) | static inline void msr_write(uint32_t msr, uint64_t val)

FILE: kernel/arch/i386/include/cpu/sdt.h
  type acpi_rsdp (line 6) | struct acpi_rsdp {
  type acpi_sdt_header (line 14) | struct acpi_sdt_header {
  type acpi_rsdt (line 26) | struct acpi_rsdt {
  type acpi_madt_entry (line 35) | struct acpi_madt_entry {
  type acpi_madt (line 58) | struct acpi_madt {

FILE: kernel/arch/i386/include/mm/mm.h
  function tlb_flush (line 22) | static inline void tlb_flush(void)
  type paddr_t (line 28) | typedef uint32_t paddr_t;
  type vaddr_t (line 29) | typedef uint32_t vaddr_t;
  type paddr_t (line 31) | typedef uint64_t paddr_t;
  type vaddr_t (line 32) | typedef uint64_t vaddr_t;

FILE: kernel/arch/i386/include/mm/pmap.h
  type pmap (line 4) | struct pmap {

FILE: kernel/arch/i386/include/platform/misc.h
  type x86_regs (line 7) | struct x86_regs
  type ioaddr (line 9) | struct ioaddr
  type ioaddr (line 9) | struct ioaddr
  type ioaddr (line 14) | struct ioaddr
  type ioaddr (line 18) | struct ioaddr
  type ioaddr (line 21) | struct ioaddr

FILE: kernel/arch/i386/mm/frame_utils.h
  function frame_get (line 4) | static inline uintptr_t frame_get()
  function frame_get_no_clr (line 20) | static inline uintptr_t frame_get_no_clr()
  function frame_release (line 31) | static void frame_release(uintptr_t i)

FILE: kernel/arch/i386/mm/i386.c
  type pmap (line 28) | struct pmap
  function tlb_invalidate_page (line 33) | static inline void tlb_invalidate_page(uintptr_t virt)
  function frame_mount (line 44) | static inline uintptr_t frame_mount(uintptr_t paddr)
  function frame_get (line 62) | static inline uintptr_t frame_get(void)
  function frame_get_no_clr (line 78) | static inline uintptr_t frame_get_no_clr(void)
  function frame_release (line 90) | static void frame_release(uintptr_t i)
  function paddr_t (line 97) | static inline paddr_t table_alloc(void)
  function table_dealloc (line 108) | static inline void table_dealloc(paddr_t paddr)
  function table_map (line 113) | static inline int table_map(paddr_t paddr, size_t pdidx, int flags)
  function table_unmap (line 127) | static inline void table_unmap(size_t pdidx)
  function page_map (line 141) | static inline int page_map(paddr_t paddr, size_t pdidx, size_t ptidx, in...
  function page_protect (line 172) | static inline int page_protect(size_t pdidx, size_t ptidx, uint32_t flags)
  function page_unmap (line 199) | static inline void page_unmap(vaddr_t vaddr)
  function __page_get_mapping (line 228) | static inline uint32_t __page_get_mapping(vaddr_t vaddr)
  function table_dump (line 240) | static void table_dump(paddr_t table)
  type pmap (line 260) | struct pmap
  type pmap (line 260) | struct pmap
  type pmap (line 265) | struct pmap
  type pmap (line 283) | struct pmap
  function setup_i386_paging (line 285) | static void setup_i386_paging(void)
  function arch_page_unmap (line 308) | int arch_page_unmap(vaddr_t vaddr)
  function arch_mm_page_fault (line 317) | void arch_mm_page_fault(vaddr_t vaddr, int err)
  type pmap (line 331) | struct pmap
  type pmap (line 333) | struct pmap
  function pmap_release (line 336) | static void pmap_release(struct pmap *pmap)
  function pmap_init (line 349) | void pmap_init(void)
  type pmap (line 355) | struct pmap
  type pmap (line 357) | struct pmap
  type pmap (line 362) | struct pmap
  function pmap_incref (line 370) | void pmap_incref(struct pmap *pmap)
  function pmap_decref (line 376) | void pmap_decref(struct pmap *pmap)
  function pmap_add (line 386) | int pmap_add(struct pmap *pmap, vaddr_t va, paddr_t pa, uint32_t flags)
  function pmap_remove (line 406) | void pmap_remove(struct pmap *pmap, vaddr_t sva, vaddr_t eva)
  function table_remove_all (line 421) | static void table_remove_all(paddr_t table)
  function pmap_remove_all (line 440) | void pmap_remove_all(struct pmap *pmap)
  function pmap_protect (line 471) | void pmap_protect(struct pmap *pmap, vaddr_t sva, vaddr_t eva, uint32_t ...
  function pmap_copy (line 491) | void pmap_copy(struct pmap *dst_map, struct pmap *src_map, vaddr_t dst_a...
  function pmap_update (line 497) | void pmap_update(struct pmap *pmap)
  function pmap_page_copy (line 503) | void pmap_page_copy(paddr_t src, paddr_t dst)
  function pmap_page_protect (line 510) | void pmap_page_protect(struct vm_page *pg, uint32_t flags)
  function pmap_clear_modify (line 515) | int pmap_clear_modify(struct vm_page *pg)
  function pmap_clear_reference (line 520) | int pmap_clear_reference(struct vm_page *pg)
  function pmap_is_modified (line 525) | int pmap_is_modified(struct vm_page *pg)
  function pmap_is_referenced (line 530) | int pmap_is_referenced(struct vm_page *pg)
  function paddr_t (line 535) | paddr_t arch_page_get_mapping(struct pmap *pmap, vaddr_t vaddr)
  function pmap_page_read (line 553) | int pmap_page_read(paddr_t paddr, off_t off, size_t size, void *buf)
  function pmap_page_write (line 563) | int pmap_page_write(paddr_t paddr, off_t off, size_t size, void *buf)

FILE: kernel/arch/i386/mm/mm.c
  function arch_mm_setup (line 24) | void arch_mm_setup(void)

FILE: kernel/arch/i386/mm/x86_64.c
  function tlb_invalidate_page (line 29) | static inline void tlb_invalidate_page(uintptr_t virt)
  function frame_mount (line 36) | static inline uintptr_t frame_mount(uintptr_t paddr)
  function pdpt_map (line 62) | static inline int pdpt_map(paddr_t paddr, size_t idx, int flags)
  function pd_map (line 82) | static inline int pd_map(paddr_t paddr, size_t pdpt_idx, size_t pd_idx, ...
  function table_map (line 102) | static inline int table_map(paddr_t paddr, size_t pdpt_idx, size_t pd_id...
  function __page_map (line 122) | static inline int __page_map(paddr_t paddr, size_t pml4, size_t dirtbl, ...
  function __page_unmap (line 167) | static inline void __page_unmap(vaddr_t vaddr)
  function arch_page_map (line 220) | int arch_page_map(paddr_t paddr, vaddr_t vaddr, int flags)
  function arch_page_unmap (line 238) | int arch_page_unmap(vaddr_t vaddr)
  function __page_t (line 252) | static inline __page_t *__page_get_mapping(uintptr_t addr)
  function paddr_t (line 270) | paddr_t arch_page_get_mapping(struct pmap *pmap, vaddr_t vaddr)
  function arch_mm_page_fault (line 280) | void arch_mm_page_fault(vaddr_t vaddr, int err)
  function paddr_t (line 293) | paddr_t arch_get_frame()
  function arch_release_frame (line 298) | void arch_release_frame(paddr_t paddr)
  type pmap (line 303) | struct pmap
  type pmap (line 304) | struct pmap
  type pmap (line 304) | struct pmap
  type pmap (line 309) | struct pmap
  type pmap (line 328) | struct pmap
  function setup_64_bit_paging (line 330) | void setup_64_bit_paging()
  type pmap (line 355) | struct pmap
  type pmap (line 357) | struct pmap
  function pmap_release (line 360) | static void pmap_release(struct pmap *pmap)
  function arch_pmap_init (line 373) | void arch_pmap_init(void)
  type pmap (line 379) | struct pmap
  type pmap (line 381) | struct pmap
  type pmap (line 386) | struct pmap
  function arch_pmap_incref (line 395) | void arch_pmap_incref(struct pmap *pmap)
  function arch_pmap_decref (line 402) | void arch_pmap_decref(struct pmap *pmap)
  function arch_pmap_add (line 410) | int arch_pmap_add(struct pmap *pmap, vaddr_t va, paddr_t pa, uint32_t fl...
  function arch_pmap_remove (line 437) | void arch_pmap_remove(struct pmap *pmap, vaddr_t sva, vaddr_t eva)
  function arch_pmap_remove_all (line 454) | void arch_pmap_remove_all(struct pmap *pmap)
  function arch_pmap_protect (line 493) | void arch_pmap_protect(struct pmap *pmap, vaddr_t sva, vaddr_t eva, uint...
  function arch_pmap_copy (line 517) | void arch_pmap_copy(struct pmap *dst_map, struct pmap *src_map, vaddr_t ...
  function arch_pmap_update (line 523) | void arch_pmap_update(struct pmap *pmap)
  function arch_pmap_page_copy (line 529) | void arch_pmap_page_copy(paddr_t src, paddr_t dst)
  function arch_pmap_page_protect (line 536) | void arch_pmap_page_protect(struct vm_page *pg, uint32_t flags)
  function arch_pmap_clear_modify (line 541) | int arch_pmap_clear_modify(struct vm_page *pg)
  function arch_pmap_clear_reference (line 546) | int arch_pmap_clear_reference(struct vm_page *pg)
  function arch_pmap_is_modified (line 551) | int arch_pmap_is_modified(struct vm_page *pg)
  function arch_pmap_is_referenced (line 556) | int arch_pmap_is_referenced(struct vm_page *pg)
  function paddr_t (line 561) | paddr_t arch_page_get_mapping(struct pmap *pmap, vaddr_t vaddr)

FILE: kernel/arch/i386/mm/x86_64.h
  type __packed (line 11) | typedef union __pml4 {
  type __dirtbl_t (line 28) | typedef union __dirtbl {
  type __directory_t (line 50) | typedef union __directory {
  type __table_t (line 69) | typedef union __table {
  type __packed (line 92) | typedef union __page {
  type __virtaddr_t (line 114) | typedef union {

FILE: kernel/arch/i386/platform/misc/acpi.c
  function byte_checksum (line 8) | static inline int byte_checksum(const char *p, size_t s)
  type acpi_rsdp (line 15) | struct acpi_rsdp
  type acpi_rsdp (line 24) | struct acpi_rsdp
  type acpi_rsdp (line 25) | struct acpi_rsdp
  type acpi_rsdp (line 32) | struct acpi_rsdp
  type acpi_rsdp (line 33) | struct acpi_rsdp
  type vmr (line 44) | struct vmr
  function acpi_setup (line 48) | void acpi_setup()
  function acpi_rsdt_find (line 77) | uintptr_t acpi_rsdt_find(char signature[4])

FILE: kernel/arch/i386/platform/misc/cmos.c
  type ioaddr (line 17) | struct ioaddr
  function cmos_reg_read (line 19) | static uint8_t cmos_reg_read(uint8_t reg)
  type cmos_rtc (line 25) | struct cmos_rtc {
  function bcd_to_bin (line 35) | static inline uint8_t bcd_to_bin(uint8_t bcd)
  function cmos_time (line 40) | static int cmos_time(struct cmos_rtc *rtc)
  function arch_time_get (line 67) | int arch_time_get(struct timespec *ts)
  function x86_cmos_setup (line 92) | int x86_cmos_setup(struct ioaddr *ioaddr)

FILE: kernel/arch/i386/platform/misc/hpet.c
  type hpet_reg_cap (line 17) | struct hpet_reg_cap {
  type hpet_reg_cnf (line 32) | struct hpet_reg_cnf {
  type hpet_reg_tmr_cnf (line 46) | struct hpet_reg_tmr_cnf {
  type hpet (line 72) | struct hpet {
  type hpet (line 97) | struct   hpet
  function hpet_reg_read (line 103) | static uint64_t hpet_reg_read(uint16_t off)
  function hpet_reg_write (line 112) | static void hpet_reg_write(uint16_t off, uint64_t val)
  function hpet_irq_handler (line 121) | void hpet_irq_handler(void)
  function hpet_timer_setup (line 127) | int hpet_timer_setup(size_t period_ns, void (*handler)())
  function hpet_setup (line 147) | void hpet_setup()

FILE: kernel/arch/i386/platform/misc/i8042.c
  type ioaddr (line 8) | struct ioaddr
  function read_status (line 27) | static uint8_t read_status(void)
  function x86_i8042_read_wait (line 32) | static void x86_i8042_read_wait(void)
  function x86_i8042_check (line 38) | static int x86_i8042_check(void)
  function x86_i8042_first_handler (line 46) | static void x86_i8042_first_handler(struct x86_regs *r)
  function x86_i8042_second_handler (line 57) | static void x86_i8042_second_handler(struct x86_regs *r)
  function x86_i8042_handler_install (line 67) | static void x86_i8042_handler_install(void)
  function x86_i8042_handler_register (line 80) | void x86_i8042_handler_register(int channel, void (*fun)(int))
  function x86_i8042_reboot (line 92) | void x86_i8042_reboot(void)
  function x86_i8042_setup (line 97) | int x86_i8042_setup(struct ioaddr *io)

FILE: kernel/arch/i386/platform/misc/pic.c
  type ioaddr (line 24) | struct ioaddr
  type ioaddr (line 25) | struct ioaddr
  function x86_irq_mask (line 86) | void x86_irq_mask(int irq)
  function x86_irq_unmask (line 99) | void x86_irq_unmask(int irq)
  function x86_irq_remap (line 113) | static void x86_irq_remap(void)
  function x86_irq_handler_install (line 149) | void x86_irq_handler_install(unsigned irq, x86_irq_handler_t handler)
  function x86_irq_handler_uninstall (line 157) | void x86_irq_handler_uninstall(unsigned irq)
  function x86_irq_ack (line 166) | static void x86_irq_ack(uint32_t irq_no)
  function __x86_irq_handler (line 174) | void __x86_irq_handler(struct x86_regs *r)
  function x86_irq_gates_setup (line 191) | static void x86_irq_gates_setup(void)
  function x86_pic_probe (line 211) | static int x86_pic_probe(void)
  function x86_pic_disable (line 226) | void x86_pic_disable(void)
  function x86_pic_setup (line 233) | int x86_pic_setup(struct ioaddr *_master, struct ioaddr *_slave)

FILE: kernel/arch/i386/platform/misc/pit.c
  type ioaddr (line 7) | struct ioaddr
  type pit_cmd_register (line 12) | struct pit_cmd_register {
  function x86_pit_setup (line 28) | int x86_pit_setup(struct ioaddr *io)
  function atou32 (line 37) | static uint32_t atou32(const char *s)
  function x86_pit_period_set (line 49) | uint32_t x86_pit_period_set(uint32_t period_ns)

FILE: kernel/arch/i386/platform/pc/init.c
  function x86_pc_pic_init (line 23) | static int x86_pc_pic_init(void)
  function x86_pc_pci_init (line 36) | static void x86_pc_pci_init(void)
  function x86_pc_i8042_init (line 48) | static int x86_pc_i8042_init(void)
  function x86_pc_pit_init (line 58) | static int x86_pc_pit_init(void)
  function x86_pc_cmos_init (line 68) | static int x86_pc_cmos_init(void)
  function platform_timer_setup (line 78) | uint32_t platform_timer_setup(size_t period_ns, void (*handler)())
  function platform_init (line 85) | int platform_init(void)

FILE: kernel/arch/i386/platform/pc/reboot.c
  function platform_reboot (line 5) | void platform_reboot(void)
  function arch_reboot (line 10) | void arch_reboot(void)

FILE: kernel/arch/i386/platform/quark/include/chipset/legacy_bridge.h
  type pci_dev (line 6) | struct pci_dev

FILE: kernel/arch/i386/platform/quark/init.c
  function quark_pic_setup (line 14) | int quark_pic_setup()
  function quark_pci_init (line 27) | void quark_pci_init()
  type pci_dev (line 48) | struct pci_dev
  type ioaddr (line 49) | struct ioaddr
  function quark_hsuart_setup (line 54) | void quark_hsuart_setup()
  function chipset_timer_setup (line 86) | void chipset_timer_setup(size_t period_ns, void (*handler)())
  function chipset_init (line 93) | int chipset_init()

FILE: kernel/arch/i386/platform/quark/legacy/bridge.c
  type pci_dev (line 9) | struct pci_dev
  function quark_legacy_bridge_setup (line 11) | void quark_legacy_bridge_setup()

FILE: kernel/arch/i386/platform/quark/legacy/interrupt.c
  function quark_interrupt_decoder_setup (line 3) | void quark_interrupt_decoder_setup()

FILE: kernel/arch/i386/platform/quark/legacy/root_complex.c
  type ioaddr (line 14) | struct ioaddr
  function quark_root_complex_io_fabric_route (line 20) | void quark_root_complex_io_fabric_route(int intr_pin, int irq)
  function quark_root_complex_init (line 59) | void quark_root_complex_init()

FILE: kernel/arch/i386/sys/execve.c
  function arch_sys_execve (line 6) | void arch_sys_execve(struct proc *proc, int argc, char * const _argp[], ...

FILE: kernel/arch/i386/sys/fork.c
  function arch_proc_fork (line 10) | int arch_proc_fork(struct thread *thread, struct proc *fork)

FILE: kernel/arch/i386/sys/proc.c
  function arch_proc_init (line 10) | void arch_proc_init(struct proc *proc)
  function arch_init_execve (line 39) | void arch_init_execve(struct proc *proc, int argc, char * const _argp[],...

FILE: kernel/arch/i386/sys/sched.c
  function arch_rtime_ns (line 13) | uint64_t arch_rtime_ns(void)
  function arch_rtime_us (line 18) | uint64_t arch_rtime_us(void)
  function arch_rtime_ms (line 23) | uint64_t arch_rtime_ms(void)
  function x86_sched_handler (line 30) | static void x86_sched_handler(struct x86_regs *r)
  function arch_sched_init (line 92) | void arch_sched_init(void)
  function __arch_idle (line 97) | static void __arch_idle(void)
  function arch_idle (line 106) | void arch_idle(void)
  function __arch_cur_thread_kill (line 117) | static void __arch_cur_thread_kill(void)
  function arch_cur_thread_kill (line 125) | void arch_cur_thread_kill(void)
  function arch_sleep (line 133) | void arch_sleep(void)

FILE: kernel/arch/i386/sys/signal.c
  function arch_handle_signal (line 8) | void arch_handle_signal(int sig)

FILE: kernel/arch/i386/sys/syscall.c
  type x86_regs (line 8) | struct x86_regs
  function arch_syscall_return (line 30) | void arch_syscall_return(struct thread *thread, uintptr_t val)

FILE: kernel/arch/i386/sys/thread.c
  function arch_thread_spawn (line 19) | void arch_thread_spawn(struct thread *thread)
  function arch_thread_switch (line 35) | void arch_thread_switch(struct thread *thread)
  function arch_thread_create (line 60) | void arch_thread_create(struct thread *thread, uintptr_t stack, uintptr_...
  function arch_thread_kill (line 100) | void arch_thread_kill(struct thread *thread)
  function internal_arch_sleep (line 123) | void internal_arch_sleep()

FILE: kernel/arch/none/include/core/types.h
  type paddr_t (line 4) | typedef uintptr_t paddr_t;
  type vaddr_t (line 5) | typedef uintptr_t vaddr_t;

FILE: kernel/arch/none/include/cpu/io.h
  function io_in8 (line 6) | static inline uint8_t io_in8(struct ioaddr *io, uintptr_t off)
  function io_in16 (line 11) | static inline uint16_t io_in16(struct ioaddr *io, uintptr_t off)
  function io_in32 (line 16) | static inline uint32_t io_in32(struct ioaddr *io, uintptr_t off)
  function io_out8 (line 21) | static inline void io_out8(struct ioaddr *io, uintptr_t off, uint8_t val)
  function io_out16 (line 25) | static inline void io_out16(struct ioaddr *io, uintptr_t off, uint16_t val)
  function io_out32 (line 29) | static inline void io_out32(struct ioaddr *io, uintptr_t off, uint32_t val)

FILE: kernel/core/kargs.c
  function kargs_parse (line 13) | int kargs_parse(const char *_cmdline)
  function kargs_get (line 44) | int kargs_get(const char *key, const char **value)

FILE: kernel/core/main.c
  function kmain (line 34) | void kmain(struct boot *boot)

FILE: kernel/core/module.c
  function modules_init (line 8) | int modules_init(void)

FILE: kernel/core/printk.c
  type ringbuf (line 8) | struct ringbuf
  type queue (line 9) | struct queue
  function earlycon_disable (line 12) | void earlycon_disable()
  function putc (line 17) | static int putc(char c)
  function puts (line 26) | static int puts(char *s)
  function putx (line 39) | static int putx(uint32_t val)
  function putlx (line 57) | static int putlx(uint64_t val)
  function putud (line 70) | static int putud(uint32_t val)
  function putul (line 83) | static int putul(uint64_t val)
  function putb (line 96) | static int putb(uint8_t val)
  function vprintk (line 108) | int vprintk(const char *fmt, va_list args)
  function printk (line 165) | int printk(const char *fmt, ...)

FILE: kernel/core/snprintf.c
  function snputc (line 3) | static int snputc(char *s, size_t n, char c)
  function snputs (line 13) | static int snputs(char *s, size_t n, char *str)
  function snputx (line 21) | static int snputx(char *s, size_t n, uint32_t val)
  function snputlx (line 39) | static int snputlx(char *s, size_t n, uint64_t val)
  function snputud (line 55) | static int snputud(char *s, size_t n, uint32_t val)
  function snputul (line 76) | static int snputul(char *s, size_t n, uint64_t val)
  function snputb (line 93) | static int snputb(char *s, size_t n, uint8_t val)
  function vsnprintf (line 110) | int vsnprintf(char *s, size_t n, const char *fmt, va_list args)
  function snprintf (line 163) | int snprintf(char *s, size_t n, const char *fmt, ...)

FILE: kernel/core/time.c
  function gettime (line 6) | int gettime(struct timespec *ts)
  function gettimeofday (line 11) | int gettimeofday(struct timeval *tv, struct timezone *tz)

FILE: kernel/dev/ata/ata.c
  type ata_drive (line 23) | struct ata_drive
  function ata_select_drive (line 25) | void ata_select_drive(struct ata_drive *drive, uint32_t mode)
  function ata_partition_offset (line 49) | static size_t ata_partition_offset(struct ata_drive *drive, size_t part)
  function ata_read (line 68) | static ssize_t ata_read(struct devid *dd, off_t offset, size_t size, voi...
  function ata_write (line 82) | static ssize_t ata_write(struct devid *dd, off_t offset, size_t size, vo...
  function ata_detect_drive (line 95) | static uint8_t ata_detect_drive(struct ata_drive *drive)
  function ata_getbs (line 197) | static size_t ata_getbs(struct devid *dd __unused)
  function ata_probe (line 202) | static int ata_probe()
  type dev (line 310) | struct dev

FILE: kernel/dev/ata/ata.h
  type ata_drive (line 92) | struct ata_drive {
  function ata_wait (line 128) | static void ata_wait(struct ata_drive *drive)
  function ata_poll (line 134) | static int ata_poll(struct ata_drive *drive, int advanced_check)
  function ata_soft_reset (line 160) | static void ata_soft_reset(struct ata_drive *drive)
  type ata_drive (line 168) | struct ata_drive
  type ata_drive (line 171) | struct ata_drive

FILE: kernel/dev/ata/pio.c
  function pio_read (line 16) | static ssize_t pio_read(struct ata_drive *drive, uint64_t lba, size_t co...
  function pio_write (line 96) | static ssize_t pio_write(struct ata_drive *drive, uint64_t lba, size_t c...
  function pio_init (line 135) | void pio_init(struct ata_drive *drive)

FILE: kernel/dev/fb/fbdev/fbdev.c
  type fbdev (line 13) | struct fbdev
  function fbdev_register (line 16) | int fbdev_register(int type, void *data)
  function fbdev_read (line 27) | static ssize_t fbdev_read(struct devid *dd, off_t offset, size_t size, v...
  function fbdev_write (line 33) | static ssize_t fbdev_write(struct devid *dd, off_t offset, size_t size, ...
  function fbdev_ioctl (line 39) | static int fbdev_ioctl(struct devid *dd, int request, void *argp)
  function fbdev_map (line 55) | static int fbdev_map(struct devid *dd, struct vm_space *vm_space, struct...
  function fbdev_probe (line 61) | int fbdev_probe()
  type dev (line 77) | struct dev

FILE: kernel/dev/fb/vesa/vesa.c
  type vm_entry (line 9) | struct vm_entry
  type fb_fix_screeninfo (line 15) | struct fb_fix_screeninfo
  type fb_var_screeninfo (line 19) | struct fb_var_screeninfo
  function fbdev_vesa_write (line 21) | static ssize_t fbdev_vesa_write(struct fbdev *fb, off_t offset, size_t s...
  function fbdev_vesa_map (line 32) | static int fbdev_vesa_map(struct fbdev *fb, struct vm_space *vm_space, s...
  function fbdev_vesa_prope (line 50) | static int fbdev_vesa_prope(int i __unused, struct fbdev *fb)
  type fbdev (line 125) | struct fbdev

FILE: kernel/dev/fdc/fdc.c
  type dev (line 9) | struct dev
  function fdc_probe (line 11) | int fdc_probe()
  type dev (line 17) | struct dev

FILE: kernel/dev/fdc/fdc_82077AA.c
  type dev (line 11) | struct dev
  type ioaddr (line 12) | struct ioaddr
  type fdc_drive (line 17) | struct fdc_drive {
  function fdc_wait (line 21) | static int fdc_wait(int check_dio)
  function fdc_cmd_send (line 37) | static int fdc_cmd_send(uint8_t cmd, int argc, const uint8_t argv[], int...
  function fdc_cmd_version (line 88) | static int fdc_cmd_version()
  function fdc_cmd_sense (line 96) | static int fdc_cmd_sense()
  function fdc_reset (line 105) | static int fdc_reset()
  function fdc_configure (line 121) | static int fdc_configure()
  function fdc_lock (line 128) | static int fdc_lock()
  function fdc_recalibrate (line 135) | static int fdc_recalibrate()
  function fdc_sect_rw (line 143) | static int fdc_sect_rw(int wr, size_t lba, void *_buf)
  function fdc_probe (line 217) | static int fdc_probe()
  function fdc_getbs (line 242) | static size_t fdc_getbs(struct devid *dd __unused)
  function fdc_read (line 247) | static ssize_t fdc_read(struct devid *dd, off_t offset, size_t size, voi...
  type dev (line 254) | struct dev

FILE: kernel/dev/kbd/kbd.c
  type keyboard (line 12) | struct keyboard
  type proc (line 14) | struct proc
  function ps2kbd_handler (line 16) | static void ps2kbd_handler(int scancode)
  function ps2kbd_register (line 24) | static void ps2kbd_register(void)
  function kbddev_read (line 29) | static ssize_t kbddev_read(struct devid *dd, off_t off, size_t sz, void ...
  function kbddev_write (line 50) | static ssize_t kbddev_write(struct devid *dd, off_t off, size_t sz, void...
  function kbddev_probe (line 65) | static int kbddev_probe(void)
  function kbddev_file_open (line 72) | static int kbddev_file_open(struct file *file)
  function keyboard_register (line 85) | int keyboard_register(struct keyboard *keyboard)
  type dev (line 89) | struct dev

FILE: kernel/dev/kbd/ps2kbd.c
  type ringbuf (line 33) | struct ringbuf
  type proc (line 34) | struct proc
  type queue (line 35) | struct queue
  function ps2kbd_handler (line 37) | static void ps2kbd_handler(int scancode)
  function ps2kbd_register (line 45) | static void ps2kbd_register(void)
  function ps2kbd_read (line 50) | static ssize_t ps2kbd_read(struct devid *dd, off_t off, size_t sz, void ...
  function ps2kbd_probe (line 58) | static int ps2kbd_probe(void)
  function ps2kbd_file_open (line 66) | static int ps2kbd_file_open(struct file *file)
  function ps2kbd_file_can_read (line 79) | static int ps2kbd_file_can_read(struct file *file, size_t size)
  type dev (line 88) | struct dev

FILE: kernel/dev/kdev.c
  type dev (line 12) | struct dev
  type dev (line 13) | struct dev
  type dev (line 15) | struct dev
  type devid (line 15) | struct devid
  type dev (line 17) | struct dev
  function kdev_close (line 35) | int kdev_close(struct devid *dev __unused)
  function kdev_bread (line 40) | ssize_t kdev_bread(struct devid *dd, off_t offset, size_t size, void *buf)
  function kdev_bwrite (line 118) | ssize_t kdev_bwrite(struct devid *dd, off_t offset, size_t size, void *buf)
  function kdev_read (line 184) | ssize_t kdev_read(struct devid *dd, off_t offset, size_t size, void *buf)
  function kdev_write (line 202) | ssize_t kdev_write(struct devid *dd, off_t offset, size_t size, void *buf)
  function kdev_ioctl (line 218) | int kdev_ioctl(struct devid *dd, int request, void *argp)
  function kdev_map (line 231) | int kdev_map(struct devid *dd, struct vm_space *vm_space, struct vm_entr...
  function kdev_file_open (line 244) | int kdev_file_open(struct devid *dd, struct file *file)
  function kdev_file_read (line 257) | ssize_t kdev_file_read(struct devid *dd, struct file *file, void *buf, s...
  function kdev_file_write (line 270) | ssize_t kdev_file_write(struct devid *dd, struct file *file, void *buf, ...
  function off_t (line 283) | off_t kdev_file_lseek(struct devid *dd, struct file *file, off_t offset,...
  function kdev_file_close (line 296) | ssize_t kdev_file_close(struct devid *dd, struct file *file)
  function kdev_file_ioctl (line 309) | int kdev_file_ioctl(struct devid *dd, struct file *file, int request, vo...
  function kdev_file_can_read (line 322) | int kdev_file_can_read(struct devid *dd, struct file * file, size_t size)
  function kdev_file_can_write (line 335) | int kdev_file_can_write(struct devid *dd, struct file * file, size_t size)
  function kdev_file_eof (line 348) | int kdev_file_eof(struct devid *dd, struct file *file)
  function kdev_chrdev_register (line 365) | void kdev_chrdev_register(devid_t major, struct dev *dev)
  function kdev_blkdev_register (line 375) | void kdev_blkdev_register(devid_t major, struct dev *dev)
  function kdev_init (line 385) | void kdev_init()

FILE: kernel/dev/mem/kmsg.c
  type dev (line 10) | struct dev
  type ringbuf (line 11) | struct ringbuf
  type queue (line 12) | struct queue
  function kmsgdev_read (line 14) | static ssize_t kmsgdev_read(struct devid *dd __unused, off_t offset, siz...
  function kmsgdev_write (line 20) | static ssize_t kmsgdev_write(struct devid *dd __unused, off_t offset, si...
  function kmsg_file_open (line 35) | static int kmsg_file_open(struct file *file)
  type dev (line 41) | struct dev

FILE: kernel/dev/mem/memdev.c
  type dev (line 7) | struct dev
  type dev (line 9) | struct dev
  type devid (line 9) | struct devid
  function memdev_probe (line 40) | int memdev_probe()
  type dev (line 46) | struct dev

FILE: kernel/dev/mem/memdev.h
  type dev (line 6) | struct dev
  type dev (line 8) | struct dev
  type dev (line 9) | struct dev

FILE: kernel/dev/mem/null.c
  type dev (line 8) | struct dev
  function nulldev_read (line 10) | static ssize_t nulldev_read(struct devid *dd __unused, off_t offset __un...
  function nulldev_write (line 15) | static ssize_t nulldev_write(struct devid *dd __unused, off_t offset __u...
  type dev (line 20) | struct dev

FILE: kernel/dev/mem/zero.c
  type dev (line 8) | struct dev
  function zerodev_read (line 10) | static ssize_t zerodev_read(struct devid *dd __unused, off_t offset __un...
  function zerodev_write (line 16) | static ssize_t zerodev_write(struct devid *dd __unused, off_t offset __u...
  type dev (line 21) | struct dev

FILE: kernel/dev/mouse/ps2mouse.c
  type dev (line 32) | struct dev
  type ioaddr (line 34) | struct ioaddr
  type ringbuf (line 51) | struct ringbuf
  type proc (line 52) | struct proc
  type queue (line 53) | struct queue
  type mouse_packet (line 55) | struct mouse_packet {
  function ps2mouse_handler (line 66) | void ps2mouse_handler(int byte)
  function ps2mouse_register (line 89) | void ps2mouse_register(void)
  function ps2mouse_read (line 94) | static ssize_t ps2mouse_read(struct devid *dd __unused, off_t offset __u...
  function __mouse_wait (line 99) | static void __mouse_wait(uint32_t i)
  function __mouse_read (line 111) | static uint8_t __mouse_read(void)
  function __mouse_write (line 117) | static void __mouse_write(uint8_t chr)
  function ps2mouse_probe (line 125) | int ps2mouse_probe()
  function ps2mouse_file_open (line 154) | static int ps2mouse_file_open(struct file *file)
  function ps2mouse_file_can_read (line 165) | static int ps2mouse_file_can_read(struct file *file, size_t size)
  function ps2mouse_file_close (line 171) | static int ps2mouse_file_close(struct file *file)
  type dev (line 178) | struct dev

FILE: kernel/dev/pci/pci.c
  type ioaddr (line 7) | struct ioaddr
  function pci_read_dword (line 9) | static inline uint32_t pci_read_dword(uint8_t bus, uint8_t dev, uint8_t ...
  function pci_write_dword (line 24) | static inline void pci_write_dword(uint8_t bus, uint8_t dev, uint8_t fun...
  function get_vendor_id (line 39) | static inline uint16_t get_vendor_id(uint8_t bus, uint8_t dev, uint8_t f...
  function get_device_id (line 44) | static inline uint16_t get_device_id(uint8_t bus, uint8_t dev, uint8_t f...
  function get_class_code (line 49) | static inline uint8_t get_class_code(uint8_t bus, uint8_t dev, uint8_t f...
  function get_subclass_code (line 54) | static inline uint8_t get_subclass_code(uint8_t bus, uint8_t dev, uint8_...
  function get_header_type (line 59) | static inline uint8_t get_header_type(uint8_t bus, uint8_t dev, uint8_t ...
  function get_bar (line 64) | static inline uint32_t get_bar(uint8_t bus, uint8_t dev, uint8_t func, u...
  function pci_device_scan (line 69) | int pci_device_scan(uint16_t vendor_id, uint16_t device_id, struct pci_d...
  function pci_reg8_read (line 94) | uint8_t pci_reg8_read(struct pci_dev *dev, uint8_t off)
  function pci_reg16_read (line 99) | uint16_t pci_reg16_read(struct pci_dev *dev, uint8_t off)
  function pci_reg32_read (line 104) | uint32_t pci_reg32_read(struct pci_dev *dev, uint8_t off)
  function pci_reg8_write (line 109) | void pci_reg8_write(struct pci_dev *dev, uint8_t off, uint8_t val)
  function pci_reg16_write (line 116) | void pci_reg16_write(struct pci_dev *dev, uint8_t off, uint8_t val)
  function pci_reg32_write (line 123) | void pci_reg32_write(struct pci_dev *dev, uint8_t off, uint8_t val)
  function scan_device (line 128) | static void scan_device(uint8_t bus, uint8_t dev)
  function scan_bus (line 146) | static void scan_bus(uint8_t bus)
  function pci_prope (line 153) | int pci_prope()
  type dev (line 159) | struct dev
  function pci_ioaddr_set (line 166) | void pci_ioaddr_set(struct ioaddr *io)
  function pci_scan_device (line 176) | int pci_scan_device(uint8_t class, uint8_t subclass, struct pci_dev *_de...
  function pci_read_bar (line 206) | uint32_t pci_read_bar(struct pci_dev *dev, uint8_t id)

FILE: kernel/dev/rd/ramdisk.c
  function rd_read (line 11) | static ssize_t rd_read(struct devid *dd __unused, off_t offset, size_t s...
  function rd_write (line 22) | static ssize_t rd_write(struct devid *dd __unused, off_t offset, size_t ...
  function rd_probe (line 33) | static int rd_probe()
  function rd_getbs (line 45) | static size_t rd_getbs(struct devid *dd __unused)
  type dev (line 50) | struct dev

FILE: kernel/dev/tty/console/console.c
  type ioaddr (line 28) | struct ioaddr
  function scroll (line 33) | static void scroll(int n)
  function set_cursor (line 44) | static void set_cursor(unsigned pos)
  function console_write (line 53) | static ssize_t console_write(struct devid *dd __unused, off_t offset __u...
  function console_probe (line 87) | static int console_probe()
  type dev (line 92) | struct dev

FILE: kernel/dev/tty/generic.c
  function tty_master_write (line 8) | ssize_t tty_master_write(struct tty *tty, size_t size, void *buf)
  function tty_slave_write (line 82) | ssize_t tty_slave_write(struct tty *tty, size_t size, void *_buf)
  function tty_ioctl (line 134) | int tty_ioctl(struct tty *tty, int request, void *argp)
  function tty_new (line 172) | int tty_new(struct proc *proc, size_t buf_size, ttyio master,
  function tty_free (line 220) | int tty_free(struct tty *tty)

FILE: kernel/dev/tty/pty/pty.c
  type pty (line 18) | struct pty {
  type pty (line 40) | struct pty
  type dev (line 42) | struct dev
  type dev (line 43) | struct dev
  function pty_master_write (line 46) | ssize_t pty_master_write(struct tty *tty, size_t size, void *buf)
  function pty_slave_write (line 64) | ssize_t pty_slave_write(struct tty *tty, size_t size, void *buf)
  function ptm_new (line 88) | static int ptm_new(struct pty *pty, struct vnode **ref)
  function ptm_read (line 108) | static ssize_t ptm_read(struct devid *dd, off_t offset __unused, size_t ...
  function ptm_write (line 118) | static ssize_t ptm_write(struct devid *dd, off_t offset __unused, size_t...
  function pty_ioctl (line 124) | static int pty_ioctl(struct devid *dd, int request, void *argp)
  function pts_new (line 146) | static int pts_new(struct pty *pty, struct vnode **ref)
  function pts_read (line 170) | ssize_t pts_read(struct devid *dd, off_t offset __unused, size_t size, v...
  function pts_write (line 177) | ssize_t pts_write(struct devid *dd, off_t offset __unused, size_t size, ...
  function pts_can_read (line 184) | int pts_can_read(struct file *file, size_t size)
  function pty_id_get (line 197) | static inline size_t pty_id_get(void)
  function pty_new (line 204) | int pty_new(struct proc *proc, struct vnode **master)
  function ptmx_open (line 259) | int ptmx_open(struct file *file)
  function pty_init (line 264) | int pty_init()
  type dev (line 274) | struct dev
  type dev (line 292) | struct dev

FILE: kernel/dev/tty/tty.c
  type dev (line 12) | struct dev
  type devid (line 12) | struct devid
  type dev (line 23) | struct dev
  type devid (line 23) | struct devid
  function ttydev_probe (line 37) | int ttydev_probe()
  type dev (line 44) | struct dev
  type dev (line 49) | struct dev

FILE: kernel/dev/tty/uart/8250/8250.c
  type uart (line 22) | struct uart
  type ioaddr (line 23) | struct ioaddr
  function serial_empty (line 36) | static int serial_empty(void)
  function serial_received (line 41) | static int serial_received(void)
  function uart_8250_receive (line 46) | char uart_8250_receive(struct uart *u __unused)
  function uart_8250_transmit (line 51) | ssize_t uart_8250_transmit(struct uart *u __unused, char c)
  function uart_8250_irq (line 57) | void uart_8250_irq()
  function uart_8250_comm_init (line 70) | void uart_8250_comm_init(struct uart *u __unused)
  function uart_8250_init (line 90) | int uart_8250_init()
  type uart (line 143) | struct uart

FILE: kernel/dev/tty/uart/uart.c
  type uart (line 11) | struct uart
  function uart_recieve_handler (line 14) | void uart_recieve_handler(struct uart *u, size_t size)
  function uart_transmit_handler (line 27) | void uart_transmit_handler(struct uart *u, size_t size)
  function uart_master_write (line 42) | ssize_t uart_master_write(struct tty *tty, size_t size, void *buf)
  function uart_slave_write (line 50) | ssize_t uart_slave_write(struct tty *tty, size_t size, void *buf)
  function uart_read (line 56) | ssize_t uart_read(struct devid *dd, off_t offset __unused, size_t size, ...
  function uart_write (line 63) | ssize_t uart_write(struct devid *dd, off_t offset __unused, size_t size,...
  function uart_ioctl (line 70) | int uart_ioctl(struct devid *dd, int request, void *argp)
  function uart_file_open (line 77) | int uart_file_open(struct file *file)
  function uart_register (line 100) | int uart_register(int id, struct uart *u)
  type dev (line 121) | struct dev

FILE: kernel/fs/bcache.c
  type cache_block (line 11) | struct cache_block {
  function bcache_eq (line 18) | static int bcache_eq(void *_a, void *_b)
  function bcache_init (line 26) | void bcache_init(struct bcache *bcache)
  function bcache_insert (line 31) | int bcache_insert(struct bcache *bcache, uint64_t off, void *data)
  function bcache_remove (line 49) | int bcache_remove(struct bcache *bcache, uint64_t off)
  type bcache (line 69) | struct bcache
  type hashmap_node (line 76) | struct hashmap_node
  type cache_block (line 79) | struct cache_block
  type cache_block (line 79) | struct cache_block
  function bcache_dirty (line 86) | void bcache_dirty(struct bcache *bcache, uint64_t off)

FILE: kernel/fs/close.c
  function vfs_close (line 9) | int vfs_close(struct vnode *vnode)

FILE: kernel/fs/devfs/devfs.c
  type vnode (line 23) | struct vnode
  function devfs_init (line 25) | static int devfs_init()
  function devfs_mount (line 52) | static int devfs_mount(const char *dir, int flags, void *data)
  type fs (line 60) | struct fs

FILE: kernel/fs/devpts/devpts.c
  type vnode (line 10) | struct vnode
  function devpts_init (line 12) | int devpts_init()
  function devpts_mount (line 46) | int devpts_mount(const char *dir, int flags, void *data)
  type fs (line 54) | struct fs

FILE: kernel/fs/ext2/block.c
  function ext2_bgd_table_rewrite (line 4) | void ext2_bgd_table_rewrite(struct ext2 *desc)
  type ext2 (line 11) | struct ext2
  type ext2 (line 17) | struct ext2
  function ext2_block_alloc (line 23) | uint32_t ext2_block_alloc(struct ext2 *desc)
  function ext2_block_free (line 71) | void ext2_block_free(struct ext2 *desc, uint32_t block)

FILE: kernel/fs/ext2/dentry.c
  function ino_t (line 4) | ino_t ext2_dentry_find(struct ext2 *desc, struct ext2_inode *inode, cons...
  function ext2_dentry_type (line 37) | static inline uint8_t ext2_dentry_type(mode_t mode)
  function ext2_dentry_create (line 51) | int ext2_dentry_create(struct vnode *dir, const char *name, ino_t ino, m...

FILE: kernel/fs/ext2/ext2.c
  function ext2_inode_build (line 19) | int ext2_inode_build(struct ext2 *desc, ino_t ino, struct vnode **ref_in...
  function ext2_inode_sync (line 67) | int ext2_inode_sync(struct vnode *inode)
  function ext2_init (line 99) | int ext2_init()
  function ext2_load (line 104) | int ext2_load(struct vnode *dev, struct vnode **super)
  function ext2_mount (line 163) | int ext2_mount(const char *dir, int flags, void *_args)
  type fs (line 191) | struct fs

FILE: kernel/fs/ext2/ext2.h
  type ext2_optional_features_flags (line 9) | struct ext2_optional_features_flags {
  type ext2_required_features_flags (line 18) | struct ext2_required_features_flags {
  type ext2_read_only_features_flags (line 25) | struct ext2_read_only_features_flags {
  type ext2_superblock (line 31) | struct ext2_superblock {
  type ext2_group (line 98) | struct ext2_group {
  type ext2_inode (line 117) | struct ext2_inode {
  type ext2_dentry (line 147) | struct ext2_dentry {
  type ext2 (line 175) | struct ext2 {
  type fs (line 187) | struct fs
  type ext2 (line 190) | struct ext2
  type ext2 (line 193) | struct ext2
  type ext2 (line 194) | struct ext2
  type ext2 (line 195) | struct ext2
  type ext2 (line 196) | struct ext2
  type ext2 (line 197) | struct ext2
  type ext2 (line 200) | struct ext2
  type ext2_inode (line 200) | struct ext2_inode
  type ext2 (line 201) | struct ext2
  type ext2_inode (line 201) | struct ext2_inode
  type ext2 (line 203) | struct ext2
  type ext2_inode (line 203) | struct ext2_inode
  type ext2 (line 204) | struct ext2
  type ext2_inode (line 204) | struct ext2_inode
  type ext2 (line 205) | struct ext2
  type ext2 (line 208) | struct ext2
  type ext2_inode (line 208) | struct ext2_inode
  type vnode (line 209) | struct vnode
  type vnode (line 212) | struct vnode
  type vnode (line 213) | struct vnode
  type vnode (line 214) | struct vnode
  type dirent (line 214) | struct dirent
  type vnode (line 215) | struct vnode
  type dirent (line 215) | struct dirent
  type vnode (line 217) | struct vnode
  type vnode (line 218) | struct vnode
  type uio (line 218) | struct uio
  type vnode (line 218) | struct vnode
  type vnode (line 220) | struct vnode
  type vnode (line 220) | struct vnode
  type ext2 (line 222) | struct ext2
  type vnode (line 222) | struct vnode
  type vnode (line 223) | struct vnode

FILE: kernel/fs/ext2/inode.c
  function off_t (line 5) | static inline off_t ext2_inode_off(struct ext2 *desc, ino_t ino)
  function ext2_inode_read (line 18) | int ext2_inode_read(struct ext2 *desc, ino_t ino, struct ext2_inode *ref)
  function ext2_inode_write (line 41) | int ext2_inode_write(struct ext2 *desc, ino_t ino, struct ext2_inode *ex...
  function ext2_inode_block_read (line 52) | size_t ext2_inode_block_read(struct ext2 *desc, struct ext2_inode *inode...
  function ext2_inode_block_write (line 100) | size_t ext2_inode_block_write(struct ext2 *desc, struct ext2_inode *inod...
  function ino_t (line 134) | ino_t ext2_inode_alloc(struct ext2 *desc)

FILE: kernel/fs/ext2/super.c
  function ext2_superblock_rewrite (line 3) | void ext2_superblock_rewrite(struct ext2 *desc)

FILE: kernel/fs/ext2/vops.c
  function ext2_read (line 4) | ssize_t ext2_read(struct vnode *node, off_t offset, size_t size, void *buf)
  function ext2_write (line 79) | ssize_t ext2_write(struct vnode *node, off_t offset, size_t size, void *...
  function ext2_readdir (line 160) | ssize_t ext2_readdir(struct vnode *dir, off_t offset, struct dirent *dir...
  function ext2_trunc (line 209) | int ext2_trunc(struct vnode *inode, off_t len)
  function ext2_vmknod (line 230) | int ext2_vmknod(struct vnode *dir, const char *fn, mode_t mode, dev_t de...
  function ext2_finddir (line 298) | int ext2_finddir(struct vnode *dir, const char *fn, struct dirent *dirent)
  function ext2_vget (line 327) | int ext2_vget(struct vnode *super, ino_t ino, struct vnode **ref)

FILE: kernel/fs/fops.c
  function vfs_file_open (line 11) | int vfs_file_open(struct file *file)
  function vfs_file_read (line 32) | ssize_t vfs_file_read(struct file *file, void *buf, size_t nbytes)
  function vfs_file_write (line 56) | ssize_t vfs_file_write(struct file *file, void *buf, size_t nbytes)
  function vfs_file_ioctl (line 80) | int vfs_file_ioctl(struct file *file, int request, void *argp)
  function off_t (line 101) | off_t vfs_file_lseek(struct file *file, off_t offset, int whence)
  function vfs_file_readdir (line 122) | ssize_t vfs_file_readdir(struct file *file, struct dirent *dirent)
  function vfs_file_close (line 140) | ssize_t vfs_file_close(struct file *file)
  function vfs_file_trunc (line 164) | int vfs_file_trunc(struct file *file, off_t len)
  function vfs_file_can_read (line 184) | int vfs_file_can_read(struct file *file, size_t size)
  function vfs_file_can_write (line 204) | int vfs_file_can_write(struct file *file, size_t size)
  function vfs_file_eof (line 224) | int vfs_file_eof(struct file *file)

FILE: kernel/fs/initramfs/cpio/cpio.c
  function cpio_root_node (line 15) | static int cpio_root_node(struct vnode *super, struct vnode **ref)
  function cpio_new_node (line 71) | static int cpio_new_node(const char *name, struct cpio_hdr *hdr, size_t ...
  type vnode (line 122) | struct vnode
  type vnode (line 122) | struct vnode
  type vnode (line 122) | struct vnode
  type cpio (line 130) | struct cpio
  type cpio (line 130) | struct cpio
  type cpio (line 131) | struct cpio
  type cpio (line 131) | struct cpio
  type vnode (line 133) | struct vnode
  type vnode (line 144) | struct vnode
  type vnode (line 144) | struct vnode
  type vnode (line 151) | struct vnode
  type vnode (line 152) | struct vnode
  type cpio (line 152) | struct cpio
  type vnode (line 166) | struct vnode
  type cpio (line 166) | struct cpio
  type cpio (line 167) | struct cpio
  type cpio (line 168) | struct cpio
  type cpio (line 170) | struct cpio
  function cpio_finddir (line 189) | static int cpio_finddir(struct vnode *root, const char *name, struct dir...
  function cpio_vget (line 214) | static int cpio_vget(struct vnode *super, ino_t ino, struct vnode **vnode)
  function cpio_load (line 222) | static int cpio_load(struct vnode *dev, struct vnode **super)
  function cpio_read (line 286) | static ssize_t cpio_read(struct vnode *vnode, off_t offset, size_t len, ...
  function cpio_readdir (line 298) | static ssize_t cpio_readdir(struct vnode *node, off_t offset, struct dir...
  function cpio_close (line 332) | static int cpio_close(struct vnode *vnode)
  function cpio_eof (line 337) | static int cpio_eof(struct file *file)
  function cpio_init (line 346) | static int cpio_init()
  type fs (line 351) | struct fs

FILE: kernel/fs/initramfs/cpio/cpio.h
  type cpio_hdr (line 13) | struct cpio_hdr {
  type cpio (line 31) | struct cpio {
  type fs (line 42) | struct fs

FILE: kernel/fs/initramfs/initramfs.c
  type vnode (line 26) | struct vnode
  type queue (line 27) | struct queue
  function initramfs_archiver_register (line 29) | int initramfs_archiver_register(struct fs *fs)
  function load_ramdisk (line 39) | int load_ramdisk(module_t *module)

FILE: kernel/fs/ioctl.c
  function vfs_ioctl (line 5) | int vfs_ioctl(struct vnode *vnode, unsigned long request, void *argp)

FILE: kernel/fs/lookup.c
  function vfs_follow (line 5) | static inline int vfs_follow(struct vnode *vnode, struct uio *uio, struc...
  function vfs_lookup (line 34) | int vfs_lookup(const char *path, struct uio *uio, struct vnode **ref, ch...

FILE: kernel/fs/minix/block.c
  function blk_t (line 8) | blk_t minix_block_alloc(struct minix *desc)
  function minix_block_free (line 31) | void minix_block_free(struct minix *desc, blk_t blk)
  function minix_block_read (line 50) | ssize_t minix_block_read(struct minix *desc, blk_t blk, void *buf)
  function minix_block_write (line 59) | ssize_t minix_block_write(struct minix *desc, blk_t blk, void *buf)
  function minix_bcache_get (line 68) | int minix_bcache_get(struct minix *desc, blk_t blk, void **data)

FILE: kernel/fs/minix/dentry.c
  function minix_dentry_find (line 4) | uint32_t minix_dentry_find(struct minix *desc, struct minix_inode *m_ino...
  function minix_dentry_create (line 41) | int minix_dentry_create(struct vnode *dir, const char *name, ino_t ino, ...

FILE: kernel/fs/minix/inode.c
  function off_t (line 5) | static inline off_t minix_inode_off(struct minix *desc, ino_t ino)
  function minix_inode_read (line 14) | int minix_inode_read(struct minix *desc, ino_t ino, struct minix_inode *...
  function minix_inode_write (line 37) | int minix_inode_write(struct minix *desc, ino_t ino, struct minix_inode ...
  function minix_inode_block_read (line 60) | ssize_t minix_inode_block_read(struct minix *desc, struct minix_inode *m...
  function minix_inode_block_write (line 121) | ssize_t minix_inode_block_write(struct minix *desc, struct minix_inode *...
  function ino_t (line 157) | ino_t minix_inode_alloc(struct minix *desc)
  function minix_inode_free (line 176) | void minix_inode_free(struct minix *desc, ino_t ino)

FILE: kernel/fs/minix/minix.c
  function minix_inode_build (line 20) | int minix_inode_build(struct minix *desc, ino_t ino, struct vnode **ref)
  function minix_inode_sync (line 69) | int minix_inode_sync(struct vnode *inode)
  function minix_init (line 91) | static int minix_init()
  function minix_load (line 96) | static int minix_load(struct vnode *dev, struct vnode **super)
  function minix_mount (line 184) | static int minix_mount(const char *dir, int flags, void *_args)
  type fs (line 210) | struct fs

FILE: kernel/fs/minix/minix.h
  type minix_superblock (line 26) | struct minix_superblock {
  type minix3_superblock (line 44) | struct minix3_superblock {
  type minix_inode (line 64) | struct minix_inode {
  type minix_dentry (line 78) | struct minix_dentry {
  type minix (line 87) | struct minix {
  type fs (line 112) | struct fs
  type minix (line 115) | struct minix
  type blk_t (line 117) | typedef uint32_t blk_t;
  type minix (line 120) | struct minix
  type minix (line 121) | struct minix
  type minix (line 122) | struct minix
  type minix (line 123) | struct minix
  type minix (line 124) | struct minix
  type minix (line 127) | struct minix
  type minix (line 128) | struct minix
  type minix (line 129) | struct minix
  type minix_inode (line 129) | struct minix_inode
  type minix (line 130) | struct minix
  type minix_inode (line 130) | struct minix_inode
  type minix (line 131) | struct minix
  type minix_inode (line 131) | struct minix_inode
  type minix (line 132) | struct minix
  type minix_inode (line 132) | struct minix_inode
  type minix (line 135) | struct minix
  type minix_inode (line 135) | struct minix_inode
  type vnode (line 136) | struct vnode
  type vnode (line 139) | struct vnode
  type vnode (line 140) | struct vnode
  type vnode (line 142) | struct vnode
  type dirent (line 142) | struct dirent
  type vnode (line 143) | struct vnode
  type dirent (line 143) | struct dirent
  type vnode (line 145) | struct vnode
  type uio (line 145) | struct uio
  type vnode (line 145) | struct vnode
  type vnode (line 146) | struct vnode
  type vnode (line 146) | struct vnode
  type vnode (line 147) | struct vnode
  type minix (line 149) | struct minix
  type vnode (line 149) | struct vnode
  type vnode (line 150) | struct vnode

FILE: kernel/fs/minix/super.c
  function minix_superblock_rewrite (line 3) | void minix_superblock_rewrite(struct minix *desc)

FILE: kernel/fs/minix/vops.c
  function minix_read (line 3) | ssize_t minix_read(struct vnode *vnode, off_t offset, size_t size, void ...
  function minix_write (line 91) | ssize_t minix_write(struct vnode *vnode, off_t offset, size_t size, void...
  function minix_readdir (line 193) | ssize_t minix_readdir(struct vnode *dir, off_t off, struct dirent *dirent)
  function minix_vmknod (line 245) | int minix_vmknod(struct vnode *dir, const char *fn, mode_t mode, dev_t d...
  function minix_finddir (line 317) | int minix_finddir(struct vnode *dir, const char *fn, struct dirent *dirent)
  function minix_vget (line 345) | int minix_vget(struct vnode *super, ino_t ino, struct vnode **ref)
  function minix_trunc (line 354) | int minix_trunc(struct vnode *vnode, off_t len)

FILE: kernel/fs/mknod.c
  function vfs_mknod (line 4) | int vfs_mknod(const char *path, mode_t mode, dev_t dev, struct uio *uio,...
  function vfs_mkdir (line 64) | int vfs_mkdir(const char *path, mode_t mode, struct uio *uio, struct vno...
  function vfs_creat (line 69) | int vfs_creat(const char *path, mode_t mode, struct uio *uio, struct vno...

FILE: kernel/fs/mount.c
  type queue (line 5) | struct queue
  function vfs_mount (line 9) | int vfs_mount(const char *type, const char *dir, int flags, void *data, ...

FILE: kernel/fs/pipe.c
  function pipefs_read (line 11) | static ssize_t pipefs_read(struct vnode *node, off_t offset __unused, si...
  function pipefs_write (line 17) | static ssize_t pipefs_write(struct vnode *node, off_t offset __unused, s...
  function pipefs_can_read (line 23) | static int pipefs_can_read(struct file *file, size_t size)
  function pipefs_can_write (line 30) | static int pipefs_can_write(struct file *file, size_t size)
  function pipefs_mkpipe (line 37) | static int pipefs_mkpipe(struct pipe **ref)
  function pipefs_pfree (line 56) | static void pipefs_pfree(struct pipe *pipe)
  function pipefs_pipe (line 65) | int pipefs_pipe(struct file *read, struct file *write)
  type fs (line 108) | struct fs

FILE: kernel/fs/posix/close.c
  function posix_file_close (line 5) | int posix_file_close(struct file *file)

FILE: kernel/fs/posix/helpers.c
  function posix_file_can_read (line 3) | int posix_file_can_read(struct file *file, size_t size)
  function posix_file_can_write (line 8) | int posix_file_can_write(struct file *file, size_t size)
  function posix_file_eof (line 13) | int posix_file_eof(struct file *file)

FILE: kernel/fs/posix/ioctl.c
  function posix_file_ioctl (line 13) | int posix_file_ioctl(struct file *file, int request, void *argp)

FILE: kernel/fs/posix/lseek.c
  function posix_file_lseek (line 12) | ssize_t posix_file_lseek(struct file *file, off_t offset, int whence)

FILE: kernel/fs/posix/open.c
  function posix_file_open (line 6) | int posix_file_open(struct file *file)

FILE: kernel/fs/posix/read.c
  function posix_file_read (line 30) | ssize_t posix_file_read(struct file *file, void *buf, size_t size)

FILE: kernel/fs/posix/readdir.c
  function posix_file_readdir (line 29) | ssize_t posix_file_readdir(struct file *file, struct dirent *dirent)

FILE: kernel/fs/posix/trunc.c
  function posix_file_trunc (line 5) | int posix_file_trunc(struct file *file, off_t len)

FILE: kernel/fs/posix/write.c
  function posix_file_write (line 29) | ssize_t posix_file_write(struct file *file, void *buf, size_t size)

FILE: kernel/fs/procfs/procfs.c
  type fs (line 21) | struct fs
  type procfs_entry (line 23) | struct procfs_entry {
  type vnode (line 29) | struct vnode
  type vcache (line 30) | struct vcache
  function procfs_meminfo (line 33) | static ssize_t procfs_meminfo(off_t off, size_t size, char *buf)
  function procfs_kvmem (line 59) | static ssize_t procfs_kvmem(off_t off, size_t size, char *buf)
  function procfs_version (line 87) | static ssize_t procfs_version(off_t off, size_t size, char *buf)
  function procfs_uptime (line 109) | static ssize_t procfs_uptime(off_t off, size_t size, char *buf)
  function procfs_filesystems (line 125) | static ssize_t procfs_filesystems(off_t off, size_t size, char *buf)
  function procfs_cmdline (line 149) | static ssize_t procfs_cmdline(off_t off, size_t size, char *buf)
  function procfs_rdcmdline (line 167) | static ssize_t procfs_rdcmdline(off_t off, size_t size, char *buf)
  function procfs_mounts (line 186) | static ssize_t procfs_mounts(off_t off, size_t size, char *buf)
  function procfs_buddyinfo (line 212) | static ssize_t procfs_buddyinfo(off_t off, size_t size, char *buf)
  function procfs_devices (line 247) | static ssize_t procfs_devices(off_t off, size_t size, char *buf)
  type procfs_entry (line 283) | struct procfs_entry
  function procfs_proc_status (line 299) | static ssize_t procfs_proc_status(int pid, off_t off, size_t size, void ...
  function procfs_proc_maps (line 338) | static ssize_t procfs_proc_maps(int pid, off_t off, size_t size, void *buf)
  function procfs_proc_vmstats (line 392) | static ssize_t procfs_proc_vmstats(int pid, off_t off, size_t size, void...
  type procfs_proc_entry (line 450) | struct procfs_proc_entry {
  type procfs_proc_entry (line 455) | struct procfs_proc_entry
  function procfs_read (line 463) | static ssize_t procfs_read(struct vnode *node, off_t offset, size_t size...
  function procfs_readdir (line 480) | static ssize_t procfs_readdir(struct vnode *vnode, off_t offset, struct ...
  function procfs_finddir (line 546) | static int procfs_finddir(struct vnode *parent, const char *name, struct...
  function procfs_vget (line 587) | static int procfs_vget(struct vnode *super, ino_t ino, struct vnode **vn...
  function procfs_close (line 667) | static int procfs_close(struct vnode *vnode)
  function procfs_init (line 685) | static int procfs_init()
  function procfs_mount (line 708) | static int procfs_mount(const char *dir, int flags, void *data)
  type fs (line 714) | struct fs

FILE: kernel/fs/pseudofs/pseudofs.c
  function pseudofs_vmknod (line 8) | int pseudofs_vmknod(struct vnode *dir, const char *fn, mode_t mode, dev_...
  function pseudofs_vunlink (line 76) | int pseudofs_vunlink(struct vnode *vnode, const char *fn, struct uio *uio)
  function pseudofs_readdir (line 120) | ssize_t pseudofs_readdir(struct vnode *dir, off_t offset, struct dirent ...
  function pseudofs_finddir (line 155) | int pseudofs_finddir(struct vnode *dir, const char *name, struct dirent ...
  function pseudofs_close (line 177) | int pseudofs_close(struct vnode *vnode)

FILE: kernel/fs/read.c
  function vfs_read (line 9) | ssize_t vfs_read(struct vnode *vnode, off_t off, size_t size, void *buf)

FILE: kernel/fs/readdir.c
  function vfs_readdir (line 7) | ssize_t vfs_readdir(struct vnode *dir, off_t off, struct dirent *dirent)
  function vfs_finddir (line 25) | int vfs_finddir(struct vnode *dir, const char *name, struct dirent *dirent)

FILE: kernel/fs/rofs.c
  function rofs_write (line 5) | ssize_t rofs_write(struct vnode *vnode, off_t offset, size_t size, void ...
  function rofs_trunc (line 10) | int rofs_trunc(struct vnode *vnode, off_t len)
  function rofs_vmknod (line 15) | int rofs_vmknod(struct vnode *dir, const char *fn, uint32_t mode, dev_t ...
  function rofs_vunlink (line 20) | int rofs_vunlink(struct vnode *dir, const char *fn, struct uio *uio)

FILE: kernel/fs/stat.c
  function vfs_stat (line 5) | int vfs_stat(struct vnode *vnode, struct stat *buf)

FILE: kernel/fs/sync.c
  function vfs_vsync (line 9) | int vfs_vsync(struct vnode *vnode, int mode)
  function vfs_fssync (line 18) | int vfs_fssync(struct vnode *super, int mode)
  function vfs_sync (line 27) | int vfs_sync(int mode)

FILE: kernel/fs/tmpfs/tmpfs.c
  function tmpfs_vget (line 22) | static int tmpfs_vget(struct vnode *super, ino_t ino, struct vnode **vnode)
  function tmpfs_close (line 31) | static int tmpfs_close(struct vnode *vnode)
  function tmpfs_read (line 44) | static ssize_t tmpfs_read(struct vnode *node, off_t offset, size_t size,...
  function tmpfs_write (line 54) | static ssize_t tmpfs_write(struct vnode *node, off_t offset, size_t size...
  function tmpfs_trunc (line 75) | static int tmpfs_trunc(struct vnode *vnode, off_t len)
  function tmpfs_file_can_read (line 108) | static int tmpfs_file_can_read(struct file *file, size_t size)
  function tmpfs_file_can_write (line 116) | static int tmpfs_file_can_write(struct file *file __unused, size_t size ...
  function tmpfs_file_eof (line 122) | static int tmpfs_file_eof(struct file *file)
  function tmpfs_init (line 127) | static int tmpfs_init()
  function tmpfs_mount (line 132) | static int tmpfs_mount(const char *dir, int flags __unused, void *data _...
  type fs (line 180) | struct fs

FILE: kernel/fs/trunc.c
  function vfs_trunc (line 5) | int vfs_trunc(struct vnode *vnode, off_t len)

FILE: kernel/fs/unlink.c
  function vfs_unlink (line 4) | int vfs_unlink(const char *path, struct uio *uio)

FILE: kernel/fs/vcache.c
  function vcache_eq (line 6) | static int vcache_eq(void *_a, void *_b)
  function vcache_init (line 18) | void vcache_init(struct vcache *vcache)
  function vcache_insert (line 23) | int vcache_insert(struct vcache *vcache, struct vnode *vnode)
  function vcache_remove (line 35) | int vcache_remove(struct vcache *vcache, struct vnode *vnode)
  type vnode (line 52) | struct vnode
  type vcache (line 52) | struct vcache
  type hashmap_node (line 59) | struct hashmap_node
  type vnode (line 62) | struct vnode

FILE: kernel/fs/vfs.c
  type fs_list (line 26) | struct fs_list
  type vfs_node (line 29) | struct vfs_node {
  type vnode (line 42) | struct vnode
  function vfs_mount_root (line 43) | int vfs_mount_root(struct vnode *vnode)
  function vfs_parse_path (line 60) | int vfs_parse_path(const char *path, struct uio *uio, char **abs_path)
  type vfs_path (line 133) | struct vfs_path
  type vfs_path (line 135) | struct vfs_path
  type vfs_path (line 135) | struct vfs_path
  type vfs_node (line 138) | struct vfs_node
  type vfs_node (line 139) | struct vfs_node
  type vfs_node (line 156) | struct vfs_node
  function vfs_bind (line 187) | int vfs_bind(const char *path, struct vnode *target)
  function vfs_init (line 246) | void vfs_init(void)
  function vfs_install (line 255) | int vfs_install(struct fs *fs)
  function vfs_perms_check (line 273) | int vfs_perms_check(struct file *file, struct uio *uio)

FILE: kernel/fs/vm_object.c
  type vm_pager (line 4) | struct vm_pager
  function vm_page_eq (line 6) | static int vm_page_eq(void *_a, void *_b)
  type vm_object (line 18) | struct vm_object
  type vnode (line 18) | struct vnode
  type vm_object (line 24) | struct vm_object
  type vm_object (line 26) | struct vm_object
  type vm_page (line 48) | struct vm_page
  type vm_object (line 48) | struct vm_object
  type vm_page (line 50) | struct vm_page
  type vnode (line 57) | struct vnode
  type vnode (line 57) | struct vnode
  type vm_pager (line 67) | struct vm_pager

FILE: kernel/fs/vops.c
  function vfs_vmknod (line 4) | int vfs_vmknod(struct vnode *dir, const char *name, mode_t mode, dev_t d...
  function vfs_vcreat (line 26) | int vfs_vcreat(struct vnode *dir, const char *name, struct uio *uio, str...
  function vfs_vmkdir (line 31) | int vfs_vmkdir(struct vnode *dir, const char *name, struct uio *uio, str...
  function vfs_vunlink (line 36) | int vfs_vunlink(struct vnode *dir, const char *fn, struct uio *uio)
  function vfs_vget (line 49) | int vfs_vget(struct vnode *super, ino_t ino, struct vnode **ref)
  function vfs_map (line 69) | int vfs_map(struct vm_space *vm_space, struct vm_entry *vm_entry)

FILE: kernel/fs/write.c
  function vfs_write (line 5) | ssize_t vfs_write(struct vnode *vnode, off_t off, size_t size, void *buf)

FILE: kernel/include/bits/dirent.h
  type dirent (line 12) | struct dirent {

FILE: kernel/include/bits/utsname.h
  type utsname (line 6) | struct utsname {

FILE: kernel/include/boot/boot.h
  type module_t (line 7) | typedef struct {
  type mmap_type (line 13) | enum mmap_type {
  type mmap_t (line 18) | typedef struct {
  type boot (line 24) | struct boot {

FILE: kernel/include/console/earlycon.h
  type earlycon (line 7) | struct earlycon {

FILE: kernel/include/core/arch.h
  type proc (line 8) | struct proc
  type proc (line 9) | struct proc
  type proc (line 10) | struct proc
  type thread (line 14) | struct thread
  type thread (line 15) | struct thread
  type thread (line 16) | struct thread
  type thread (line 17) | struct thread
  type thread (line 21) | struct thread
  type proc (line 21) | struct proc
  type thread (line 24) | struct thread
  type proc (line 32) | struct proc
  type pmap (line 40) | struct pmap
  type timespec (line 50) | struct timespec

FILE: kernel/include/core/qsort.h
  function __qsort_swap (line 7) | static inline void __qsort_swap(char *a, char *b, size_t size)
  function qsort (line 18) | static inline void qsort(void *base, size_t nmemb, size_t size, int (*co...

FILE: kernel/include/core/string.h
  function strcmp (line 45) | static inline int strcmp(const char *s1, const char *s2)
  function strncmp (line 55) | static inline int strncmp(const char *s1, const char *s2, size_t n)
  function strlen (line 65) | static inline int strlen(const char *s)
  function free_tokens (line 138) | static inline void free_tokens(char **ptr)

FILE: kernel/include/core/time.h
  type timespec (line 6) | struct timespec
  type timeval (line 8) | struct timeval
  type timezone (line 8) | struct timezone
  type timeval (line 9) | struct timeval
  type timezone (line 9) | struct timezone

FILE: kernel/include/core/types.h
  type pid_t (line 6) | typedef int       pid_t;
  type pid_t (line 7) | typedef pid_t     tid_t;
  type off_t (line 8) | typedef long int  off_t;
  type vino_t (line 14) | typedef uintptr_t vino_t;
  type mode_t (line 15) | typedef uint32_t  mode_t;
  type mask_t (line 16) | typedef uint8_t   mask_t;
  type devid_t (line 17) | typedef uint8_t   devid_t;
  type dev_t (line 18) | typedef uint16_t  dev_t;
  type uid_t (line 20) | typedef uint32_t  uid_t;
  type gid_t (line 21) | typedef uint32_t  gid_t;
  type nlink_t (line 22) | typedef uint32_t  nlink_t;
  type ino_t (line 23) | typedef uintptr_t ino_t;
  type _time_t (line 24) | typedef struct timespec _time_t;
  type time_t (line 26) | typedef uint64_t time_t;
  type sigset_t (line 27) | typedef unsigned long sigset_t;
  type suseconds_t (line 28) | typedef long suseconds_t;
  type timespec (line 30) | struct timespec {
  type timeval (line 35) | struct timeval {
  type timezone (line 40) | struct timezone {
  type utimbuf (line 45) | struct utimbuf {

FILE: kernel/include/cpu/io.h
  type ioaddr (line 11) | struct ioaddr {
  type ioaddr (line 16) | struct ioaddr

FILE: kernel/include/dev/console.h
  type dev (line 7) | struct dev

FILE: kernel/include/dev/dev.h
  type devid (line 6) | struct devid
  type dev (line 7) | struct dev
  type devid (line 17) | struct devid {
  type dev (line 27) | struct dev {
  type dev (line 44) | struct dev
  type dev (line 45) | struct dev
  type devid (line 47) | struct devid
  type devid (line 48) | struct devid
  type devid (line 49) | struct devid
  type devid (line 50) | struct devid
  type vm_space (line 50) | struct vm_space
  type vm_entry (line 50) | struct vm_entry
  type devid (line 52) | struct devid
  type file (line 52) | struct file
  type devid (line 53) | struct devid
  type file (line 53) | struct file
  type devid (line 54) | struct devid
  type file (line 54) | struct file
  type devid (line 55) | struct devid
  type file (line 55) | struct file
  type devid (line 56) | struct devid
  type file (line 56) | struct file
  type devid (line 57) | struct devid
  type file (line 57) | struct file
  type devid (line 58) | struct devid
  type file (line 58) | struct file
  type devid (line 59) | struct devid
  type file (line 59) | struct file
  type devid (line 60) | struct devid
  type file (line 60) | struct file
  type dev (line 69) | struct dev
  type dev (line 70) | struct dev
  type dev (line 71) | struct dev
  type dev (line 72) | struct dev
  type dev (line 73) | struct dev
  type dev (line 74) | struct dev
  type dev (line 75) | struct dev
  type dev (line 76) | struct dev

FILE: kernel/include/dev/fbdev.h
  type fbdev (line 7) | struct fbdev
  type fb_fix_screeninfo (line 14) | struct fb_fix_screeninfo {
  type fb_bitfield (line 32) | struct fb_bitfield {
  type fb_var_screeninfo (line 38) | struct fb_var_screeninfo {
  type fbdev (line 80) | struct fbdev {

FILE: kernel/include/dev/kbd.h
  type keyboard (line 7) | struct keyboard {

FILE: kernel/include/dev/pci.h
  type pci_dev (line 7) | struct pci_dev
  type pci_dev (line 27) | struct pci_dev {
  type dev (line 33) | struct dev
  type ioaddr (line 34) | struct ioaddr
  type pci_dev (line 40) | struct pci_dev
  type pci_dev (line 41) | struct pci_dev
  type pci_dev (line 42) | struct pci_dev
  type pci_dev (line 43) | struct pci_dev
  type pci_dev (line 44) | struct pci_dev
  type pci_dev (line 45) | struct pci_dev
  type pci_dev (line 46) | struct pci_dev
  type pci_dev (line 47) | struct pci_dev
  type pci_dev (line 48) | struct pci_dev

FILE: kernel/include/dev/ramdev.h
  type ramdev_priv (line 6) | struct ramdev_priv {
  type dev (line 12) | struct dev

FILE: kernel/include/dev/tty.h
  type tty (line 6) | struct tty
  type tty (line 12) | struct tty
  type tty (line 18) | struct tty {
  type proc (line 51) | struct proc
  type tty (line 51) | struct tty
  type tty (line 52) | struct tty
  type tty (line 53) | struct tty
  type tty (line 54) | struct tty
  type tty (line 55) | struct tty

FILE: kernel/include/dev/ttydev.h
  type dev (line 7) | struct dev
  type dev (line 8) | struct dev
  type dev (line 9) | struct dev
  type dev (line 10) | struct dev
  type dev (line 11) | struct dev

FILE: kernel/include/dev/uart.h
  type uart (line 7) | struct uart {
  type uart (line 21) | struct uart
  type uart (line 22) | struct uart
  type uart (line 23) | struct uart

FILE: kernel/include/ds/bitmap.h
  type bitmap_t (line 8) | typedef uint32_t bitmap_t;
  type bitmap (line 14) | struct bitmap {
  function bitmap_size (line 33) | static inline size_t bitmap_size(size_t n)
  function bitmap_set (line 38) | static inline void bitmap_set(struct bitmap *bitmap, size_t index)
  function bitmap_clear (line 43) | static inline void bitmap_clear(struct bitmap *bitmap, size_t index)
  function bitmap_check (line 48) | static inline int bitmap_check(struct bitmap *bitmap, size_t index)
  function bitmap_set_range (line 53) | static inline void bitmap_set_range(struct bitmap *bitmap, size_t findex...
  function bitmap_clear_range (line 75) | static inline void bitmap_clear_range(struct bitmap *bitmap, size_t find...

FILE: kernel/include/ds/buddy.h
  type buddy (line 11) | struct buddy {

FILE: kernel/include/ds/hashmap.h
  type hashmap (line 6) | struct hashmap
  type hashmap_node (line 7) | struct hashmap_node
  type hash_t (line 13) | typedef uintptr_t hash_t;
  type hashmap (line 21) | struct hashmap {
  type hashmap_node (line 34) | struct hashmap_node {
  type hashmap (line 62) | struct hashmap
  type hashmap (line 66) | struct hashmap
  type hashmap (line 68) | struct hashmap
  type hashmap (line 73) | struct hashmap
  type queue (line 76) | struct queue
  type queue (line 83) | struct queue
  function hash_t (line 94) | static inline hash_t hashmap_digest(const void *_id, size_t size)
  function hashmap_insert (line 113) | static inline int hashmap_insert(struct hashmap *hashmap, hash_t hash, v...
  type hashmap_node (line 145) | struct hashmap_node
  type hashmap (line 145) | struct hashmap
  type queue (line 151) | struct queue
  type hashmap_node (line 154) | struct hashmap_node
  type hashmap_node (line 154) | struct hashmap_node
  function hashmap_replace (line 166) | static inline int hashmap_replace(struct hashmap *hashmap, hash_t hash, ...
  function hashmap_node_remove (line 189) | static inline void hashmap_node_remove(struct hashmap *hashmap, struct h...
  function hashmap_remove (line 204) | static inline void hashmap_remove(struct hashmap *hashmap, hash_t id)
  function hashmap_free (line 217) | static inline void hashmap_free(struct hashmap *hashmap)

FILE: kernel/include/ds/queue.h
  type qnode (line 6) | struct qnode
  type queue (line 7) | struct queue
  type qnode (line 15) | struct qnode {
  type queue (line 27) | struct queue {
  type queue (line 50) | struct queue
  type queue (line 52) | struct queue
  type queue (line 54) | struct queue
  type queue (line 57) | struct queue
  type qnode (line 65) | struct qnode
  type queue (line 65) | struct queue
  type qnode (line 74) | struct qnode
  type qnode (line 76) | struct qnode
  type qnode (line 79) | struct qnode
  type queue (line 102) | struct queue
  type qnode (line 108) | struct qnode
  function queue_remove (line 128) | static inline void queue_remove(struct queue *queue, void *value)
  function queue_node_remove (line 158) | static inline void queue_node_remove(struct queue *queue, struct qnode *...

FILE: kernel/include/ds/ringbuf.h
  type ringbuf (line 13) | struct ringbuf {
  type ringbuf (line 30) | struct ringbuf
  type ringbuf (line 32) | struct ringbuf
  type ringbuf (line 32) | struct ringbuf
  function ringbuf_free (line 55) | static inline void ringbuf_free(struct ringbuf *r)
  function ringbuf_read (line 68) | static inline size_t ringbuf_read(struct ringbuf *ring, size_t n, char *...
  function ringbuf_read_noconsume (line 88) | static inline size_t ringbuf_read_noconsume(struct ringbuf *ring, off_t ...
  function ringbuf_write (line 108) | static inline size_t ringbuf_write(struct ringbuf *ring, size_t n, char ...
  function ringbuf_write_overwrite (line 126) | static inline size_t ringbuf_write_overwrite(struct ringbuf *ring, size_...
  function ringbuf_available (line 146) | static inline size_t ringbuf_available(struct ringbuf *ring)

FILE: kernel/include/fs/bcache.h
  type bcache (line 11) | struct bcache {
  type bcache (line 15) | struct bcache
  type bcache (line 16) | struct bcache
  type bcache (line 17) | struct bcache
  type bcache (line 18) | struct bcache

FILE: kernel/include/fs/devfs.h
  type fs (line 6) | struct fs
  type vnode (line 7) | struct vnode

FILE: kernel/include/fs/devpts.h
  type fs (line 6) | struct fs
  type vnode (line 7) | struct vnode

FILE: kernel/include/fs/initramfs.h
  type fs (line 7) | struct fs
  type fs (line 9) | struct fs

FILE: kernel/include/fs/ioctl.h
  type winsize (line 4) | struct winsize {

FILE: kernel/include/fs/mbr.h
  type mbr_part (line 6) | struct mbr_part
  type mbr (line 7) | struct mbr
  type mbr_part (line 12) | struct mbr_part {
  type mbr (line 27) | struct mbr {

FILE: kernel/include/fs/pipe.h
  type pipe (line 6) | struct pipe
  type pipe (line 17) | struct pipe {
  type fs (line 28) | struct fs
  type file (line 29) | struct file
  type file (line 29) | struct file

FILE: kernel/include/fs/posix.h
  type file (line 6) | struct file
  type file (line 7) | struct file
  type file (line 8) | struct file
  type file (line 9) | struct file
  type file (line 10) | struct file
  type dirent (line 10) | struct dirent
  type file (line 11) | struct file
  type file (line 12) | struct file
  type file (line 13) | struct file
  type file (line 16) | struct file
  type file (line 17) | struct file
  type file (line 18) | struct file

FILE: kernel/include/fs/pseudofs.h
  type pseudofs_dirent (line 6) | struct pseudofs_dirent {
  type vnode (line 13) | struct vnode
  type uio (line 13) | struct uio
  type vnode (line 13) | struct vnode
  type vnode (line 14) | struct vnode
  type uio (line 14) | struct uio
  type vnode (line 16) | struct vnode
  type dirent (line 16) | struct dirent
  type vnode (line 17) | struct vnode
  type dirent (line 17) | struct dirent
  type vnode (line 19) | struct vnode

FILE: kernel/include/fs/rofs.h
  type vnode (line 4) | struct vnode
  type vnode (line 5) | struct vnode
  type vnode (line 6) | struct vnode
  type uio (line 6) | struct uio
  type vnode (line 6) | struct vnode
  type vnode (line 7) | struct vnode
  type uio (line 7) | struct uio

FILE: kernel/include/fs/stat.h
  type stat (line 6) | struct  stat
  type stat (line 13) | struct  stat {

FILE: kernel/include/fs/termios.h
  type cc_t (line 6) | typedef unsigned char cc_t;
  type speed_t (line 7) | typedef unsigned int  speed_t;
  type tcflag_t (line 8) | typedef unsigned int  tcflag_t;
  type termios (line 16) | struct termios {

FILE: kernel/include/fs/tmpfs.h
  type fs (line 6) | struct fs

FILE: kernel/include/fs/vcache.h
  type vcache (line 11) | struct vcache {
  type vcache (line 15) | struct vcache
  type vcache (line 16) | struct vcache
  type vnode (line 16) | struct vnode
  type vcache (line 17) | struct vcache
  type vnode (line 17) | struct vnode
  type vnode (line 18) | struct vnode
  type vcache (line 18) | struct vcache

FILE: kernel/include/fs/vfs.h
  type fs (line 8) | struct fs
  type vnode (line 9) | struct vnode
  type file (line 10) | struct file
  type uio (line 11) | struct uio
  type vops (line 12) | struct vops
  type fops (line 20) | struct fops {
  type uio (line 48) | struct uio {
  type vops (line 61) | struct vops {
  type vfs_path (line 85) | struct vfs_path {
  type fs (line 94) | struct fs {
  type vnode (line 111) | struct vnode {
  type file (line 140) | struct file {
  type fs_list (line 155) | struct fs_list {
  type vfs_path (line 167) | struct vfs_path
  type uio (line 169) | struct uio
  type fs_list (line 171) | struct fs_list
  type vnode (line 172) | struct vnode
  function __vfs_can_always (line 174) | static inline int __vfs_can_always(struct file *f, size_t s){return 1;}
  function __vfs_can_never (line 175) | static inline int __vfs_can_never (struct file *f, size_t s){return 0;}
  function __vfs_eof_always (line 176) | static inline int __vfs_eof_always(struct file *f){return 1;}
  function __vfs_eof_never (line 177) | static inline int __vfs_eof_never (struct file *f){return 0;}
  type fs (line 183) | struct fs
  type vnode (line 184) | struct vnode
  type vnode (line 185) | struct vnode
  type uio (line 186) | struct uio
  type vnode (line 189) | struct vnode
  type uio (line 189) | struct uio
  type vnode (line 189) | struct vnode
  type vnode (line 190) | struct vnode
  type uio (line 190) | struct uio
  type vnode (line 190) | struct vnode
  type vnode (line 191) | struct vnode
  type uio (line 191) | struct uio
  type vnode (line 191) | struct vnode
  type vnode (line 192) | struct vnode
  type uio (line 192) | struct uio
  type vnode (line 193) | struct vnode
  type vnode (line 193) | struct vnode
  type vm_space (line 195) | struct vm_space
  type vm_entry (line 195) | struct vm_entry
  type vnode (line 197) | struct vnode
  type vnode (line 198) | struct vnode
  type vnode (line 199) | struct vnode
  type vnode (line 200) | struct vnode
  type vnode (line 201) | struct vnode
  type vm_page (line 203) | struct vm_page
  type vnode (line 203) | struct vnode
  type vnode (line 208) | struct vnode
  type vnode (line 209) | struct vnode
  type vnode (line 212) | struct vnode
  type dirent (line 212) | struct dirent
  type vnode (line 213) | struct vnode
  type dirent (line 213) | struct dirent
  type file (line 216) | struct file
  type file (line 217) | struct file
  type file (line 218) | struct file
  type file (line 219) | struct file
  type dirent (line 219) | struct dirent
  type file (line 220) | struct file
  type file (line 221) | struct file
  type file (line 222) | struct file
  type file (line 223) | struct file
  type file (line 226) | struct file
  type file (line 227) | struct file
  type file (line 228) | struct file
  type uio (line 232) | struct uio
  type vnode (line 232) | struct vnode
  type uio (line 235) | struct uio
  type vnode (line 235) | struct vnode
  type uio (line 236) | struct uio
  type vnode (line 236) | struct vnode
  type uio (line 237) | struct uio
  type vnode (line 237) | struct vnode
  type uio (line 238) | struct uio
  type vnode (line 239) | struct vnode
  type stat (line 239) | struct stat
  type file (line 240) | struct file
  type uio (line 240) | struct uio
  type mountpoint (line 244) | struct mountpoint {

FILE: kernel/include/mm/kvmem.h
  type malloc_type (line 4) | struct malloc_type {
  type malloc_type (line 24) | struct malloc_type

FILE: kernel/include/mm/mm.h
  type boot (line 17) | struct boot
  type vm_page (line 19) | struct vm_page
  type vm_page (line 20) | struct vm_page
  type pmap (line 26) | struct pmap
  type pmap (line 27) | struct pmap
  type pmap (line 28) | struct pmap
  type pmap (line 29) | struct pmap

FILE: kernel/include/mm/pmap.h
  type pmap (line 5) | struct pmap
  type pmap (line 5) | struct pmap
  type pmap (line 6) | struct pmap
  type pmap (line 7) | struct pmap
  type pmap (line 8) | struct pmap
  type pmap (line 9) | struct pmap
  type pmap (line 10) | struct pmap
  type pmap (line 11) | struct pmap
  type pmap (line 13) | struct pmap

FILE: kernel/include/mm/vm.h
  type vm_space (line 7) | struct vm_space
  type vm_entry (line 8) | struct vm_entry
  type vm_object (line 9) | struct vm_object
  type vm_page (line 10) | struct vm_page
  type vm_space (line 26) | struct vm_space {
  type vm_entry (line 70) | struct vm_entry {
  type vm_pager (line 100) | struct vm_pager {
  type vm_aref (line 115) | struct vm_aref {
  type vm_anon (line 130) | struct vm_anon {
  type vm_object (line 145) | struct vm_object {
  type vm_page (line 166) | struct vm_page {
  type vm_page (line 176) | struct vm_page
  type vm_space (line 177) | struct vm_space
  type vm_space (line 182) | struct vm_space
  type vm_entry (line 182) | struct vm_entry
  type vm_space (line 183) | struct vm_space
  type vm_entry (line 183) | struct vm_entry
  type vm_space (line 184) | struct vm_space
  type vm_entry (line 184) | struct vm_entry
  type vm_space (line 187) | struct vm_space
  type vm_space (line 187) | struct vm_space
  type vm_space (line 188) | struct vm_space
  type vm_entry (line 189) | struct vm_entry
  type vm_space (line 189) | struct vm_space
  type vm_space (line 190) | struct vm_space
  type vm_entry (line 190) | struct vm_entry
  type vm_entry (line 193) | struct vm_entry
  type vm_entry (line 194) | struct vm_entry
  type vm_anon (line 197) | struct vm_anon
  type vm_anon (line 198) | struct vm_anon
  type vm_anon (line 198) | struct vm_anon
  type vm_anon (line 199) | struct vm_anon
  type vm_anon (line 200) | struct vm_anon
  type vm_anon (line 201) | struct vm_anon
  type vm_object (line 204) | struct vm_object
  type vnode (line 204) | struct vnode
  type vm_page (line 205) | struct vm_page
  type vm_object (line 205) | struct vm_object
  type vm_object (line 206) | struct vm_object
  type vm_page (line 206) | struct vm_page
  type vm_object (line 207) | struct vm_object
  type vm_object (line 208) | struct vm_object

FILE: kernel/include/net/socket.h
  type socklen_t (line 7) | typedef uint32_t socklen_t;
  type sa_family_t (line 8) | typedef uint32_t sa_family_t;
  type sockaddr (line 10) | struct sockaddr {
  type socket (line 15) | struct socket {
  type sock_ops (line 29) | struct sock_ops {
  type file (line 71) | struct file
  type file (line 72) | struct file
  type sockaddr (line 72) | struct sockaddr
  type file (line 73) | struct file
  type file (line 73) | struct file
  type sockaddr (line 73) | struct sockaddr
  type file (line 74) | struct file
  type sockaddr (line 74) | struct sockaddr
  type file (line 75) | struct file
  type file (line 76) | struct file
  type file (line 77) | struct file
  type file (line 78) | struct file
  type file (line 79) | struct file
  type file (line 80) | struct file
  type file (line 83) | struct file

FILE: kernel/include/stddef.h
  type __SIZE_TYPE__ (line 4) | typedef __SIZE_TYPE__ size_t;
  type __PTRDIFF_TYPE__ (line 5) | typedef __PTRDIFF_TYPE__ ssize_t;
  type __WCHAR_TYPE__ (line 6) | typedef __WCHAR_TYPE__ wchar_t;
  type __PTRDIFF_TYPE__ (line 7) | typedef __PTRDIFF_TYPE__ ptrdiff_t;
  type __PTRDIFF_TYPE__ (line 8) | typedef __PTRDIFF_TYPE__ intptr_t;
  type __SIZE_TYPE__ (line 9) | typedef __SIZE_TYPE__ uintptr_t;

FILE: kernel/include/sys/binfmt.h
  type binfmt (line 12) | struct binfmt {
  type proc (line 17) | struct proc
  type proc (line 17) | struct proc
  type vnode (line 20) | struct vnode
  type proc (line 21) | struct proc
  type vnode (line 21) | struct vnode

FILE: kernel/include/sys/elf.h
  type elf32_sword (line 6) | typedef int32_t  elf32_sword;
  type elf32_word (line 7) | typedef uint32_t elf32_word;
  type elf32_addr (line 8) | typedef uint32_t elf32_addr;
  type elf32_off (line 9) | typedef uint32_t elf32_off;
  type elf32_half (line 10) | typedef uint16_t elf32_half;
  type elf32_hdr (line 140) | struct elf32_hdr {
  type elf32_shdr (line 161) | struct elf32_shdr {
  type elf32_sym (line 178) | struct elf32_sym {
  type elf32_phdr (line 191) | struct elf32_phdr {
  type elf32_dyn (line 206) | struct elf32_dyn {

FILE: kernel/include/sys/proc.h
  type proc (line 6) | struct proc
  type pgroup (line 7) | struct pgroup
  type session (line 8) | struct session
  type session (line 21) | struct session {
  type pgroup (line 42) | struct pgroup {
  type proc (line 66) | struct proc {
  type thread (line 133) | struct thread
  type proc (line 133) | struct proc
  type thread (line 136) | struct thread
  type proc (line 141) | struct proc
  type proc (line 143) | struct proc
  type proc (line 144) | struct proc
  type proc (line 145) | struct proc
  type pgroup (line 145) | struct pgroup
  type proc (line 147) | struct proc
  type proc (line 148) | struct proc
  type proc (line 149) | struct proc
  type proc (line 150) | struct proc
  type proc (line 151) | struct proc
  type proc (line 153) | struct proc
  type queue (line 158) | struct queue
  type queue (line 159) | struct queue
  type queue (line 160) | struct queue

FILE: kernel/include/sys/sched.h
  type queue (line 8) | struct queue
  type thread (line 9) | struct thread
  type thread (line 15) | struct thread
  type proc (line 16) | struct proc
  type thread (line 19) | struct thread

FILE: kernel/include/sys/signal.h
  type sigaction (line 6) | struct sigaction
  type sigaction (line 58) | struct sigaction {
  type proc (line 67) | struct proc
  type pgroup (line 68) | struct pgroup

FILE: kernel/include/sys/thread.h
  type thread (line 6) | struct thread
  type state_t (line 10) | typedef enum {
  type thread (line 21) | struct thread {
  type queue (line 51) | struct queue
  type queue (line 52) | struct queue
  type proc (line 53) | struct proc
  type thread (line 53) | struct thread
  type thread (line 54) | struct thread
  type thread (line 54) | struct thread
  type thread (line 55) | struct thread
  type thread (line 58) | struct thread

FILE: kernel/include/video/vbe.h
  type vbe_info_block (line 7) | struct vbe_info_block {
  type mode_info_block (line 26) | struct mode_info_block {
  type pm_info_block (line 174) | struct pm_info_block {

FILE: kernel/include/video/vesa.h
  type fbdev_vesa (line 6) | struct fbdev_vesa {

FILE: kernel/mm/buddy.c
  type buddy (line 32) | struct buddy
  function buddy_recursive_alloc (line 39) | static size_t buddy_recursive_alloc(int zone, size_t order)
  function buddy_recursive_free (line 88) | static void buddy_recursive_free(int zone, size_t order, size_t idx)
  function paddr_t (line 116) | paddr_t buddy_alloc(int zone, size_t _sz)
  function buddy_free (line 143) | void buddy_free(int zone, paddr_t addr, size_t size)
  function buddy_set_unusable (line 165) | void buddy_set_unusable(paddr_t addr, size_t size)
  function buddy_setup (line 200) | int buddy_setup(size_t total_mem)

FILE: kernel/mm/fault.c
  type pf (line 14) | struct pf {
  function check_violation (line 25) | static inline int check_violation(int flags, int vm_flags)
  function pf_present (line 39) | static inline int pf_present(struct pf *pf)
  function pf_anon (line 84) | static inline int pf_anon(struct pf *pf)
  type vm_page (line 171) | struct vm_page
  type vm_object (line 171) | struct vm_object
  type hashmap_node (line 173) | struct hashmap_node
  type vm_page (line 174) | struct vm_page
  type vm_page (line 178) | struct vm_page
  function pf_object (line 192) | static inline int pf_object(struct pf *pf)
  function pf_zero (line 253) | static inline int pf_zero(struct pf *pf)
  function mm_page_fault (line 295) | void mm_page_fault(vaddr_t vaddr, int flags)

FILE: kernel/mm/kvmem.c
  function __stack_chk_fail (line 11) | void __stack_chk_fail(void)
  type queue (line 16) | struct queue
  type kvmem_node (line 27) | struct kvmem_node {
  type vm_entry (line 46) | struct vm_entry
  type kvmem_node (line 54) | struct kvmem_node
  function kvmem_setup (line 56) | void kvmem_setup(void)
  function get_node (line 74) | static uint32_t get_node(void)
  function release_node (line 85) | void release_node(uint32_t i)
  function get_first_fit_free_node (line 94) | uint32_t get_first_fit_free_node(uint32_t size)
  function print_node (line 107) | void print_node(unsigned i)
  type malloc_type (line 117) | struct malloc_type
  type vm_entry (line 153) | struct vm_entry
  function kfree (line 176) | void kfree(void *_ptr)
  function dump_nodes (line 291) | void dump_nodes(void)

FILE: kernel/mm/mm.c
  type vm_page (line 24) | struct vm_page
  function mm_page_incref (line 31) | void mm_page_incref(paddr_t paddr)
  function mm_page_decref (line 40) | void mm_page_decref(paddr_t paddr)
  function mm_page_ref (line 49) | size_t mm_page_ref(paddr_t paddr)
  type vm_page (line 58) | struct vm_page
  type vm_page (line 67) | struct vm_page
  type vm_page (line 71) | struct vm_page
  type vm_page (line 73) | struct vm_page
  function mm_page_dealloc (line 83) | void mm_page_dealloc(paddr_t paddr)
  function mm_page_map (line 93) | int mm_page_map(struct pmap *pmap, vaddr_t vaddr, paddr_t paddr, int flags)
  function mm_page_unmap (line 103) | int mm_page_unmap(struct pmap *pmap, vaddr_t vaddr)
  function mm_map (line 128) | int mm_map(struct pmap *pmap, paddr_t paddr, vaddr_t vaddr, size_t size,...
  function mm_unmap (line 160) | void mm_unmap(struct pmap *pmap, vaddr_t vaddr, size_t size)
  function mm_unmap_full (line 182) | void mm_unmap_full(struct pmap *pmap, vaddr_t vaddr, size_t size)
  function mm_setup (line 199) | void mm_setup(struct boot *boot)

FILE: kernel/mm/vm_anon.c
  function vm_aref_eq (line 11) | static int vm_aref_eq(void *_a, void *_b)
  type vm_anon (line 27) | struct vm_anon
  type vm_anon (line 29) | struct vm_anon
  type vm_anon (line 29) | struct vm_anon
  function vm_aref_destroy (line 55) | void vm_aref_destroy(struct vm_aref *vm_aref)
  function vm_aref_decref (line 64) | void vm_aref_decref(struct vm_aref *vm_aref)
  function vm_anon_destroy (line 73) | void vm_anon_destroy(struct vm_anon *vm_anon)
  function vm_anon_incref (line 104) | void vm_anon_incref(struct vm_anon *vm_anon)
  function vm_anon_decref (line 117) | void vm_anon_decref(struct vm_anon *vm_anon)
  function vm_anon_copy_arefs (line 134) | static int vm_anon_copy_arefs(struct vm_anon *src, struct vm_anon *dst)
  type vm_anon (line 155) | struct vm_anon
  type vm_anon (line 155) | struct vm_anon
  type vm_anon (line 160) | struct vm_anon

FILE: kernel/mm/vm_entry.c
  type vm_entry (line 8) | struct vm_entry
  type vm_entry (line 10) | struct vm_entry
  type vm_entry (line 10) | struct vm_entry
  function vm_entry_destroy (line 18) | void vm_entry_destroy(struct vm_entry *vm_entry)

FILE: kernel/mm/vm_object.c
  function vm_object_incref (line 11) | void vm_object_incref(struct vm_object *vm_object)
  function vm_object_decref (line 16) | void vm_object_decref(struct vm_object *vm_object)
  function vm_object_page_insert (line 29) | void vm_object_page_insert(struct vm_object *vm_object, struct vm_page *...

FILE: kernel/mm/vm_space.c
  function vm_space_insert (line 13) | int vm_space_insert(struct vm_space *vm_space, struct vm_entry *vm_entry)
  type vm_entry (line 78) | struct vm_entry
  type vm_space (line 78) | struct vm_space
  type queue (line 84) | struct queue
  type vm_entry (line 87) | struct vm_entry
  function vm_space_destroy (line 101) | void vm_space_destroy(struct vm_space *vm_space)
  function vm_space_fork (line 120) | int vm_space_fork(struct vm_space *src, struct vm_space *dst)

FILE: kernel/mm/vmm.c
  type vm_space (line 11) | struct vm_space
  function vm_map (line 13) | int vm_map(struct vm_space *vm_space, struct vm_entry *vm_entry)
  function vm_unmap (line 19) | void vm_unmap(struct vm_space *vm_space, struct vm_entry *vm_entry)
  function vm_unmap_full (line 30) | void vm_unmap_full(struct vm_space *vm_space, struct vm_entry *vm_entry)

FILE: kernel/net/socket.c
  function socket_create (line 12) | int socket_create(struct file *file, int domain, int type, int protocol)
  function socket_accept (line 22) | int socket_accept(struct file *file, struct file *conn, const struct soc...
  function socket_bind (line 33) | int socket_bind(struct file *file, const struct sockaddr *addr, uint32_t...
  function socket_connect (line 44) | int socket_connect(struct file *file, const struct sockaddr *addr, uint3...
  function socket_listen (line 55) | int socket_listen(struct file *file, int backlog)
  function socket_send (line 66) | int socket_send(struct file *file, void *buf, size_t len, int flags)
  function socket_recv (line 83) | int socket_recv(struct file *file, void *buf, size_t len, int flags)
  function socket_can_read (line 94) | int socket_can_read(struct file *file, size_t len)
  function socket_can_write (line 105) | int socket_can_write(struct file *file, size_t len)
  function socket_shutdown (line 116) | int socket_shutdown(struct file *file, int how)

FILE: kernel/net/unix/unix.c
  type sock_ops (line 14) | struct sock_ops
  type queue (line 16) | struct queue
  function socket_unix_create (line 18) | int socket_unix_create(struct file *file, int domain, int type, int prot...
  function socket_unix_accept (line 36) | static int socket_unix_accept(struct file *file, struct file *conn, cons...
  function socket_unix_bind (line 81) | static int socket_unix_bind(struct file *file, const struct sockaddr *ad...
  function socket_unix_connect (line 118) | static int socket_unix_connect(struct file *file, const struct sockaddr ...
  function socket_unix_listen (line 167) | static int socket_unix_listen(struct file *file, int backlog)
  function socket_unix_send (line 179) | static ssize_t socket_unix_send(struct file *file, void *buf, size_t len...
  function socket_unix_recv (line 230) | static ssize_t socket_unix_recv(struct file *file, void *buf, size_t len...
  function socket_unix_can_read (line 279) | static int socket_unix_can_read(struct file *file, size_t len)
  function socket_unix_can_write (line 312) | static int socket_unix_can_write(struct file *file, size_t len)
  function socket_unix_shutdown (line 335) | static int socket_unix_shutdown(struct file *file, int how)
  type sock_ops (line 377) | struct sock_ops

FILE: kernel/net/unix/unix.h
  type un_conn (line 6) | struct un_conn {
  type un_socket (line 19) | struct un_socket {
  type sockaddr_un (line 31) | struct sockaddr_un {

FILE: kernel/sys/binfmt/binfmt.c
  type binfmt (line 6) | struct binfmt
  function binfmt_fmt_load (line 12) | static int binfmt_fmt_load(struct proc *proc, const char *path, struct v...
  function binfmt_load (line 70) | int binfmt_load(struct proc *proc, const char *path, struct proc **ref)

FILE: kernel/sys/binfmt/elf.c
  function binfmt_elf32_load (line 20) | static int binfmt_elf32_load(struct proc *proc, struct vnode *vnode)
  function binfmt_elf64_load (line 138) | static int binfmt_elf64_load(struct proc *proc, struct vnode *file)
  function binfmt_elf_check (line 192) | int binfmt_elf_check(struct vnode *vnode)
  function binfmt_elf_load (line 207) | int binfmt_elf_load(struct proc *proc, const char *path __unused, struct...

FILE: kernel/sys/execve.c
  function proc_execve (line 8) | int proc_execve(struct thread *thread, const char *fn, char * const _arg...
  function thread_execve (line 67) | int thread_execve(struct thread *thread, char * const _argp[], char * co...

FILE: kernel/sys/fork.c
  function copy_fds (line 13) | static int copy_fds(struct proc *parent, struct proc *fork)
  function fork_proc_copy (line 36) | static int fork_proc_copy(struct proc *parent, struct proc *fork)
  function proc_fork (line 54) | int proc_fork(struct thread *thread, struct proc **ref)

FILE: kernel/sys/proc.c
  type queue (line 40) | struct queue
  type queue (line 43) | struct queue
  type queue (line 46) | struct queue
  type bitmap (line 48) | struct bitmap
  function proc_pid_alloc (line 51) | int proc_pid_alloc()
  function proc_pid_free (line 64) | void proc_pid_free(int pid)
  function proc_new (line 71) | int proc_new(struct proc **ref)
  type proc (line 118) | struct proc
  type proc (line 121) | struct proc
  function proc_init (line 129) | int proc_init(struct proc *proc)
  function proc_kill (line 164) | void proc_kill(struct proc *proc)
  function proc_reap (line 249) | int proc_reap(struct proc *proc)
  function proc_fd_get (line 259) | int proc_fd_get(struct proc *proc)
  function proc_fd_release (line 271) | void proc_fd_release(struct proc *proc, int fd)
  function session_new (line 278) | int session_new(struct proc *proc)
  function pgrp_new (line 331) | int pgrp_new(struct proc *proc, struct pgroup **ref)

FILE: kernel/sys/sched.c
  type queue (line 8) | struct queue
  type thread (line 9) | struct thread
  function sched_thread_ready (line 11) | void sched_thread_ready(struct thread *thread)
  function kernel_idle (line 19) | void kernel_idle(void)
  function sched_thread_spawn (line 25) | void sched_thread_spawn(struct thread *thread)   /* Starts thread execut...
  function sched_init_spawn (line 31) | void sched_init_spawn(struct proc *init)
  function schedule (line 48) | void schedule() /* Called from arch-specific timer event handler */

FILE: kernel/sys/signal.c
  function signal_proc_send (line 53) | int signal_proc_send(struct proc *proc, int signal)
  function signal_pgrp_send (line 69) | int signal_pgrp_send(struct pgroup *pg, int signal)
  function signal_send (line 79) | int signal_send(pid_t pid, int signal)

FILE: kernel/sys/syscall.c
  function sys_exit (line 40) | static void sys_exit(int code)
  function sys_close (line 55) | static void sys_close(int fildes)
  function sys_execve (line 76) | static void sys_execve(const char *path, char * const argp[], char * con...
  function sys_fork (line 104) | static void sys_fork(void)
  function sys_fstat (line 118) | static void sys_fstat(int fildes, struct stat *buf)
  function sys_getpid (line 140) | static void sys_getpid(void)
  function sys_isatty (line 146) | static void sys_isatty(int fildes)
  function sys_kill (line 166) | static void sys_kill(pid_t pid, int sig)
  function sys_link (line 173) | static void sys_link(const char *oldpath, const char *newpath)
  function sys_lseek (line 183) | static void sys_lseek(int fildes, off_t offset, int whence)
  function sys_open (line 204) | static void sys_open(const char *path, int oflags, mode_t mode)
  function sys_read (line 262) | static void sys_read(int fildes, void *buf, size_t nbytes)
  function sys_sbrk (line 277) | static void sys_sbrk(ptrdiff_t incr)
  function sys_stat (line 291) | static void sys_stat(const char *path, struct stat *buf)
  function sys_times (line 308) | static void sys_times()
  function sys_unlink (line 313) | static void sys_unlink(const char *path)
  function sys_waitpid (line 323) | static void sys_waitpid(int pid, int *stat_loc, int options)
  function sys_write (line 410) | static void sys_write(int fd, void *buf, size_t nbytes)
  function sys_ioctl (line 425) | static void sys_ioctl(int fd, int request, void *argp)
  function sys_sigaction (line 441) | static void sys_sigaction(int sig, const struct sigaction *act, struct s...
  function sys_readdir (line 460) | static void sys_readdir(int fd, struct dirent *dirent)
  type mount_struct (line 475) | struct mount_struct {
  function sys_mount (line 482) | static void sys_mount(struct mount_struct *args)
  function sys_mkdir (line 502) | static void sys_mkdir(const char *path, mode_t mode)
  function sys_uname (line 513) | static void sys_uname(struct utsname *name)
  function sys_pipe (line 529) | static void sys_pipe(int fd[2])
  function sys_fcntl (line 540) | static void sys_fcntl(int fd, int cmd, uintptr_t arg)
  function sys_chdir (line 575) | static void sys_chdir(const char *path)
  function sys_getcwd (line 606) | static void sys_getcwd(char *buf, size_t size)
  type __uthread (line 626) | struct __uthread {
  function sys_thread_create (line 634) | static void sys_thread_create(struct __uthread *__uthread)
  function sys_thread_exit (line 647) | static void sys_thread_exit(void *value_ptr)
  function sys_thread_join (line 664) | static void sys_thread_join(int tid, void **value_ptr)
  function sys_setpgid (line 700) | static void sys_setpgid(pid_t pid, pid_t pgid)
  function sys_mknod (line 712) | static void sys_mknod(const char *path, uint32_t mode, uint32_t dev)
  function sys_lstat (line 720) | static void sys_lstat(const char *path, struct stat *buf)
  function sys_auth (line 738) | static void sys_auth(uint32_t uid, const char *pw)
  function sys_getuid (line 746) | static void sys_getuid(void)
  function sys_getgid (line 752) | static void sys_getgid(void)
  type mmap_args (line 758) | struct mmap_args {
  function sys_mmap (line 767) | static void sys_mmap(struct mmap_args *args, void **ret)
  function sys_munmap (line 834) | static void sys_munmap(void *addr, size_t len)
  function sys_socket (line 857) | static void sys_socket(int domain, int type, int protocol)
  function sys_accept (line 883) | static void sys_accept(int fd, const struct sockaddr *addr, uint32_t *len)
  function sys_bind (line 914) | static void sys_bind(int fd, const struct sockaddr *addr, uint32_t len)
  function sys_connect (line 942) | static void sys_connect(int fd, const struct sockaddr *addr, uint32_t len)
  function sys_listen (line 964) | static void sys_listen(int fd, int backlog)
  type socket_io_syscall (line 991) | struct socket_io_syscall {
  function sys_send (line 998) | static void sys_send(struct socket_io_syscall *s)
  function sys_recv (line 1031) | static void sys_recv(struct socket_io_syscall *s)
  function sys_umask (line 1064) | static void sys_umask(mode_t mask)
  function sys_chmod (line 1075) | static void sys_chmod(const char *path, mode_t mode)
  function sys_sysconf (line 1081) | static void sys_sysconf(int name)
  function sys_access (line 1092) | static void sys_access(const char *path, int mode)
  function sys_gettimeofday (line 1130) | static void sys_gettimeofday(struct timeval *tv, struct timezone *tz)
  function sys_sigmask (line 1137) | static void sys_sigmask(int how, void *set, void *oldset)
  type fd_mask (line 1143) | typedef unsigned long fd_mask;
  type fd_set (line 1149) | typedef struct {
  type select_args (line 1153) | struct select_args {
  function sys_select (line 1161) | static void sys_select(struct select_args *args)
  function sys_getpgrp (line 1198) | static void sys_getpgrp(void)
  function sys_chown (line 1204) | static void sys_chown(const char *path, uid_t owner, gid_t group)
  function sys_fchown (line 1210) | static void sys_fchown(int fd, uid_t owner, gid_t group)
  function sys_lchown (line 1216) | static void sys_lchown(const char *path, uid_t owner, gid_t group)
  function sys_utime (line 1222) | static void sys_utime(const char *path, const struct utimbuf *times)
  function sys_rmdir (line 1228) | static void sys_rmdir(const char *path)

FILE: kernel/sys/thread.c
  function thread_new (line 10) | int thread_new(struct proc *proc, struct thread **ref)
  function thread_kill (line 31) | int thread_kill(struct thread *thread)
  function thread_queue_sleep (line 42) | int thread_queue_sleep(struct queue *queue)
  function thread_queue_wakeup (line 71) | int thread_queue_wakeup(struct queue *queue)
  function thread_create (line 88) | int thread_create(struct thread *thread, uintptr_t stack, uintptr_t entr...

FILE: system/aqbox/aqbox.c
  function usage (line 10) | static void usage()
  function bsearch_helper (line 21) | static int bsearch_helper(const void *a, const void *b)
  type applet (line 31) | struct applet
  type applet (line 31) | struct applet
  type applet (line 32) | struct applet
  function aqbox_run (line 37) | int aqbox_run(int argc, char **argv)
  function main (line 49) | int main(int argc, char *argv[])

FILE: system/aqbox/extra/bim.c
  type char_t (line 143) | typedef struct {
  type line_t (line 154) | typedef struct {
  function bim_unget (line 235) | void bim_unget(int c) {
  function bim_getch_timeout (line 240) | int bim_getch_timeout(int timeout) {
  type history_t (line 282) | typedef struct history {
  type buffer_t (line 315) | typedef struct _env {
  function buffer_t (line 366) | buffer_t * buffer_new(void) {
  function buffer_t (line 384) | buffer_t * buffer_close(buffer_t * buf) {
  function load_colorscheme_ansi (line 424) | void load_colorscheme_ansi(void) {
  function load_colorscheme_wombat (line 457) | void load_colorscheme_wombat(void) {
  function load_colorscheme_citylights (line 491) | void load_colorscheme_citylights(void) {
  function load_colorscheme_solarized_dark (line 525) | void load_colorscheme_solarized_dark(void) {
  function load_colorscheme_sunsmoke256 (line 559) | void load_colorscheme_sunsmoke256(void) {
  function load_colorscheme_sunsmoke (line 592) | void load_colorscheme_sunsmoke(void) {
  type theme_def (line 628) | struct theme_def {
  function syn_c_iskeywordchar (line 645) | int syn_c_iskeywordchar(int c) {
  function syn_c_extended (line 676) | static int syn_c_extended(line_t * line, int i, int c, int last, int * o...
  function syn_c_finish (line 775) | static int syn_c_finish(line_t * line, int * left, int state) {
  function syn_py_extended (line 815) | static int syn_py_extended(line_t * line, int i, int c, int last, int * ...
  function syn_py_finish (line 930) | static int syn_py_finish(line_t * line, int * left, int state) {
  function variable_char (line 971) | static int variable_char(uint8_t c) {
  function syn_sh_extended (line 980) | static int syn_sh_extended(line_t * line, int i, int c, int last, int * ...
  function syn_sh_iskeywordchar (line 1042) | static int syn_sh_iskeywordchar(int c) {
  function syn_make_extended (line 1071) | static int syn_make_extended(line_t * line, int i, int c, int last, int ...
  function syn_bimrc_extended (line 1139) | static int syn_bimrc_extended(line_t * line, int i, int c, int last, int...
  function syn_gitcommit_extended (line 1150) | static int syn_gitcommit_extended(line_t * line, int i, int c, int last,...
  function syn_gitrebase_extended (line 1170) | static int syn_gitrebase_extended(line_t * line, int i, int c, int last,...
  function syn_diff_extended (line 1204) | static int syn_diff_extended(line_t * line, int i, int c, int last, int ...
  function syn_rust_extended (line 1247) | static int syn_rust_extended(line_t * line, int i, int c, int last, int ...
  function syn_rust_finish (line 1324) | static int syn_rust_finish(line_t * line, int * left, int state) {
  function syn_conf_extended (line 1342) | static int syn_conf_extended(line_t * line, int i, int c, int last, int ...
  type syntax_definition (line 1373) | struct syntax_definition {
  function check_line (line 1399) | int check_line(line_t * line, int c, char * str, int last) {
  function recalculate_syntax (line 1413) | void recalculate_syntax(line_t * line, int offset) {
  function recalculate_tabs (line 1539) | void recalculate_tabs(line_t * line) {
  function recursive_history_free (line 1558) | void recursive_history_free(history_t * root) {
  function set_history_break (line 1593) | void set_history_break(void) {
  function line_t (line 1606) | line_t * line_insert(line_t * line, char_t c, int offset, int lineno) {
  function line_delete (line 1650) | void line_delete(line_t * line, int offset, int lineno) {
  function line_replace (line 1679) | void line_replace(line_t * line, char_t _c, int offset, int lineno) {
  function line_t (line 1702) | line_t ** remove_line(line_t ** lines, int offset) {
  function line_t (line 1738) | line_t ** add_line(line_t ** lines, int offset) {
  function replace_line (line 1781) | void replace_line(line_t ** lines, int offset, line_t * replacement) {
  function line_t (line 1810) | line_t ** merge_lines(line_t ** lines, int lineb) {
  function line_t (line 1863) | line_t ** split_line(line_t ** lines, int line, int split) {
  function add_indent (line 1928) | void add_indent(int new_line, int old_line, int ignore_brace) {
  function setup_buffer (line 1985) | void setup_buffer(buffer_t * env) {
  type termios (line 2022) | struct termios
  function get_initial_termios (line 2023) | void get_initial_termios(void) {
  function set_unbuffered (line 2027) | void set_unbuffered(void) {
  function set_buffered (line 2035) | void set_buffered(void) {
  function to_eight (line 2042) | int to_eight(uint32_t codepoint, char * out) {
  function codepoint_width (line 2080) | int codepoint_width(wchar_t codepoint) {
  function place_cursor (line 2116) | void place_cursor(int x, int y) {
  function set_colors (line 2130) | void set_colors(const char * fg, const char * bg) {
  function set_fg_color (line 2160) | void set_fg_color(const char * fg) {
  function clear_to_end (line 2178) | void clear_to_end(void) {
  function paint_line (line 2191) | void paint_line(const char * bg) {
  function set_bold (line 2204) | void set_bold(void) {
  function set_underline (line 2212) | void set_underline(void) {
  function reset (line 2220) | void reset(void) {
  function clear_screen (line 2228) | void clear_screen(void) {
  function hide_cursor (line 2236) | void hide_cursor(void) {
  function show_cursor (line 2246) | void show_cursor(void) {
  function mouse_enable (line 2256) | void mouse_enable(void) {
  function mouse_disable (line 2266) | void mouse_disable(void) {
  function shift_up (line 2276) | void shift_up(void) {
  function shift_down (line 2283) | void shift_down(void) {
  function set_alternate_screen (line 2290) | void set_alternate_screen(void) {
  function unset_alternate_screen (line 2299) | void unset_alternate_screen(void) {
  function draw_tab_name (line 2311) | int draw_tab_name(buffer_t * _env, char * out) {
  function redraw_tabbar (line 2322) | void redraw_tabbar(void) {
  function log_base_10 (line 2373) | int log_base_10(unsigned int v) {
  function render_line (line 2389) | void render_line(line_t * line, int width, int offset) {
  function num_width (line 2572) | int num_width(void) {
  function draw_line_number (line 2581) | void draw_line_number(int x) {
  function redraw_line (line 2597) | void redraw_line(int j, int x) {
  function draw_excess_line (line 2626) | void draw_excess_line(int j) {
  function redraw_text (line 2637) | void redraw_text(void) {
  function redraw_statusbar (line 2665) | void redraw_statusbar(void) {
  function redraw_commandline (line 2734) | void redraw_commandline(void) {
  function render_commandline_message (line 2774) | void render_commandline_message(char * message, ...) {
  function redraw_all (line 2803) | void redraw_all(void) {
  function update_title (line 2813) | void update_title(void) {
  function set_modified (line 2828) | void set_modified(void) {
  function render_status_message (line 2844) | void render_status_message(char * message, ...) {
  function render_error (line 2873) | void render_error(char * message, ...) {
  function is_paren (line 2900) | int is_paren(int c) {
  function highlight_matching_paren (line 2916) | void highlight_matching_paren(void) {
  function place_cursor_actual (line 2956) | void place_cursor_actual(void) {
  function update_screen_size (line 3025) | void update_screen_size(void) {
  function SIGWINCH_handler (line 3035) | void SIGWINCH_handler(int sig) {
  function SIGTSTP_handler (line 3046) | void SIGTSTP_handler(int sig) {
  function SIGCONT_handler (line 3060) | void SIGCONT_handler(int sig) {
  function goto_line (line 3073) | void goto_line(int line) {
  function decode (line 3097) | static inline uint32_t decode(uint32_t* state, uint32_t* codep, uint32_t...
  function add_buffer (line 3138) | void add_buffer(uint8_t * buf, int size) {
  type syntax_definition (line 3164) | struct syntax_definition
  type syntax_definition (line 3165) | struct syntax_definition
  function is_all_numbers (line 3186) | int is_all_numbers(const char * c) {
  function open_file (line 3197) | void open_file(char * file) {
  function quit (line 3310) | void quit(void) {
  function try_quit (line 3324) | void try_quit(void) {
  function previous_tab (line 3342) | void previous_tab(void) {
  function next_tab (line 3365) | void next_tab(void) {
  function write_file (line 3386) | void write_file(char * file) {
  function close_buffer (line 3435) | void close_buffer(void) {
  function set_preferred_column (line 3456) | void set_preferred_column(void) {
  function cursor_down (line 3467) | void cursor_down(void) {
  function cursor_up (line 3552) | void cursor_up(void) {
  function cursor_left (line 3635) | void cursor_left(void) {
  function cursor_right (line 3651) | void cursor_right(void) {
  function cursor_home (line 3669) | void cursor_home(void) {
  function cursor_end (line 3686) | void cursor_end(void) {
  function leave_insert (line 3703) | void leave_insert(void) {
  function process_command (line 3717) | void process_command(char * cmd) {
  function command_tab_complete (line 3983) | void command_tab_complete(char * buffer) {
  function command_mode (line 4215) | void command_mode(void) {
  function search_matches (line 4262) | int search_matches(uint32_t a, uint32_t b, int mode) {
  function smart_case (line 4271) | int smart_case(uint32_t * str) {
  function find_match (line 4288) | void find_match(int from_line, int from_col, int * out_line, int * out_c...
  function find_match_backwards (line 4319) | void find_match_backwards(int from_line, int from_col, int * out_line, i...
  function draw_search_match (line 4351) | void draw_search_match(uint32_t * buffer, int redraw_buffer) {
  function search_mode (line 4393) | void search_mode(int direction) {
  function search_next (line 4511) | void search_next(void) {
  function search_prev (line 4531) | void search_prev(void) {
  function find_matching_paren (line 4558) | void find_matching_paren(int * out_line, int * out_col) {
  function handle_mouse (line 4625) | void handle_mouse(void) {
  function insert_char (line 4701) | void insert_char(unsigned int c) {
  function replace_char (line 4722) | void replace_char(unsigned int c) {
  function undo_history (line 4739) | void undo_history(void) {
  function redo_history (line 4865) | void redo_history(void) {
  function word_left (line 4993) | void word_left(void) {
  function word_right (line 5035) | void word_right(void) {
  function delete_at_cursor (line 5083) | void delete_at_cursor(void) {
  function delete_word (line 5105) | void delete_word(void) {
  function insert_line_feed (line 5128) | void insert_line_feed(void) {
  function yank_lines (line 5147) | void yank_lines(int start, int end) {
  function yank_partial_line (line 5182) | void yank_partial_line(int yank_no, int line_no, int start_off, int coun...
  function yank_text (line 5196) | void yank_text(int start_line, int start_col, int end_line, int end_col) {
  function handle_escape (line 5232) | int handle_escape(int * this_buf, int * timeout, int c) {
  function handle_navigation (line 5347) | void handle_navigation(int c) {
  function adjust_indent (line 5461) | void adjust_indent(int start_line, int direction) {
  function line_selection_mode (line 5518) | void line_selection_mode(void) {
  function point_in_range (line 5643) | int point_in_range(int start_line, int end_line, int start_col, int end_...
  function char_selection_mode (line 5709) | char_selection_mode(void) {
  function insert_mode (line 5868) | void insert_mode(void) {
  function replace_mode (line 6005) | void replace_mode(void) {
  function normal_mode (line 6087) | void normal_mode(void) {
  function show_usage (line 6252) | static void show_usage(char * argv[]) {
  function load_bimrc (line 6286) | void load_bimrc(void) {
  function detect_weird_terminals (line 6379) | void detect_weird_terminals(void) {
  function initialize (line 6418) | void initialize(void) {
  function init_terminal (line 6432) | void init_terminal(void) {
  function AQBOX_APPLET (line 6445) | AQBOX_APPLET(bim)(int argc, char * argv[]) {

FILE: system/aqbox/extra/clear.c
  function AQBOX_APPLET (line 4) | AQBOX_APPLET(clear)(int argc, char *argv[])

FILE: system/aqbox/extra/mknod.c
  function mknod_usage (line 8) | void mknod_usage()
  function AQBOX_APPLET (line 13) | AQBOX_APPLET(mknod)(int argc, char **argv)

FILE: system/aqbox/extra/mktemp.c
  function usage (line 8) | static void usage()
  function AQBOX_APPLET (line 13) | AQBOX_APPLET(mktemp)(int argc, char **argv)

FILE: system/aqbox/extra/readmbr.c
  type part (line 112) | struct part {
  type mbr (line 129) | struct mbr {
  function readmbr (line 141) | static int readmbr(const char *path)
  function AQBOX_APPLET (line 177) | AQBOX_APPLET(readmbr)(int argc, char *argv[])

FILE: system/aqbox/extra/stat.c
  function AQBOX_APPLET (line 11) | AQBOX_APPLET(stat)(int argc, char *argv[])

FILE: system/aqbox/extra/truncate.c
  function truncate_usage (line 6) | void truncate_usage()
  function AQBOX_APPLET (line 16) | AQBOX_APPLET(truncate)(int argc, char **argv)

FILE: system/aqbox/extra/vmstat.c
  function AQBOX_APPLET (line 13) | AQBOX_APPLET(vmstat)(int argc, char *argv[])

FILE: system/aqbox/include/aq_applets.h
  type applet (line 32) | struct applet {

FILE: system/aqbox/posix/cat.c
  function usage (line 12) | static void usage()
  function do_cat (line 20) | static int do_cat(const char *path)
  function AQBOX_APPLET (line 54) | AQBOX_APPLET(cat)(int argc, char **argv)

FILE: system/aqbox/posix/date.c
  function usage (line 8) | static void usage()
  function AQBOX_APPLET (line 15) | AQBOX_APPLET(date)(int argc, char **argv)

FILE: system/aqbox/posix/echo.c
  function usage (line 9) | static void usage()
  function do_echo (line 16) | static int do_echo(int argc, const char *argv[], int flags)
  function AQBOX_APPLET (line 48) | AQBOX_APPLET(echo)(int argc, char *argv[])

FILE: system/aqbox/posix/env.c
  function usage (line 9) | static void usage(void)
  function __clearenv (line 16) | static void __clearenv(void)
  function print_env (line 21) | static void print_env(void)
  function run (line 29) | static int run(int argc, char *argv[])
  function AQBOX_APPLET (line 42) | AQBOX_APPLET(env)(int argc, char *argv[])

FILE: system/aqbox/posix/kill.c
  function usage (line 7) | static void usage()
  function do_kill (line 14) | static int do_kill(int argc, const char *argv[], int sig)
  function AQBOX_APPLET (line 27) | AQBOX_APPLET(kill)(int argc, char *argv[])

FILE: system/aqbox/posix/ls.c
  type dirent (line 42) | struct dirent
  type stat (line 44) | struct stat
  function print_long_entry (line 74) | int print_long_entry(char *path, char *fn)
  function do_ls (line 137) | int do_ls(char *path, uint32_t flags)
  function ls_usage (line 205) | int ls_usage()
  function AQBOX_APPLET (line 210) | AQBOX_APPLET(ls)(int argc, char **argv)

FILE: system/aqbox/posix/mkdir.c
  function usage (line 6) | static void usage()
  function AQBOX_APPLET (line 13) | AQBOX_APPLET(mkdir)(int argc, char **argv)

FILE: system/aqbox/posix/ps.c
  function print_info (line 6) | void print_info(char *ent)
  function AQBOX_APPLET (line 35) | AQBOX_APPLET(ps)(int argc, char **argv)

FILE: system/aqbox/posix/pwd.c
  function AQBOX_APPLET (line 6) | AQBOX_APPLET(pwd)(int argc, char **argv)

FILE: system/aqbox/posix/sh.c
  function builtin_cd (line 29) | int builtin_cd(int argc, char **argv)
  function builtin_export (line 56) | int builtin_export(int argc, char **argv)
  function builtin_exit (line 65) | int builtin_exit(int argc, char **argv)
  function builtin_true (line 70) | int builtin_true(int argc, char **argv)
  function builtin_set (line 75) | int builtin_set(int argc, char **argv)
  function builtin_glob (line 86) | int builtin_glob(int argc, char **argv)
  type aqsh_command (line 104) | struct aqsh_command {
  function bsearch_helper (line 118) | static int bsearch_helper(const void *a, const void *b)
  type aqsh_command (line 128) | struct aqsh_command
  type aqsh_command (line 128) | struct aqsh_command
  type aqsh_command (line 129) | struct aqsh_command
  function print_prompt (line 144) | void print_prompt()
  function run_prog (line 151) | int run_prog(char *name, char **argv, int wait)
  type KEY_ACTION (line 183) | enum KEY_ACTION {
  function read_key (line 210) | int read_key(int fd)
  type termios (line 262) | struct termios
  type termios (line 268) | struct termios
  function eval (line 380) | int eval(char *buf)
  function sigpass (line 461) | void sigpass(int s)
  function shell (line 466) | void shell()
  function shell_batch (line 485) | void shell_batch(const char *path)
  function AQBOX_APPLET (line 506) | AQBOX_APPLET(sh)(int argc, char **argv)

FILE: system/aqbox/posix/touch.c
  function usage (line 8) | static void usage()
  function do_touch (line 15) | static int do_touch(int argc, const char *argv[], int flags)
  function AQBOX_APPLET (line 35) | AQBOX_APPLET(touch)(int argc, char *argv[])

FILE: system/aqbox/posix/uname.c
  function AQBOX_APPLET (line 14) | AQBOX_APPLET(uname)(int argc, char **argv)

FILE: system/aqbox/posix/unlink.c
  function AQBOX_APPLET (line 5) | AQBOX_APPLET(unlink)(int argc, char **argv)

FILE: system/aqbox/sys/getty.c
  function AQBOX_APPLET (line 5) | AQBOX_APPLET(getty)(int argc, char **argv)

FILE: system/aqbox/sys/login.c
  function AQBOX_APPLET (line 16) | AQBOX_APPLET(login)(int argc, char **argv)

FILE: system/aqbox/sys/mount.c
  function usage (line 6) | void usage(char *name)
  function AQBOX_APPLET (line 12) | AQBOX_APPLET(mount)(int argc, char **argv)

FILE: system/aqbox/sys/reboot.c
  function AQBOX_APPLET (line 4) | AQBOX_APPLET(reboot)(int argc, char **argv)

FILE: system/fbterm/aqkb.c
  type fbterm_ctx (line 40) | struct fbterm_ctx
  function handle_keyboard (line 42) | void handle_keyboard(int fd, int scancode)
  type fbterm_ctx (line 135) | struct fbterm_ctx

FILE: system/fbterm/fb.c
  type fb_fix_screeninfo (line 16) | struct fb_fix_screeninfo
  type fb_var_screeninfo (line 17) | struct fb_var_screeninfo
  function fb_put_pixel (line 28) | void fb_put_pixel(struct fbterm_ctx *ctx, int x, int y, uint32_t fg, uin...
  function fb_clear (line 43) | void fb_clear(struct fbterm_ctx *ctx)
  function fb_rect_clear (line 52) | void fb_rect_clear(struct fbterm_ctx *ctx, size_t x0, size_t x1, size_t ...
  function fb_rect_move (line 67) | void fb_rect_move(struct fbterm_ctx *ctx, size_t dx0, size_t dx1, size_t...
  function fb_render (line 98) | void fb_render(struct fbterm_ctx *ctx)
  function fb_term_init (line 103) | void fb_term_init(struct fbterm_ctx *ctx)
  function fb_cook_wallpaper (line 112) | int fb_cook_wallpaper(struct fbterm_ctx *ctx, char *path)
  function fb_debug (line 181) | void fb_debug(char r, char g, char b)
  function fb_init (line 198) | int fb_init(const char *path)

FILE: system/fbterm/fbterm.c
  function debug_init (line 25) | int debug_init()
  function debug (line 31) | int debug(int level, const char *fmt, ...)
  type fbterm_ctx (line 49) | struct fbterm_ctx
  function fbterm_putc (line 52) | static void fbterm_putc(struct fbterm_ctx *ctx, int row, int col, char c...
  function fbterm_set_cursor (line 69) | void fbterm_set_cursor(struct fbterm_ctx *ctx, int row, int col)
  function fbterm_clear (line 75) | void fbterm_clear(struct fbterm_ctx *ctx)
  function fbterm_rect_clear (line 80) | void fbterm_rect_clear(struct fbterm_ctx *ctx, int r0, int r1, int c0, i...
  function fbterm_rect_move (line 90) | void fbterm_rect_move(struct fbterm_ctx *ctx, int dr0, int dr1, int dc0,...
  function fbterm_cursor_draw (line 106) | void fbterm_cursor_draw(struct fbterm_ctx *ctx, int row, int col)
  function fbterm_redraw (line 118) | void fbterm_redraw(struct fbterm_ctx *ctx)
  function damage (line 139) | int damage(VTermRect rect, void *user)
  function moverect (line 162) | int moverect(VTermRect dest, VTermRect src, void *user)
  function movecursor (line 180) | int movecursor(VTermPos pos, VTermPos oldpos, int visible, void *user)
  function settermprop (line 200) | int settermprop(VTermProp prop, VTermValue *val, void *user)
  function bell (line 205) | int bell(void *user)
  function resize (line 210) | int resize(int rows, int cols, void *user)
  function sb_pushline (line 215) | int sb_pushline(int cols, const VTermScreenCell *cells, void *user)
  function sb_popline (line 220) | int sb_popline(int cols, VTermScreenCell *cells, void *user)
  type font (line 225) | struct font
  function fbterm_init (line 237) | int fbterm_init(struct fbterm_ctx *ctx)
  function fbterm_main (line 269) | int fbterm_main()
  function launch_shell (line 302) | void launch_shell()
  function main (line 330) | int main(int argc, char **argv)

FILE: system/fbterm/font.c
  type font (line 17) | struct font
  type font (line 19) | struct font
  type tinyfont (line 20) | struct tinyfont
  function find_glyph (line 45) | static int find_glyph(struct font *font, int c)
  function font_bitmap (line 61) | int font_bitmap(struct font *font, void *dst, int c)
  function font_free (line 71) | void font_free(struct font *font)
  function font_rows (line 80) | int font_rows(struct font *font)
  function font_cols (line 85) | int font_cols(struct font *font)

FILE: system/fbterm/include/fb.h
  type fb_fix_screeninfo (line 13) | struct fb_fix_screeninfo {
  type fb_bitfield (line 34) | struct fb_bitfield {
  type fb_var_screeninfo (line 40) | struct fb_var_screeninfo {
  type fbterm_ctx (line 79) | struct fbterm_ctx
  type fbterm_ctx (line 80) | struct fbterm_ctx
  type fbterm_ctx (line 81) | struct fbterm_ctx
  type fbterm_ctx (line 82) | struct fbterm_ctx
  type fbterm_ctx (line 84) | struct fbterm_ctx
  type fbterm_ctx (line 85) | struct fbterm_ctx
  type fbterm_ctx (line 86) | struct fbterm_ctx

FILE: system/fbterm/include/fbterm.h
  type fbterm_ctx (line 8) | struct fbterm_ctx {
  type fbterm_ctx (line 29) | struct fbterm_ctx
  type fbterm_ctx (line 30) | struct fbterm_ctx
  type fbterm_ctx (line 31) | struct fbterm_ctx

FILE: system/fbterm/include/tinyfont.h
  type font (line 4) | struct font {
  type tinyfont (line 17) | struct tinyfont {
  type font (line 25) | struct font
  type font (line 26) | struct font
  type font (line 27) | struct font
  type font (line 28) | struct font
  type font (line 29) | struct font

FILE: system/fbterm/include/vterm.h
  type VTerm (line 14) | typedef struct VTerm VTerm;
  type VTermState (line 15) | typedef struct VTermState VTermState;
  type VTermScreen (line 16) | typedef struct VTermScreen VTermScreen;
  type VTermPos (line 18) | typedef struct {
  function vterm_pos_cmp (line 26) | static inline int vterm_pos_cmp(VTermPos a, VTermPos b)
  type VTermRect (line 31) | typedef struct {
  function vterm_rect_contains (line 39) | static inline int vterm_rect_contains(VTermRect r, VTermPos p)
  function vterm_rect_move (line 46) | static inline void vterm_rect_move(VTermRect *rect, int row_delta, int c...
  type VTermColor (line 52) | typedef struct {
  type VTermValueType (line 56) | typedef enum {
  type VTermValue (line 66) | typedef union {
  type VTermAttr (line 73) | typedef enum {
  type VTermProp (line 88) | typedef enum {
  type VTermGlyphInfo (line 119) | typedef struct {
  type VTermLineInfo (line 127) | typedef struct {
  type VTermAllocatorFunctions (line 132) | typedef struct {
  type VTermParserCallbacks (line 191) | typedef struct {
  type VTermStateCallbacks (line 208) | typedef struct {
  type VTermScreenCellAttrs (line 248) | typedef struct {
  type VTermScreenCell (line 260) | typedef struct {
  type VTermScreenCallbacks (line 268) | typedef struct {
  type VTermDamageSize (line 290) | typedef enum {
  type VTermAttrMask (line 308) | typedef enum {

FILE: system/fbterm/include/vterm_keycodes.h
  type VTermModifier (line 4) | typedef enum {
  type VTermKey (line 13) | typedef enum {

FILE: system/fbterm/libvterm/encoding.c
  type UTF8DecoderData (line 9) | struct UTF8DecoderData {
  function init_utf8 (line 20) | static void init_utf8(VTermEncoding *enc, void *data_)
  function decode_utf8 (line 28) | static void decode_utf8(VTermEncoding *enc, void *data_,
  function decode_usascii (line 162) | static void decode_usascii(VTermEncoding *enc, void *data,
  type StaticTableEncoding (line 182) | struct StaticTableEncoding {
  function decode_table (line 187) | static void decode_table(VTermEncoding *enc, void *data,
  function VTermEncoding (line 224) | VTermEncoding *vterm_lookup_encoding(VTermEncodingType type, char design...

FILE: system/fbterm/libvterm/keyboard.c
  function vterm_keyboard_unichar (line 7) | void vterm_keyboard_unichar(VTerm *vt, uint32_t c, VTermModifier mod)
  type keycodes_s (line 54) | typedef struct {
  function vterm_keyboard_key (line 128) | void vterm_keyboard_key(VTerm *vt, VTermKey key, VTermModifier mod)
  function vterm_keyboard_start_paste (line 216) | void vterm_keyboard_start_paste(VTerm *vt)
  function vterm_keyboard_end_paste (line 222) | void vterm_keyboard_end_paste(VTerm *vt)

FILE: system/fbterm/libvterm/mouse.c
  function output_mouse (line 5) | static void output_mouse(VTermState *state, int code, int pressed, int m...
  function vterm_mouse_move (line 54) | void vterm_mouse_move(VTerm *vt, int row, int col, VTermModifier mod)
  function vterm_mouse_button (line 73) | void vterm_mouse_button(VTerm *vt, int button, bool pressed, VTermModifi...

FILE: system/fbterm/libvterm/parser.c
  function is_intermed (line 8) | static bool is_intermed(unsigned char c)
  function do_control (line 13) | static void do_control(VTerm *vt, unsigned char control)
  function do_csi (line 22) | static void do_csi(VTerm *vt, char command)
  function do_escape (line 48) | static void do_escape(VTerm *vt, char command)
  function append_strbuffer (line 64) | static void append_strbuffer(VTerm *vt, const char *str, size_t len)
  function start_string (line 77) | static void start_string(VTerm *vt, VTermParserStringType type)
  function more_string (line 84) | static void more_string(VTerm *vt, const char *str, size_t len)
  function done_string (line 89) | static void done_string(VTerm *vt, const char *str, size_t len)
  function vterm_input_write (line 125) | size_t vterm_input_write(VTerm *vt, const char *bytes, size_t len)
  function vterm_parser_set_callbacks (line 332) | void vterm_parser_set_callbacks(VTerm *vt, const VTermParserCallbacks *c...

FILE: system/fbterm/libvterm/pen.c
  function lookup_colour_ansi (line 36) | static bool lookup_colour_ansi(const VTermState *state, long index, VTer...
  function lookup_colour_palette (line 46) | static bool lookup_colour_palette(const VTermState *state, long index, V...
  function lookup_colour (line 76) | static int lookup_colour(const VTermState *state, int palette, const lon...
  function setpenattr (line 105) | static void setpenattr(VTermState *state, VTermAttr attr, VTermValueType...
  function setpenattr_bool (line 118) | static void setpenattr_bool(VTermState *state, VTermAttr attr, int boolean)
  function setpenattr_int (line 124) | static void setpenattr_int(VTermState *state, VTermAttr attr, int number)
  function setpenattr_col (line 130) | static void setpenattr_col(VTermState *state, VTermAttr attr, VTermColor...
  function set_pen_col_ansi (line 136) | static void set_pen_col_ansi(VTermState *state, VTermAttr attr, long col)
  function INTERNAL (line 145) | INTERNAL void vterm_state_newpen(VTermState *state)
  function INTERNAL (line 155) | INTERNAL void vterm_state_resetpen(VTermState *state)
  function INTERNAL (line 171) | INTERNAL void vterm_state_savepen(VTermState *state, int save)
  function vterm_state_get_default_colors (line 191) | void vterm_state_get_default_colors(const VTermState *state, VTermColor ...
  function vterm_state_get_palette_color (line 197) | void vterm_state_get_palette_color(const VTermState *state, int index, V...
  function vterm_state_set_default_colors (line 202) | void vterm_state_set_default_colors(VTermState *state, const VTermColor ...
  function vterm_state_set_palette_color (line 208) | void vterm_state_set_palette_color(VTermState *state, int index, const V...
  function vterm_state_set_bold_highbright (line 214) | void vterm_state_set_bold_highbright(VTermState *state, int bold_is_high...
  function INTERNAL (line 219) | INTERNAL void vterm_state_setpen(VTermState *state, const long args[], i...
  function INTERNAL (line 382) | INTERNAL int vterm_state_getpen(VTermState *state, long args[], int argc...
  function vterm_state_get_penattr (line 457) | int vterm_state_get_penattr(const VTermState *state, VTermAttr attr, VTe...

FILE: system/fbterm/libvterm/rect.h
  function rect_expand (line 9) | static void rect_expand(VTermRect *dst, VTermRect *src)
  function rect_clip (line 18) | static void rect_clip(VTermRect *dst, VTermRect *bounds)
  function rect_equal (line 30) | static int rect_equal(VTermRect *a, VTermRect *b)
  function rect_contains (line 39) | static int rect_contains(VTermRect *big, VTermRect *small)
  function rect_intersects (line 49) | static int rect_intersects(VTermRect *a, VTermRect *b)

FILE: system/fbterm/libvterm/screen.c
  type ScreenPen (line 13) | typedef struct
  type ScreenCell (line 33) | typedef struct
  type VTermScreen (line 41) | struct VTermScreen
  function ScreenCell (line 71) | static inline ScreenCell *getcell(const VTermScreen *screen, int row, in...
  function ScreenCell (line 80) | static ScreenCell *realloc_buffer(VTermScreen *screen, ScreenCell *buffe...
  function damagerect (line 103) | static void damagerect(VTermScreen *screen, VTermRect rect)
  function damagescreen (line 160) | static void damagescreen(VTermScreen *screen)
  function putglyph (line 172) | static int putglyph(VTermGlyphInfo *info, VTermPos pos, void *user)
  function moverect_internal (line 207) | static int moverect_internal(VTermRect dest, VTermRect src, void *user)
  function moverect_user (line 247) | static int moverect_user(VTermRect dest, VTermRect src, void *user)
  function erase_internal (line 265) | static int erase_internal(VTermRect rect, int selective, void *user)
  function erase_user (line 288) | static int erase_user(VTermRect rect, int selective, void *user)
  function erase (line 297) | static int erase(VTermRect rect, int selective, void *user)
  function scrollrect (line 303) | static int scrollrect(VTermRect rect, int downward, int rightward, void ...
  function movecursor (line 387) | static int movecursor(VTermPos pos, VTermPos oldpos, int visible, void *...
  function setpenattr (line 397) | static int setpenattr(VTermAttr attr, VTermValue *val, void *user)
  function settermprop (line 437) | static int settermprop(VTermProp prop, VTermValue *val, void *user)
  function bell (line 467) | static int bell(void *user)
  function resize (line 477) | static int resize(int new_rows, int new_cols, VTermPos *delta, void *user)
  function setlineinfo (line 579) | static int setlineinfo(int row, const VTermLineInfo *newinfo, const VTer...
  function VTermScreen (line 622) | static VTermScreen *screen_new(VTerm *vt)
  function INTERNAL (line 657) | INTERNAL void vterm_screen_free(VTermScreen *screen)
  function vterm_screen_reset (line 668) | void vterm_screen_reset(VTermScreen *screen, int hard)
  function _get_chars (line 676) | static size_t _get_chars(const VTermScreen *screen, const int utf8, void...
  function vterm_screen_get_chars (line 726) | size_t vterm_screen_get_chars(const VTermScreen *screen, uint32_t *chars...
  function vterm_screen_get_text (line 731) | size_t vterm_screen_get_text(const VTermScreen *screen, char *str, size_...
  function vterm_screen_get_cell (line 737) | int vterm_screen_get_cell(const VTermScreen *screen, VTermPos pos, VTerm...
  function vterm_screen_set_cell (line 774) | static int vterm_screen_set_cell(VTermScreen *screen, VTermPos pos, cons...
  function vterm_screen_is_eol (line 803) | int vterm_screen_is_eol(const VTermScreen *screen, VTermPos pos)
  function VTermScreen (line 815) | VTermScreen *vterm_obtain_screen(VTerm *vt)
  function vterm_screen_enable_altscreen (line 826) | void vterm_screen_enable_altscreen(VTermScreen *screen, int altscreen)
  function vterm_screen_set_callbacks (line 837) | void vterm_screen_set_callbacks(VTermScreen *screen, const VTermScreenCa...
  function vterm_screen_set_unrecognised_fallbacks (line 848) | void vterm_screen_set_unrecognised_fallbacks(VTermScreen *screen, const ...
  function vterm_screen_flush_damage (line 858) | void vterm_screen_flush_damage(VTermScreen *screen)
  function vterm_screen_set_damage_merge (line 875) | void vterm_screen_set_damage_merge(VTermScreen *screen, VTermDamageSize ...
  function attrs_differ (line 881) | static int attrs_differ(VTermAttrMask attrs, ScreenCell *a, ScreenCell *b)
  function vterm_screen_get_attrs_extent (line 905) | int vterm_screen_get_attrs_extent(const VTermScreen *screen, VTermRect *...

FILE: system/fbterm/libvterm/state.c
  function putglyph (line 14) | static void putglyph(VTermState *state, const uint32_t chars[], int widt...
  function updatecursor (line 31) | static void updatecursor(VTermState *state, VTermPos *oldpos, int cancel...
  function erase (line 44) | static void erase(VTermState *state, VTermRect rect, int selective)
  function VTermState (line 51) | static VTermState *vterm_state_new(VTerm *vt)
  function INTERNAL (line 76) | INTERNAL void vterm_state_free(VTermState *state)
  function scroll (line 84) | static void scroll(VTermState *state, VTermRect rect, int downward, int ...
  function linefeed (line 124) | static void linefeed(VTermState *state)
  function grow_combine_buffer (line 140) | static void grow_combine_buffer(VTermState *state)
  function set_col_tabstop (line 153) | static void set_col_tabstop(VTermState *state, int col)
  function clear_col_tabstop (line 159) | static void clear_col_tabstop(VTermState *state, int col)
  function is_col_tabstop (line 165) | static int is_col_tabstop(VTermState *state, int col)
  function is_cursor_in_scrollregion (line 171) | static int is_cursor_in_scrollregion(const VTermState *state)
  function tab (line 183) | static void tab(VTermState *state, int count, int direction)
  function set_lineinfo (line 214) | static void set_lineinfo(VTermState *state, int row, int force, int dwl,...
  function on_text (line 238) | static int on_text(const char bytes[], size_t len, void *user)
  function on_control (line 408) | static int on_control(unsigned char control, void *user)
  function settermprop_bool (line 507) | static int settermprop_bool(VTermState *state, VTermProp prop, int v)
  function settermprop_int (line 513) | static int settermprop_int(VTermState *state, VTermProp prop, int v)
  function settermprop_string (line 519) | static int settermprop_string(VTermState *state, VTermProp prop, const c...
  function savecursor (line 529) | static void savecursor(VTermState *state, int save)
  function on_escape (line 554) | static int on_escape(const char *bytes, size_t len, void *user)
  function set_mode (line 695) | static void set_mode(VTermState *state, int num, int val)
  function set_dec_mode (line 712) | static void set_dec_mode(VTermState *state, int num, int val)
  function request_dec_mode (line 805) | static void request_dec_mode(VTermState *state, int num)
  function on_csi (line 882) | static int on_csi(const char *leader, const long args[], int argcount, c...
  function on_osc (line 1469) | static int on_osc(const char *command, size_t cmdlen, void *user)
  function request_status_string (line 1496) | static void request_status_string(VTermState *state, const char *command...
  function on_dcs (line 1545) | static int on_dcs(const char *command, size_t cmdlen, void *user)
  function on_resize (line 1560) | static int on_resize(int rows, int cols, void *user)
  function VTermState (line 1649) | VTermState *vterm_obtain_state(VTerm *vt)
  function vterm_state_reset (line 1673) | void vterm_state_reset(VTermState *state, int hard)
  function vterm_state_get_cursorpos (line 1738) | void vterm_state_get_cursorpos(const VTermState *state, VTermPos *cursor...
  function vterm_state_set_callbacks (line 1743) | void vterm_state_set_callbacks(VTermState *state, const VTermStateCallba...
  function vterm_state_set_unrecognised_fallbacks (line 1763) | void vterm_state_set_unrecognised_fallbacks(VTermState *state, const VTe...
  function vterm_state_set_termprop (line 1780) | int vterm_state_set_termprop(VTermState *state, VTermProp prop, VTermVal...
  function vterm_state_focus_in (line 1834) | void vterm_state_focus_in(VTermState *state)
  function vterm_state_focus_out (line 1840) | void vterm_state_focus_out(VTermState *state)
  function VTermLineInfo (line 1846) | const VTermLineInfo *vterm_state_get_lineinfo(const VTermState *state, i...

FILE: system/fbterm/libvterm/unicode.c
  type interval (line 70) | struct interval {
  type interval (line 77) | struct interval
  function bisearch (line 130) | static int bisearch(uint32_t ucs, const struct interval *table, int max) {
  function mk_wcwidth (line 183) | static int mk_wcwidth(uint32_t ucs)
  function mk_wcswidth (line 215) | static int mk_wcswidth(const uint32_t *pwcs, size_t n)
  function mk_wcwidth_cjk (line 238) | static int mk_wcwidth_cjk(uint32_t ucs)
  function mk_wcswidth_cjk (line 306) | static int mk_wcswidth_cjk(const uint32_t *pwcs, size_t n)
  function INTERNAL (line 322) | INTERNAL int vterm_unicode_width(uint32_t codepoint)
  function INTERNAL (line 327) | INTERNAL int vterm_unicode_is_combining(uint32_t codepoint)

FILE: system/fbterm/libvterm/utf8.h
  function utf8_seqlen (line 5) | static inline unsigned int utf8_seqlen(long codepoint)
  function fill_utf8 (line 16) | static int fill_utf8(long codepoint, char *str)

FILE: system/fbterm/libvterm/vterm.c
  function default_free (line 20) | static void default_free(void *ptr, void *allocdata)
  function VTerm (line 30) | VTerm *vterm_new(int rows, int cols)
  function VTerm (line 35) | VTerm *vterm_new_with_allocator(int rows, int cols, VTermAllocatorFuncti...
  function vterm_free (line 62) | void vterm_free(VTerm *vt)
  function INTERNAL (line 76) | INTERNAL void *vterm_allocator_malloc(VTerm *vt, size_t size)
  function INTERNAL (line 81) | INTERNAL void vterm_allocator_free(VTerm *vt, void *ptr)
  function vterm_get_size (line 86) | void vterm_get_size(const VTerm *vt, int *rowsp, int *colsp)
  function vterm_set_size (line 94) | void vterm_set_size(VTerm *vt, int rows, int cols)
  function vterm_get_utf8 (line 103) | int vterm_get_utf8(const VTerm *vt)
  function vterm_set_utf8 (line 108) | void vterm_set_utf8(VTerm *vt, int is_utf8)
  function INTERNAL (line 113) | INTERNAL void vterm_push_output_bytes(VTerm *vt, const char *bytes, size...
  function outbuffer_is_full (line 124) | static int outbuffer_is_full(VTerm *vt)
  function INTERNAL (line 129) | INTERNAL void vterm_push_output_vsprintf(VTerm *vt, const char *format, ...
  function INTERNAL (line 148) | INTERNAL void vterm_push_output_sprintf(VTerm *vt, const char *format, ...)
  function INTERNAL (line 156) | INTERNAL void vterm_push_output_sprintf_ctrl(VTerm *vt, unsigned char ct...
  function INTERNAL (line 174) | INTERNAL void vterm_push_output_sprintf_dcs(VTerm *vt, const char *fmt, ...
  function vterm_output_get_buffer_size (line 194) | size_t vterm_output_get_buffer_size(const VTerm *vt)
  function vterm_output_get_buffer_current (line 199) | size_t vterm_output_get_buffer_current(const VTerm *vt)
  function vterm_output_get_buffer_remaining (line 204) | size_t vterm_output_get_buffer_remaining(const VTerm *vt)
  function vterm_output_read (line 209) | size_t vterm_output_read(VTerm *vt, char *buffer, size_t len)
  function VTermValueType (line 224) | VTermValueType vterm_get_attr_type(VTermAttr attr)
  function VTermValueType (line 242) | VTermValueType vterm_get_prop_type(VTermProp prop)
  function vterm_scroll_rect (line 259) | void vterm_scroll_rect(VTermRect rect,
  function vterm_copy_cells (line 328) | void vterm_copy_cells(VTermRect dest,

FILE: system/fbterm/libvterm/vterm_internal.h
  type VTermEncoding (line 27) | typedef struct VTermEncoding VTermEncoding;
  type VTermEncodingInstance (line 29) | typedef struct {
  type VTermPen (line 36) | struct VTermPen
  function vterm_color_equal (line 49) | static inline int vterm_color_equal(VTermColor a, VTermColor b)
  type VTermState (line 54) | struct VTermState
  type VTermParserStringType (line 148) | typedef enum {
  type VTerm (line 155) | struct VTerm
  type VTermEncoding (line 208) | struct VTermEncoding {
  type VTermEncodingType (line 215) | typedef enum {

FILE: system/fbterm/nanojpeg.c
  type nj_result_t (line 117) | typedef enum _nj_result {
  function main (line 209) | int main(int argc, char* argv[]) {
  type nj_vlc_code_t (line 299) | typedef struct _nj_code {
  type nj_component_t (line 303) | typedef struct _nj_cmp {
  type nj_context_t (line 314) | typedef struct _nj_ctx {
  function njClip (line 340) | NJ_FORCE_INLINE unsigned char njClip(const int x) {
  function NJ_INLINE (line 351) | NJ_INLINE void njRowIDCT(int* blk) {
  function NJ_INLINE (line 396) | NJ_INLINE void njColIDCT(const int* blk, unsigned char *out, int stride) {
  function njShowBits (line 448) | static int njShowBits(int bits) {
  function NJ_INLINE (line 485) | NJ_INLINE void njSkipBits(int bits) {
  function NJ_INLINE (line 491) | NJ_INLINE int njGetBits(int bits) {
  function NJ_INLINE (line 497) | NJ_INLINE void njByteAlign(void) {
  function njSkip (line 501) | static void njSkip(int count) {
  function njDecode16 (line 508) | NJ_INLINE unsigned short njDecode16(const unsigned char *pos) {
  function njDecodeLength (line 512) | static void njDecodeLength(void) {
  function NJ_INLINE (line 519) | NJ_INLINE void njSkipMarker(void) {
  function NJ_INLINE (line 524) | NJ_INLINE void njDecodeSOF(void) {
  function NJ_INLINE (line 578) | NJ_INLINE void njDecodeDHT(void) {
  function NJ_INLINE (line 619) | NJ_INLINE void njDecodeDQT(void) {
  function NJ_INLINE (line 636) | NJ_INLINE void njDecodeDRI(void) {
  function njGetVLC (line 644) | static int njGetVLC(nj_vlc_code_t* vlc, unsigned char* code) {
  function NJ_INLINE (line 659) | NJ_INLINE void njDecodeBlock(nj_component_t* c, unsigned char* out) {
  function NJ_INLINE (line 679) | NJ_INLINE void njDecodeScan(void) {
  function NJ_INLINE (line 737) | NJ_INLINE void njUpsampleH(nj_component_t* c) {
  function NJ_INLINE (line 765) | NJ_INLINE void njUpsampleV(nj_component_t* c) {
  function NJ_INLINE (line 796) | NJ_INLINE void njUpsample(nj_component_t* c) {
  function NJ_INLINE (line 818) | NJ_INLINE void njConvert(void) {
  function njInit (line 869) | void njInit(void) {
  function njDone (line 873) | void njDone(void) {
  function nj_result_t (line 881) | nj_result_t njDecode(const void* jpeg, const int size) {
  function njGetWidth (line 911) | int njGetWidth(void)            { return nj.width; }
  function njGetHeight (line 912) | int njGetHeight(void)           { return nj.height; }
  function njIsColor (line 913) | int njIsColor(void)             { return (nj.ncomp != 1); }
  function njGetImageSize (line 915) | int njGetImageSize(void)        { return nj.width * nj.height * nj.ncomp; }

FILE: system/kilo/kilo.c
  function tcgetattr (line 55) | int tcgetattr(int fd, struct termios *tios)
  function tcsetattr (line 60) | int tcsetattr(int fd, int req, struct termios *tios)
  function getline (line 66) | ssize_t getline(char **lineptr, size_t *n, FILE *stream)
  type editorSyntax (line 88) | struct editorSyntax {
  type erow (line 98) | typedef struct erow {
  type hlcolor (line 109) | typedef struct hlcolor {
  type editorConfig (line 113) | struct editorConfig {
  type editorConfig (line 129) | struct editorConfig
  type KEY_ACTION (line 131) | enum KEY_ACTION{
  type editorSyntax (line 194) | struct editorSyntax
  type termios (line 208) | struct termios
  function disableRawMode (line 210) | void disableRawMode(int fd) {
  function editorAtExit (line 219) | void editorAtExit(void) {
  function enableRawMode (line 224) | int enableRawMode(int fd) {
  function editorReadKey (line 259) | int editorReadKey(int fd) {
  function getCursorPosition (line 313) | int getCursorPosition(int ifd, int ofd, int *rows, int *cols) {
  function getWindowSize (line 337) | int getWindowSize(int ifd, int ofd, int *rows, int *cols) {
  function is_separator (line 372) | int is_separator(int c) {
  function editorRowHasOpenComment (line 379) | int editorRowHasOpenComment(erow *row) {
  function editorUpdateSyntax (line 388) | void editorUpdateSyntax(erow *row) {
  function editorSyntaxToColor (line 526) | int editorSyntaxToColor(int hl) {
  function editorSelectSyntaxHighlight (line 541) | void editorSelectSyntaxHighlight(char *filename) {
  function editorUpdateRow (line 562) | void editorUpdateRow(erow *row) {
  function editorInsertRow (line 590) | void editorInsertRow(int at, char *s, size_t len) {
  function editorFreeRow (line 611) | void editorFreeRow(erow *row) {
  function editorDelRow (line 619) | void editorDelRow(int at) {
  function editorRowInsertChar (line 659) | void editorRowInsertChar(erow *row, int at, int c) {
  function editorRowAppendString (line 682) | void editorRowAppendString(erow *row, char *s, size_t len) {
  function editorRowDelChar (line 692) | void editorRowDelChar(erow *row, int at) {
  function editorInsertChar (line 701) | void editorInsertChar(int c) {
  function editorInsertNewline (line 723) | void editorInsertNewline(void) {
  function editorDelChar (line 759) | void editorDelChar() {
  function editorOpen (line 795) | int editorOpen(char *filename) {
  function editorSave (line 826) | int editorSave(void) {
  type abuf (line 856) | struct abuf {
  function abAppend (line 863) | void abAppend(struct abuf *ab, const char *s, int len) {
  function abFree (line 872) | void abFree(struct abuf *ab) {
  function editorRefreshScreen (line 878) | void editorRefreshScreen(void) {
  function editorSetStatusMessage (line 998) | void editorSetStatusMessage(const char *fmt, ...) {
  function editorFind (line 1010) | void editorFind(int fd) {
  function editorMoveCursor (line 1107) | void editorMoveCursor(int key) {
  function editorProcessKeypress (line 1183) | void editorProcessKeypress(int fd) {
  function editorFileWasModified (line 1252) | int editorFileWasModified(void) {
  function initEditor (line 1256) | void initEditor(void) {
  function main (line 1275) | int main(int argc, char **argv) {
Condensed preview — 453 files, each showing path, character count, and a content snippet. Download the .json file or copy for the full structured content (1,424K chars).
[
  {
    "path": ".gitignore",
    "chars": 256,
    "preview": "*.o\n*.iso\n*.elf\n*.img\n\ntools/\ngraph.sh\ntags\nmnt/\n\nbuild-tools/*\n!build-tools/build.sh\n!build-tools/aquila/\n!build-tools/"
  },
  {
    "path": ".gitlab-ci.yml",
    "chars": 302,
    "preview": "image: manwar/aquila\n\nbuild:\n  stage: build\n  before_script:\n    - apt update && apt -y install make cpio texinfo grub-p"
  },
  {
    "path": ".travis.yml",
    "chars": 1290,
    "preview": "language: c\nbefore_install:\n  - sudo apt-get update -qq\n  - sudo apt-get install -qq texinfo grub-pc-bin xorriso\ninstall"
  },
  {
    "path": "LICENSE",
    "chars": 35141,
    "preview": "                    GNU GENERAL PUBLIC LICENSE\n                       Version 3, 29 June 2007\n\n Copyright (C) 2007 Free "
  },
  {
    "path": "Makefile",
    "chars": 2961,
    "preview": "# This is the top leve Makefile of AquilaOS\n#\n# Targets:\n#\n#  build-kernel     - build kernel image in kernel/{ARCH}/ker"
  },
  {
    "path": "README.md",
    "chars": 1919,
    "preview": "# Aquila OS ![https://travis-ci.org/mohamed-anwar/Aquila](https://api.travis-ci.org/mohamed-anwar/Aquila.svg?branch=mast"
  },
  {
    "path": "configs/clang.mk",
    "chars": 243,
    "preview": "CC := clang\n\nCFLAGS := $(INCLUDES) \\\n\t\t-nostdlib -ffreestanding -m32 \\\n\t\t-O3 -Wall -Wextra -Werror \\\n\t\t-Wno-unused -Wno-"
  },
  {
    "path": "configs/gcc.mk",
    "chars": 322,
    "preview": "CC := i686-aquila-gcc\n\nCFLAGS += \\\n\t\t-nostdlib -ffreestanding -m32 \\\n\t\t-O3 -Wall -Wextra -Werror \\\n\t\t-Wno-unused -Wno-un"
  },
  {
    "path": "configs/i386-pc.mk",
    "chars": 859,
    "preview": "include $(SRCDIR)/configs/gcc.mk\n\n#\n# Configurations\n#\n\nARCH=i386\nARCH_DIR=i386\nARCH_I386=y\nARCH_BITS=32\n\n#\n# Boot Defin"
  },
  {
    "path": "configs/i386-quark.mk",
    "chars": 1115,
    "preview": "#\n# Compilation flags\n#\n\nCC := $(PDIR)/../build-tools/sys/bin/i686-elf-gcc\nCFLAGS := -std=gnu99 -I. -I$(PDIR)/arch/$$(AR"
  },
  {
    "path": "configs/none.mk",
    "chars": 773,
    "preview": "CC := $(PDIR)/../build-tools/sysroot/bin/i686-elf-gcc\nCFLAGS := -std=gnu99 -I. -I$(PDIR)/arch/$$(ARCH_DIR)/chipset/$$(CH"
  },
  {
    "path": "configs/pcc.mk",
    "chars": 386,
    "preview": "CC := /opt/aquila/bin/i686-aquila-pcc\n\nCFLAGS += \\\n\t\t-nostdlib -ffreestanding -m32 \\\n\t\t-O3 -Wall -Wextra -Werror \\\n\t\t-Wn"
  },
  {
    "path": "configs/x86_64-pc.mk",
    "chars": 1140,
    "preview": "#\n# Compilation flags\n#\n\nCC := gcc\nCFLAGS := -std=gnu99 -I. -I$(PDIR)/arch/$$(ARCH_DIR)/chipset/$$(PLATFORM_DIR)/include"
  },
  {
    "path": "initrd/Makefile",
    "chars": 1373,
    "preview": "ROOT= initrd\nDIRS= bin sbin dev mnt proc tmp root\nCOPY= etc usr\n\nAQBOX= aqbox\nAQBOX_BIN= cat clear echo env ls mkdir mkn"
  },
  {
    "path": "initrd/etc/hostname",
    "chars": 7,
    "preview": "aquila\n"
  },
  {
    "path": "initrd/etc/motd",
    "chars": 938,
    "preview": "\n                                               _...__..-'\n                                             .'\n             "
  },
  {
    "path": "initrd/etc/passwd",
    "chars": 30,
    "preview": "root:x:0:0:root:/root:/bin/sh\n"
  },
  {
    "path": "initrd/etc/rc.init",
    "chars": 576,
    "preview": "#!/bin/sh\n\nset -x\nexport PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/libexec:/usr/local/bin:/usr/local/sbin\n\n# Mount devfs o"
  },
  {
    "path": "initrd/init/Makefile",
    "chars": 396,
    "preview": "#ARCH=i686\n#SYSROOT= ../../build-tools/sysroot\n#CC= $(SYSROOT)/bin/$(ARCH)-aquila-gcc\n#CFLAGS= -I$(SYSROOT)/usr/$(ARCH)-"
  },
  {
    "path": "initrd/init/init.c",
    "chars": 2576,
    "preview": "#include <stdio.h>\n#include <stdlib.h>\n#include <unistd.h>\n#include <fcntl.h>\n#include <string.h>\n#include <sys/wait.h>\n"
  },
  {
    "path": "initrd/usr/share/man/man1/ccom.1",
    "chars": 12915,
    "preview": ".\\\"\t$Id: ccom.1,v 1.33 2018/12/15 09:12:14 plunky Exp $\n.\\\"\n.\\\" Copyright (c) 2007 Jeremy C. Reed <reed@reedmedia.net>\n."
  },
  {
    "path": "initrd/usr/share/man/man1/cpp.1",
    "chars": 6328,
    "preview": ".\\\"\t$Id: cpp.1,v 1.17 2013/02/26 19:27:38 plunky Exp $\n.\\\"\n.\\\" Copyright (c) 2007 Jeremy C. Reed <reed@reedmedia.net>\n.\\"
  },
  {
    "path": "initrd/usr/share/man/man1/p++.1",
    "chars": 9630,
    "preview": ".\\\"\t$Id: cc.1,v 1.45 2016/10/10 11:27:49 ragge Exp $\n.\\\"\n.\\\" Copyright (c) 2007 Jeremy C. Reed <reed@reedmedia.net>\n.\\\"\n"
  },
  {
    "path": "initrd/usr/share/man/man1/pcc.1",
    "chars": 9630,
    "preview": ".\\\"\t$Id: cc.1,v 1.45 2016/10/10 11:27:49 ragge Exp $\n.\\\"\n.\\\" Copyright (c) 2007 Jeremy C. Reed <reed@reedmedia.net>\n.\\\"\n"
  },
  {
    "path": "initrd/usr/share/man/man1/pcpp.1",
    "chars": 9630,
    "preview": ".\\\"\t$Id: cc.1,v 1.45 2016/10/10 11:27:49 ragge Exp $\n.\\\"\n.\\\" Copyright (c) 2007 Jeremy C. Reed <reed@reedmedia.net>\n.\\\"\n"
  },
  {
    "path": "initrd/usr/test.c",
    "chars": 64,
    "preview": "#include <stdio.h>\n\nint main()\n{\n    puts(\"Hello, World!\\n\");\n}\n"
  },
  {
    "path": "iso/boot/grub/grub.cfg",
    "chars": 122,
    "preview": "set timeout=5\nset default=0\n\nmenuentry \"Aquila\" {\n\tmultiboot /kernel.elf.gz earlycon=ttyS0\n\tmodule /initrd.img.gz\n\tboot\n"
  },
  {
    "path": "kernel/Makefile",
    "chars": 943,
    "preview": "export\n\nPDIR := $(SRCDIR)/kernel\n\n#\n# Add include pathes to CFLAGS & ASFLAGS\n#\n\nCFLAGS += \\\n\t-I. \\\n\t-I$(PDIR)/arch/$(ARC"
  },
  {
    "path": "kernel/README.md",
    "chars": 483,
    "preview": "# AquilaOS Kernel\n\n### Source tree structure\n- arch/     - all arch. dependent code\n- configs/  - configurations used du"
  },
  {
    "path": "kernel/arch/Build.mk",
    "chars": 117,
    "preview": "dirs-$(ARCH_NONE)   += none/\ndirs-$(ARCH_I386)   += i386/\ndirs-$(ARCH_X86_64) += x86_64/\ndirs-$(ARCH_ARM)    += arm/\n"
  },
  {
    "path": "kernel/arch/Makefile",
    "chars": 661,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/arch/arm/Build.mk",
    "chars": 169,
    "preview": "obj-y  += none.o\nelf    += kernel-$(VERSION).$(ARCH)\n\nkernel-$(VERSION).$(ARCH): builtin.o\n\t@echo -e \"  ELF     \" $@;\n\t@"
  },
  {
    "path": "kernel/arch/arm/include/core/types.h",
    "chars": 172,
    "preview": "#ifndef _NONE_CORE_TYPES_H\n#define _NONE_CORE_TYPES_H\n\ntypedef uintptr_t paddr_t;\ntypedef uintptr_t vaddr_t;\n\n#include_n"
  },
  {
    "path": "kernel/arch/arm/include/cpu/io.h",
    "chars": 594,
    "preview": "#ifndef _NONE_CPU_IO_H\n#define _NONE_CPU_IO_H\n\n#include_next <cpu/io.h>\n\nstatic inline uint8_t io_in8(struct ioaddr *io,"
  },
  {
    "path": "kernel/arch/arm/include/mm/mm.h",
    "chars": 294,
    "preview": "#ifndef _NONE_MM_MM_H\n#define _NONE_MM_MM_H\n\n#define USER_STACK_BASE 0\n#define PAGE_SIZE   (0x1000)\n#define PAGE_MASK   "
  },
  {
    "path": "kernel/arch/arm/kernel.arm.ld",
    "chars": 934,
    "preview": "ENTRY(_start)\nINPUT(builtin.o ../../core/builtin.o ../../fs/builtin.o ../../dev/builtin.o ../../sys/builtin.o ../../mm/b"
  },
  {
    "path": "kernel/arch/arm/none.c",
    "chars": 0,
    "preview": ""
  },
  {
    "path": "kernel/arch/i386/Build.mk",
    "chars": 252,
    "preview": "dirs-y += boot/\ndirs-y += cpu/\ndirs-y += earlycon/\ndirs-y += mm/\ndirs-y += sys/\ndirs-y += platform/\n\nelf    += kernel-$("
  },
  {
    "path": "kernel/arch/i386/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/arch/i386/boot/Build.mk",
    "chars": 110,
    "preview": "obj-$(X86_MULTIBOOT) += multiboot.o\nobj-$(ARCH_X86_64)   += x86_64_bootstrap.o\nobj-y += init.o\nobj-y += sys.o\n"
  },
  {
    "path": "kernel/arch/i386/boot/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/arch/i386/boot/init.c",
    "chars": 3400,
    "preview": "/**********************************************************************\n *                  Early initalization of the k"
  },
  {
    "path": "kernel/arch/i386/boot/multiboot.S",
    "chars": 1780,
    "preview": "/**********************************************************************\n *                      Multiboot support\n *\n *\n"
  },
  {
    "path": "kernel/arch/i386/boot/sys.S",
    "chars": 117,
    "preview": ".global early_init_fix_stack\nearly_init_fix_stack:\n    mov 4(%esp), %eax\n    add %eax, %esp\n    mov $0, %ebp\n    ret\n"
  },
  {
    "path": "kernel/arch/i386/boot/x86_64_bootstrap.S",
    "chars": 1679,
    "preview": ".code32\n.global x86_64_bootstrap\nx86_64_bootstrap:\n\n    /* Set up basic identity paging\n     * PML4 -> 0x0FF000\n     * P"
  },
  {
    "path": "kernel/arch/i386/cpu/Build.mk",
    "chars": 141,
    "preview": "obj-y += init.o\nobj-y += gdt.o\nobj-y += idt.o\nobj-y += isr.o\n#obj-y += smp.o\nobj-y += fpu.o\nobj-y += cpu.o\nobj-y += arit"
  },
  {
    "path": "kernel/arch/i386/cpu/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/arch/i386/cpu/arith.c",
    "chars": 4312,
    "preview": "/*\n * https://www.ida.liu.se/~TDIU25/pintos/src/lib/arithmetic.c\n */\n\n#include <stdint.h>\n\n/* Uses x86 DIVL instruction "
  },
  {
    "path": "kernel/arch/i386/cpu/cpu.S",
    "chars": 5629,
    "preview": "#include <config.h>\n\n.global x86_cpuid_check\nx86_cpuid_check:\n#if ARCH_BITS==32\n    pushf\n    pushf\n    xorl $1 << 21, ("
  },
  {
    "path": "kernel/arch/i386/cpu/cpu.h",
    "chars": 179,
    "preview": "#ifndef _CPU_SYS_H\n#define _CPU_SYS_H\n\n#include <core/system.h>\n\nvoid x86_lgdt(uint16_t, uintptr_t);\nvoid x86_lidt(uintp"
  },
  {
    "path": "kernel/arch/i386/cpu/fpu.c",
    "chars": 1638,
    "preview": "#include <core/system.h>\n#include <core/panic.h>\n#include <core/assert.h>\n#include <core/arch.h>\n#include <cpu/cpu.h>\n#i"
  },
  {
    "path": "kernel/arch/i386/cpu/gdt.c",
    "chars": 3498,
    "preview": "/**********************************************************************\n *              Global Descriptor Table (GDT)\n *"
  },
  {
    "path": "kernel/arch/i386/cpu/idt.c",
    "chars": 2050,
    "preview": "/**********************************************************************\n *              Interrupt Descriptor Table (IDT)"
  },
  {
    "path": "kernel/arch/i386/cpu/init.c",
    "chars": 1420,
    "preview": "/**********************************************************************\n *                  Initalization of the kernel\n"
  },
  {
    "path": "kernel/arch/i386/cpu/isr.c",
    "chars": 6603,
    "preview": "/**********************************************************************\n *              Interrupt Service Routines (ISRs"
  },
  {
    "path": "kernel/arch/i386/cpu/smp.S",
    "chars": 539,
    "preview": ".code16\n\n.global trampoline\ntrampoline:\n    movw $0x1400, %ax\n    movw %ax, %ds\n    lgdt %ds:(0x00)\n    movl %cr0, %eax\n"
  },
  {
    "path": "kernel/arch/i386/cpu/trace.c",
    "chars": 1202,
    "preview": "#include <core/system.h>\n#include <core/printk.h>\n#include <boot/boot.h>\n\nstruct stack_frame {\n    struct stack_frame *b"
  },
  {
    "path": "kernel/arch/i386/earlycon/Build.mk",
    "chars": 65,
    "preview": "obj-y += uart.o\nobj-y += vga.o\nobj-y += earlycon.o\nobj-y += fb.o\n"
  },
  {
    "path": "kernel/arch/i386/earlycon/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/arch/i386/earlycon/earlycon.c",
    "chars": 859,
    "preview": "#include <core/kargs.h>\n#include <core/string.h>\n#include <console/earlycon.h>\n\nstatic struct earlycon *earlycon;\n\nexter"
  },
  {
    "path": "kernel/arch/i386/earlycon/fb.c",
    "chars": 2732,
    "preview": "#include <core/system.h>\n#include <core/string.h>\n#include <console/earlycon.h>\n#include <cpu/io.h>\n#include <mm/vm.h>\n\n"
  },
  {
    "path": "kernel/arch/i386/earlycon/font.h",
    "chars": 95730,
    "preview": "/* from linux/drivers/video/font-8x16.c */\n\n/**********************************************/\n/*                         "
  },
  {
    "path": "kernel/arch/i386/earlycon/uart.c",
    "chars": 2224,
    "preview": "#include <core/system.h>\n#include <core/string.h>\n#include <console/earlycon.h>\n#include <cpu/io.h>\n#include <mm/mm.h>\n\n"
  },
  {
    "path": "kernel/arch/i386/earlycon/vga.c",
    "chars": 1405,
    "preview": "#include <core/system.h>\n#include <core/string.h>\n#include <console/earlycon.h>\n#include <cpu/io.h>\n\nstatic char *vga_st"
  },
  {
    "path": "kernel/arch/i386/include/boot/boot.h",
    "chars": 4308,
    "preview": "#ifndef _X86_BOOT_H\n#define _X86_BOOT_H\n\n#include_next <boot/boot.h>\n#include <boot/multiboot.h>\n\n#ifdef MULTIBOOT_GFX\n#"
  },
  {
    "path": "kernel/arch/i386/include/boot/multiboot.h",
    "chars": 6478,
    "preview": "/* multiboot.h - Multiboot header file. */\n/* Copyright (C) 1999,2003,2007,2008,2009  Free Software Foundation, Inc.\n *\n"
  },
  {
    "path": "kernel/arch/i386/include/config.h",
    "chars": 356,
    "preview": "#ifndef _X86_CONFIG_H\n#define _X86_CONFIG_H\n\n#if 1\n#define ARCH X86\n#define ARCH_X86\n#define ARCH_BITS 32\n#define MULTIB"
  },
  {
    "path": "kernel/arch/i386/include/core/_string.h",
    "chars": 3321,
    "preview": "#ifndef _X86_STRING_H\n#define _X86_STRING_H\n\n#include <core/system.h>\n#include <mm/mm.h>\n\nstatic inline void *memcpy(voi"
  },
  {
    "path": "kernel/arch/i386/include/core/arch.h",
    "chars": 1401,
    "preview": "#ifndef _X86_ARCH_H\n#define _X86_ARCH_H\n\n#include <cpu/cpu.h>\n\n#define X86_SS      (0x20 | 3)\n#define X86_EFLAGS  (0x200"
  },
  {
    "path": "kernel/arch/i386/include/core/panic.h",
    "chars": 551,
    "preview": "#ifndef _PANIC_H\n#define _PANIC_H\n\n#include <core/system.h>\n#include <core/arch.h>\n#include <core/printk.h>\n\n#define __P"
  },
  {
    "path": "kernel/arch/i386/include/core/platform.h",
    "chars": 189,
    "preview": "#ifndef _X86_CORE_PLATFORM_H\n#define _X86_CORE_PLATFORM_H\n\nint platform_init(void);\nuint32_t platform_timer_setup(size_t"
  },
  {
    "path": "kernel/arch/i386/include/core/system.h",
    "chars": 436,
    "preview": "#ifndef _X86_SYSTEM_H\n#define _X86_SYSTEM_H\n\n#include <config.h>\n\n#define PAGE_SIZE   (0x1000)\n#define PAGE_MASK   (PAGE"
  },
  {
    "path": "kernel/arch/i386/include/cpu/cpu.h",
    "chars": 4700,
    "preview": "#ifndef _X86_CPU_H\n#define _X86_CPU_H\n\n#include <core/system.h>\n#include <cpu/cpuid.h>\n\nstruct x86_regs {\n#if ARCH_BITS="
  },
  {
    "path": "kernel/arch/i386/include/cpu/cpuid.h",
    "chars": 2616,
    "preview": "#ifndef _X86_CPUID_H\n#define _X86_CPUID_H\n\n#include <core/system.h>\n\nunion x86_cpuid_vendor {\n    char string[13];\n    u"
  },
  {
    "path": "kernel/arch/i386/include/cpu/io.h",
    "chars": 4580,
    "preview": "#ifndef _X86_IO_H\n#define _X86_IO_H\n\n#include <stdint.h>\n\n#define __inb(port) \\\n({ \\\n    uint8_t ret; \\\n    asm volatile"
  },
  {
    "path": "kernel/arch/i386/include/cpu/msr.h",
    "chars": 472,
    "preview": "#ifndef _X86_MSR_H\n#define _X86_MSR_H\n\n#include <core/system.h>\n\nstatic inline uint64_t msr_read(uint32_t msr)\n{\n    uin"
  },
  {
    "path": "kernel/arch/i386/include/cpu/pit.h",
    "chars": 123,
    "preview": "#ifndef _X86_PIT_H\n#define _X86_PIT_H\n\n#include <core/system.h>\n\nvoid pit_setup(uint32_t freq);\n\n#endif /* ! _X86_PIT_H "
  },
  {
    "path": "kernel/arch/i386/include/cpu/sdt.h",
    "chars": 1526,
    "preview": "#ifndef _X86_SDT_H\n#define _X86_SDT_H\n\n#include <core/system.h>\n\nstruct acpi_rsdp {\n    char     signature[8];\n    uint8"
  },
  {
    "path": "kernel/arch/i386/include/mm/mm.h",
    "chars": 947,
    "preview": "#ifndef _I386_MM_H\n#define _I386_MM_H\n\n#include <core/system.h>\n#include <cpu/cpu.h>\n\n#define NR_PAGE_SIZE           2\n#"
  },
  {
    "path": "kernel/arch/i386/include/mm/pmap.h",
    "chars": 159,
    "preview": "#ifndef _I386_MM_PMAP_H\n#define _I386_MM_PMAP_H\n\nstruct pmap {\n    paddr_t map;\n    size_t  ref;\n};\n\n#include_next <mm/p"
  },
  {
    "path": "kernel/arch/i386/include/platform/misc.h",
    "chars": 658,
    "preview": "#ifndef _PLATFORM_MISC_H\n#define _PLATFORM_MISC_H\n\n#include <cpu/cpu.h>\n#include <cpu/io.h>\n\ntypedef void (*x86_irq_hand"
  },
  {
    "path": "kernel/arch/i386/kernel.i386.ld",
    "chars": 1340,
    "preview": "OUTPUT_FORMAT(elf32-i386)\nENTRY(_start)\nINPUT(boot/builtin.o cpu/builtin.o earlycon/builtin.o mm/builtin.o sys/builtin.o"
  },
  {
    "path": "kernel/arch/i386/kernel.x86_64.ld",
    "chars": 1076,
    "preview": "OUTPUT_FORMAT(elf64-x86-64)\nENTRY(_start)\nINPUT(boot/builtin.o cpu/builtin.o earlycon/builtin.o mm/builtin.o sys/builtin"
  },
  {
    "path": "kernel/arch/i386/mm/Build.mk",
    "chars": 81,
    "preview": "obj-y  \t\t\t   += mm.o\nobj-$(ARCH_I386)   += i386.o\nobj-$(ARCH_X86_64) += x86_64.o\n"
  },
  {
    "path": "kernel/arch/i386/mm/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/arch/i386/mm/frame_utils.h",
    "chars": 676,
    "preview": "#ifndef _FRAME_UTILS_H\n#define _FRAME_UTILS_H\n\nstatic inline uintptr_t frame_get()\n{\n    uintptr_t frame = buddy_alloc(B"
  },
  {
    "path": "kernel/arch/i386/mm/i386.c",
    "chars": 12243,
    "preview": "/*\n *                 Intel 32-Bit Paging Mode Handler\n *\n *  References:\n *      [1] - Intel(R) 64 and IA-32 Architectu"
  },
  {
    "path": "kernel/arch/i386/mm/i386.h",
    "chars": 283,
    "preview": "#ifndef _PAGING_I386_H\n#define _PAGING_I386_H\n\n#include <core/system.h>\n\n#define PG_PRESENT  1\n#define PG_WRITE    2\n#de"
  },
  {
    "path": "kernel/arch/i386/mm/mm.c",
    "chars": 519,
    "preview": "/**********************************************************************\n *                  Physical Memory Manager\n *\n "
  },
  {
    "path": "kernel/arch/i386/mm/page_utils.h",
    "chars": 1953,
    "preview": "#ifndef _PAGE_UTILS_H\n#define _PAGE_UTILS_H\n\nstatic void *copy_physical_to_virtual(void *_virt_dest, void *_phys_src, si"
  },
  {
    "path": "kernel/arch/i386/mm/x86_64.c",
    "chars": 13508,
    "preview": "#include <core/arch.h>\n#include <core/panic.h>\n#include <core/printk.h>\n#include <core/system.h>\n#include <cpu/cpu.h>\n#i"
  },
  {
    "path": "kernel/arch/i386/mm/x86_64.h",
    "chars": 3046,
    "preview": "#ifndef _PAGING_X86_64_H\n#define _PAGING_X86_64_H\n\n#include <core/system.h>\n\n/* \n * Page Management Level 4 (PML4)\n * Ta"
  },
  {
    "path": "kernel/arch/i386/platform/Build.mk",
    "chars": 87,
    "preview": "dirs-y += misc/\ndirs-$(PLATFORM_X86_PC)    += pc/\ndirs-$(PLATFORM_X86_QUARK) += quark/\n"
  },
  {
    "path": "kernel/arch/i386/platform/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/arch/i386/platform/misc/Build.mk",
    "chars": 247,
    "preview": "obj-$(PLATFORM_X86_MISC_PIC)   += pic.o\nobj-$(PLATFORM_X86_MISC_I8042) += i8042.o\nobj-$(PLATFORM_X86_MISC_PIT)   += pit."
  },
  {
    "path": "kernel/arch/i386/platform/misc/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/arch/i386/platform/misc/acpi.c",
    "chars": 2364,
    "preview": "#include <core/system.h>\n#include <core/string.h>\n\n#include <cpu/cpu.h>\n\n#include <mm/vm.h>\n\nstatic inline int byte_chec"
  },
  {
    "path": "kernel/arch/i386/platform/misc/cmos.c",
    "chars": 2479,
    "preview": "#include <core/system.h>\n#include <core/types.h>\n#include <cpu/io.h>\n\n#define RTC_SEC    0x00      /* Seconds */\n#define"
  },
  {
    "path": "kernel/arch/i386/platform/misc/hpet.c",
    "chars": 4623,
    "preview": "#include <core/system.h>\n#include <mm/mm.h>\n#include <cpu/cpu.h>\n#include <cpu/io.h>\n\n#define HPET_MEM_IO     0\n#define "
  },
  {
    "path": "kernel/arch/i386/platform/misc/i8042.c",
    "chars": 2627,
    "preview": "#include <core/system.h>\n#include <core/string.h>\n#include <core/kargs.h>\n#include <cpu/cpu.h>\n#include <cpu/io.h>\n#incl"
  },
  {
    "path": "kernel/arch/i386/platform/misc/pic.c",
    "chars": 7448,
    "preview": "/**********************************************************************\n *              Programmable Interrupt Controlle"
  },
  {
    "path": "kernel/arch/i386/platform/misc/pit.c",
    "chars": 1750,
    "preview": "#include <core/system.h>\n#include <core/string.h>\n#include <core/kargs.h>\n#include <cpu/io.h>\n#include <platform/misc.h>"
  },
  {
    "path": "kernel/arch/i386/platform/pc/Build.mk",
    "chars": 34,
    "preview": "obj-y += init.o\nobj-y += reboot.o\n"
  },
  {
    "path": "kernel/arch/i386/platform/pc/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/arch/i386/platform/pc/init.c",
    "chars": 1714,
    "preview": "#include <core/kargs.h>\n#include <core/system.h>\n#include <cpu/io.h>\n#include <dev/pci.h>\n#include <platform/misc.h>\n\n\n/"
  },
  {
    "path": "kernel/arch/i386/platform/pc/reboot.c",
    "chars": 183,
    "preview": "#include <core/system.h>\n#include <core/arch.h>\n#include <platform/misc.h>\n\nvoid platform_reboot(void)\n{\n    x86_i8042_r"
  },
  {
    "path": "kernel/arch/i386/platform/quark/Build.mk",
    "chars": 34,
    "preview": "dirs-y += legacy/\nobj-y += init.o\n"
  },
  {
    "path": "kernel/arch/i386/platform/quark/include/chipset/legacy_bridge.h",
    "chars": 194,
    "preview": "#ifndef _QUARK_LEGACY_BRIDGE_H\n#define _QUARK_LEGACY_BRIDGE_H\n\n#include <dev/pci.h>\n\nextern struct pci_dev qrk_leg_brdg;"
  },
  {
    "path": "kernel/arch/i386/platform/quark/include/chipset/root_complex.h",
    "chars": 195,
    "preview": "#ifndef _QUARK_ROOT_COMPLEX_H\n#define _QUARK_ROOT_COMPLEX_H\n\nvoid quark_root_complex_io_fabric_route(int intr_pin, int i"
  },
  {
    "path": "kernel/arch/i386/platform/quark/include/chipset/system.h",
    "chars": 112,
    "preview": "#ifndef _QUARK_CHIPSET\n#define _QUARK_CHIPSET\n\nvoid quark_legacy_bridge_setup();\n\n#endif /* ! _QUARK_CHIPSET */\n"
  },
  {
    "path": "kernel/arch/i386/platform/quark/init.c",
    "chars": 2747,
    "preview": "#include <core/system.h>\n#include <chipset/system.h>\n#include <chipset/misc.h>\n#include <cpu/io.h>\n#include <console/ear"
  },
  {
    "path": "kernel/arch/i386/platform/quark/legacy/Build.mk",
    "chars": 42,
    "preview": "obj-y += bridge.o\nobj-y += root_complex.o\n"
  },
  {
    "path": "kernel/arch/i386/platform/quark/legacy/bridge.c",
    "chars": 604,
    "preview": "#include <core/system.h>\n#include <dev/pci.h>\n\n#include <chipset/root_complex.h>\n\n#define QRK_LEG_BRDG_VENDOR_ID  0x8086"
  },
  {
    "path": "kernel/arch/i386/platform/quark/legacy/interrupt.c",
    "chars": 68,
    "preview": "#include <core/system.h>\n\nvoid quark_interrupt_decoder_setup()\n{\n\n}\n"
  },
  {
    "path": "kernel/arch/i386/platform/quark/legacy/root_complex.c",
    "chars": 2303,
    "preview": "#include <core/system.h>\n#include <chipset/legacy_bridge.h>\n#include <chipset/root_complex.h>\n\n#define QRK_LEG_BRDG_REG_"
  },
  {
    "path": "kernel/arch/i386/sys/Build.mk",
    "chars": 122,
    "preview": "obj-y += fork.o\nobj-y += proc.o\nobj-y += thread.o\nobj-y += syscall.o\nobj-y += sched.o\nobj-y += execve.o\nobj-y += signal."
  },
  {
    "path": "kernel/arch/i386/sys/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/arch/i386/sys/execve.c",
    "chars": 2117,
    "preview": "#include <core/system.h>\n#include <core/string.h>\n#include <core/arch.h>\n#include <sys/proc.h>\n\nvoid arch_sys_execve(str"
  },
  {
    "path": "kernel/arch/i386/sys/fork.c",
    "chars": 1464,
    "preview": "#include <core/system.h>\n#include <core/string.h>\n#include <core/arch.h>\n\n#include <sys/proc.h>\n#include <sys/sched.h>\n\n"
  },
  {
    "path": "kernel/arch/i386/sys/proc.c",
    "chars": 1399,
    "preview": "#include <core/system.h>\n#include <core/string.h>\n#include <core/arch.h>\n#include <sys/proc.h>\n#include <sys/sched.h>\n#i"
  },
  {
    "path": "kernel/arch/i386/sys/sched.c",
    "chars": 3337,
    "preview": "#include <core/arch.h>\n#include <core/platform.h>\n#include <core/time.h>\n#include <mm/mm.h>\n#include <sys/proc.h>\n#inclu"
  },
  {
    "path": "kernel/arch/i386/sys/signal.c",
    "chars": 1435,
    "preview": "#include <core/system.h>\n#include <core/arch.h>\n#include <sys/signal.h>\n#include <sys/proc.h>\n#include <sys/sched.h>\n#in"
  },
  {
    "path": "kernel/arch/i386/sys/sys.h",
    "chars": 453,
    "preview": "#include <core/system.h>\n#include <cpu/cpu.h>\n#include <mm/mm.h>\n#include <sys/proc.h>\n\nvoid x86_jump_user(uintptr_t eax"
  },
  {
    "path": "kernel/arch/i386/sys/syscall.c",
    "chars": 1091,
    "preview": "#include <core/system.h>\n#include <core/arch.h>\n#include <sys/proc.h>\n#include <sys/sched.h>\n#include <sys/syscall.h>\n#i"
  },
  {
    "path": "kernel/arch/i386/sys/thread.c",
    "chars": 3668,
    "preview": "#include <core/system.h>\n#include <core/string.h>\n#include <core/arch.h>\n#include <sys/proc.h>\n#include <sys/sched.h>\n#i"
  },
  {
    "path": "kernel/arch/none/Build.mk",
    "chars": 169,
    "preview": "obj-y  += none.o\nelf    += kernel-$(VERSION).$(ARCH)\n\nkernel-$(VERSION).$(ARCH): builtin.o\n\t@echo -e \"  ELF     \" $@;\n\t@"
  },
  {
    "path": "kernel/arch/none/include/core/types.h",
    "chars": 172,
    "preview": "#ifndef _NONE_CORE_TYPES_H\n#define _NONE_CORE_TYPES_H\n\ntypedef uintptr_t paddr_t;\ntypedef uintptr_t vaddr_t;\n\n#include_n"
  },
  {
    "path": "kernel/arch/none/include/cpu/io.h",
    "chars": 594,
    "preview": "#ifndef _NONE_CPU_IO_H\n#define _NONE_CPU_IO_H\n\n#include_next <cpu/io.h>\n\nstatic inline uint8_t io_in8(struct ioaddr *io,"
  },
  {
    "path": "kernel/arch/none/include/mm/mm.h",
    "chars": 294,
    "preview": "#ifndef _NONE_MM_MM_H\n#define _NONE_MM_MM_H\n\n#define USER_STACK_BASE 0\n#define PAGE_SIZE   (0x1000)\n#define PAGE_MASK   "
  },
  {
    "path": "kernel/arch/none/kernel.none.ld",
    "chars": 982,
    "preview": "OUTPUT_FORMAT(elf32-i386)\nENTRY(_start)\nINPUT(builtin.o ../../core/builtin.o ../../fs/builtin.o ../../dev/builtin.o ../."
  },
  {
    "path": "kernel/arch/none/none.c",
    "chars": 0,
    "preview": ""
  },
  {
    "path": "kernel/core/Build.mk",
    "chars": 105,
    "preview": "obj-y += printk.o\nobj-y += main.o\nobj-y += module.o\nobj-y += snprintf.o\nobj-y += kargs.o\nobj-y += time.o\n"
  },
  {
    "path": "kernel/core/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/core/kargs.c",
    "chars": 1091,
    "preview": "#include <core/system.h>\n#include <core/string.h>\n\n#define MAX_ARGS 128\n\nstatic struct {\n    const char *key;\n    const "
  },
  {
    "path": "kernel/core/main.c",
    "chars": 1788,
    "preview": "/**\n * \\defgroup core kernel/core\n * \\brief core system components\n */\n\n#include <core/printk.h>\n#include <core/panic.h>"
  },
  {
    "path": "kernel/core/module.c",
    "chars": 476,
    "preview": "#include <core/system.h>\n#include <core/module.h>\n\nextern char __minit, __minit_end;\n\ntypedef void (*__ctor)(void);\n\nint"
  },
  {
    "path": "kernel/core/printk.c",
    "chars": 3861,
    "preview": "#include <core/system.h>\n\n#include <core/string.h>\n#include <console/earlycon.h>\n#include <ds/ringbuf.h>\n\n#define KMSG_S"
  },
  {
    "path": "kernel/core/snprintf.c",
    "chars": 3921,
    "preview": "#include <core/system.h>\n\nstatic int snputc(char *s, size_t n, char c)\n{\n    if (n) {\n        *s = c;\n        return 1;\n"
  },
  {
    "path": "kernel/core/time.c",
    "chars": 514,
    "preview": "#include <core/system.h>\n#include <core/time.h>\n#include <core/arch.h>\n\n/* XXX use a better name */\nint gettime(struct t"
  },
  {
    "path": "kernel/dev/Build.mk",
    "chars": 225,
    "preview": "dirs-y += pci/\ndirs-$(DEV_KEYBOARD) += kbd/\ndirs-$(DEV_FRAMEBUFFER) += fb/\ndirs-y += tty/\ndirs-$(DEV_MOUSE) += mouse/\ndi"
  },
  {
    "path": "kernel/dev/Makefile",
    "chars": 643,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/dev/ata/Build.mk",
    "chars": 30,
    "preview": "obj-y += ata.o\nobj-y += pio.o\n"
  },
  {
    "path": "kernel/dev/ata/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/dev/ata/ata.c",
    "chars": 8906,
    "preview": "/**\n * \\defgroup dev-ata kernel/dev/ata\n * \\brief ata device\n */\n\n#include <core/system.h>\n#include <core/module.h>\n\n#in"
  },
  {
    "path": "kernel/dev/ata/ata.h",
    "chars": 5614,
    "preview": "#ifndef _ATA_H\n#define _ATA_H\n\n/* definitions used in atadev driver */\n#define ATADEV_UNKOWN               0x000\n#define"
  },
  {
    "path": "kernel/dev/ata/pio.c",
    "chars": 4112,
    "preview": "#include <core/system.h>\n#include <core/panic.h>\n#include <cpu/io.h>\n#include <dev/dev.h>\n#include <fs/vfs.h>\n#include <"
  },
  {
    "path": "kernel/dev/fb/Build.mk",
    "chars": 45,
    "preview": "dirs-y += fbdev/\ndirs-$(FBDEV_VESA) += vesa/\n"
  },
  {
    "path": "kernel/dev/fb/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/dev/fb/fbdev/Build.mk",
    "chars": 17,
    "preview": "obj-y += fbdev.o\n"
  },
  {
    "path": "kernel/dev/fb/fbdev/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/dev/fb/fbdev/fbdev.c",
    "chars": 2245,
    "preview": "#include <core/system.h>\n#include <core/module.h>\n\n#include <dev/fbdev.h>\n#include <dev/ramdev.h>\n\n#include <fs/vfs.h>\n#"
  },
  {
    "path": "kernel/dev/fb/vesa/Build.mk",
    "chars": 16,
    "preview": "obj-y += vesa.o\n"
  },
  {
    "path": "kernel/dev/fb/vesa/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/dev/fb/vesa/vesa.c",
    "chars": 3950,
    "preview": "#include <core/system.h>\n#include <dev/fbdev.h>\n#include <fs/devfs.h>\n#include <video/vesa.h>\n#include <mm/vm.h>\n\nstatic"
  },
  {
    "path": "kernel/dev/fdc/Build.mk",
    "chars": 38,
    "preview": "obj-y += fdc.o\nobj-y += fdc_82077AA.o\n"
  },
  {
    "path": "kernel/dev/fdc/fdc.c",
    "chars": 340,
    "preview": "#include <core/system.h>\n#include <core/panic.h>\n#include <core/module.h>\n\n#include <cpu/io.h>\n#include <dev/dev.h>\n#inc"
  },
  {
    "path": "kernel/dev/fdc/fdc_82077AA.c",
    "chars": 5743,
    "preview": "#include <core/system.h>\n#include <core/panic.h>\n#include <core/module.h>\n#include <fs/posix.h>\n\n#include <cpu/io.h>\n#in"
  },
  {
    "path": "kernel/dev/fdc/fdc_82077AA.h",
    "chars": 2001,
    "preview": "#ifndef _FDC_H\n#define _FDC_H\n\n#define FDC_BASE 0x3F0\n\n#define FDC_SRA         0   /* Status Register A */\n#define FDC_S"
  },
  {
    "path": "kernel/dev/kbd/Build.mk",
    "chars": 36,
    "preview": "obj-$(DEV_KEYBOARD_PS2) += ps2kbd.o\n"
  },
  {
    "path": "kernel/dev/kbd/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/dev/kbd/kbd.c",
    "chars": 2099,
    "preview": "#include <core/system.h>\n#include <core/module.h>\n#include <sys/sched.h>\n#include <dev/dev.h>\n#include <ds/ringbuf.h>\n#i"
  },
  {
    "path": "kernel/dev/kbd/ps2kbd.c",
    "chars": 2194,
    "preview": "/*\n *          PS/2 Keyboard driver\n *\n *\n *  This file is part of Aquila OS and is released under\n *  the terms of GNU "
  },
  {
    "path": "kernel/dev/kdev.c",
    "chars": 7845,
    "preview": "/**\n * \\defgroup kdev kernel/kdev\n * \\brief devices management\n */\n\n#include <core/system.h>\n#include <dev/dev.h>\n#inclu"
  },
  {
    "path": "kernel/dev/mem/Build.mk",
    "chars": 66,
    "preview": "obj-y += zero.o\nobj-y += null.o\nobj-y += kmsg.o\nobj-y += memdev.o\n"
  },
  {
    "path": "kernel/dev/mem/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/dev/mem/kmsg.c",
    "chars": 1417,
    "preview": "#include <core/system.h>\n#include <dev/dev.h>\n#include <fs/posix.h>\n#include <ds/ringbuf.h>\n#include <sys/sched.h>\n#incl"
  },
  {
    "path": "kernel/dev/mem/memdev.c",
    "chars": 1020,
    "preview": "#include <core/system.h>\n#include <core/module.h>\n#include <dev/dev.h>\n\n#include <memdev.h>\n\nstruct dev memdev;\n\nstruct "
  },
  {
    "path": "kernel/dev/mem/memdev.h",
    "chars": 195,
    "preview": "#ifndef _MEMDEV_H\n#define _MEMDEV_H\n\n#include <dev/dev.h>\n\nextern struct dev nulldev;\n//extern struct dev portdev;\nexter"
  },
  {
    "path": "kernel/dev/mem/null.c",
    "chars": 768,
    "preview": "#include <core/system.h>\n#include <dev/dev.h>\n#include <fs/posix.h>\n#include <bits/errno.h>\n\n#include <memdev.h>\n\nstruct"
  },
  {
    "path": "kernel/dev/mem/zero.c",
    "chars": 778,
    "preview": "#include <core/system.h>\n#include <dev/dev.h>\n#include <fs/posix.h>\n#include <bits/errno.h>\n\n#include <memdev.h>\n\nstruct"
  },
  {
    "path": "kernel/dev/mouse/Build.mk",
    "chars": 20,
    "preview": "obj-y += ps2mouse.o\n"
  },
  {
    "path": "kernel/dev/mouse/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/dev/mouse/ps2mouse.c",
    "chars": 4132,
    "preview": "/*\n *          PS/2 Mouse driver\n *\n *\n *  This file is part of Aquila OS and is released under\n *  the terms of GNU GPL"
  },
  {
    "path": "kernel/dev/pci/Build.mk",
    "chars": 15,
    "preview": "obj-y += pci.o\n"
  },
  {
    "path": "kernel/dev/pci/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/dev/pci/pci.c",
    "chars": 5918,
    "preview": "#include <core/system.h>\n#include <core/module.h>\n\n#include <dev/pci.h>\n#include <cpu/io.h>\n\nstatic struct ioaddr pci_io"
  },
  {
    "path": "kernel/dev/rd/Build.mk",
    "chars": 19,
    "preview": "obj-y += ramdisk.o\n"
  },
  {
    "path": "kernel/dev/rd/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/dev/rd/ramdisk.c",
    "chars": 1258,
    "preview": "#include <core/system.h>\n#include <core/module.h>\n#include <core/string.h>\n\n#include <boot/boot.h>\n#include <dev/dev.h>\n"
  },
  {
    "path": "kernel/dev/tty/Build.mk",
    "chars": 117,
    "preview": "dirs-$(DEV_CONSOLE) += console/\ndirs-$(DEV_PTY)  += pty/\ndirs-$(DEV_UART) += uart/\nobj-y += tty.o\nobj-y += generic.o\n"
  },
  {
    "path": "kernel/dev/tty/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/dev/tty/console/Build.mk",
    "chars": 19,
    "preview": "obj-y += console.o\n"
  },
  {
    "path": "kernel/dev/tty/console/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/dev/tty/console/console.c",
    "chars": 2313,
    "preview": "/*\n *          IBM VGA Text-Mode Console\n *\n *\n *  This file is part of Aquila OS and is released under\n *  the terms of"
  },
  {
    "path": "kernel/dev/tty/generic.c",
    "chars": 6849,
    "preview": "#include <core/system.h>\n#include <sys/sched.h>\n#include <dev/tty.h>\n\nMALLOC_DEFINE(M_TTY, \"tty\", \"tty structure\");\nMALL"
  },
  {
    "path": "kernel/dev/tty/pty/Build.mk",
    "chars": 15,
    "preview": "obj-y += pty.o\n"
  },
  {
    "path": "kernel/dev/tty/pty/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/dev/tty/pty/pty.c",
    "chars": 6685,
    "preview": "#include <core/system.h>\n#include <core/module.h>\n#include <fs/vfs.h>\n#include <fs/devpts.h>\n#include <fs/posix.h>\n#incl"
  },
  {
    "path": "kernel/dev/tty/tty.c",
    "chars": 946,
    "preview": "/**\n * \\defgroup dev-tty kernel/dev/tty\n * \\brief tty device\n */\n\n#include <core/system.h>\n#include <core/module.h>\n#inc"
  },
  {
    "path": "kernel/dev/tty/uart/8250/8250.c",
    "chars": 3499,
    "preview": "#include <core/system.h>\n#include <core/module.h>\n\n#include <dev/tty.h>\n#include <dev/uart.h>\n#include <dev/pci.h>\n#incl"
  },
  {
    "path": "kernel/dev/tty/uart/8250/Build.mk",
    "chars": 16,
    "preview": "obj-y += 8250.o\n"
  },
  {
    "path": "kernel/dev/tty/uart/8250/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/dev/tty/uart/Build.mk",
    "chars": 32,
    "preview": "dirs-y += 8250/\nobj-y += uart.o\n"
  },
  {
    "path": "kernel/dev/tty/uart/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/dev/tty/uart/uart.c",
    "chars": 3299,
    "preview": "#include <core/system.h>\n#include <dev/dev.h>\n#include <dev/tty.h>\n#include <dev/uart.h>\n#include <fs/posix.h>\n#include "
  },
  {
    "path": "kernel/fs/Build.mk",
    "chars": 630,
    "preview": "obj-y  += close.o\nobj-y  += fops.o\nobj-y  += ioctl.o\nobj-y  += lookup.o\nobj-y  += mknod.o\nobj-y  += mount.o\nobj-y  += re"
  },
  {
    "path": "kernel/fs/Makefile",
    "chars": 648,
    "preview": "include Build.mk\n\nCWD != realpath --relative-to=$(SRCDIR) .\n\nall: builtin.o $(elf)\n\nbuiltin.o: $(obj-y) $(dirs-y)\n\t@$(EC"
  },
  {
    "path": "kernel/fs/bcache.c",
    "chars": 2208,
    "preview": "#include <core/system.h>\n#include <fs/bcache.h>\n\nMALLOC_DEFINE(M_BCACHE, \"bcache\", \"block cache structure\");\nMALLOC_DEFI"
  },
  {
    "path": "kernel/fs/close.c",
    "chars": 616,
    "preview": "#include <core/system.h>\n#include <core/panic.h>\n#include <fs/vfs.h>\n\n/** close a vnode\n * \\ingroup vfs\n * \\brief closes"
  },
  {
    "path": "kernel/fs/devfs/Build.mk",
    "chars": 80,
    "preview": "ifneq ($(FS_TMPFS),y)\n$(error \"devfs depends on tmpfs\")\nendif\n\nobj-y += devfs.o\n"
  }
]

// ... and 253 more files (download for full content)

About this extraction

This page contains the full source code of the thethumbler/Aquila GitHub repository, extracted and formatted as plain text for AI agents and large language models (LLMs). The extraction includes 453 files (1.3 MB), approximately 431.1k tokens, and a symbol index with 2223 extracted functions, classes, methods, constants, and types. Use this with OpenClaw, Claude, ChatGPT, Cursor, Windsurf, or any other AI tool that accepts text input. You can copy the full output to your clipboard or download it as a .txt file.

Extracted by GitExtract — free GitHub repo to text converter for AI. Built by Nikandr Surkov.

Copied to clipboard!