Skip to content

Headers

Aditya Vaidyam edited this page Jul 28, 2016 · 1 revision

From this page you can find concise documentation about each file and function in Xinu. Development of this page is ongoing at the moment. If you are part of the Xinu development team, feel free to add to this page whenever you are able.

The documentation regarding the files is intentionally brief; since the Xinu code base is very well-commented, most necessary information can be found within the files themselves.

Please note that this page only contains documentation about files and functions that are present within the master branch of the Xinu codebase. For documentation about project-specific code(for example, ssh.h or pthread_wrapper.h), visit the projects page of the Xinu wiki.

Files

arp.h

Defines constants and structures related to the Address Resolution Protocol(ARP).

bufpool.h

Defines constants and structures needed for buffer pool management, which provides synchronous access to partitioned memory. From Vol. 1 of Operating System Design - The Xinu Approach:

The mechanism we have chosen to handle partitioned memory is known as a buffer pool manager. Memory is divided into a set of buffer pools. Each buffer pool contains a fixed number of memory blocks, and all blocks in a given pool are the same size.

clock.h

Contains constants needed to interface with the Intel 8254 Programmable Interval Timer. The datasheet for this chip can be downloaded here.

ctype.h

date.h

Defines constants and functions used to store and convert dates. Xinu follows the UNIX convention of storing the time as the number of seconds since the Epoch(January 1, 1970 GMT).

debug.h

delay.h

Defines two delay functions, DELAY and MDELAY, which force Xinu to delay for a given number of microseconds or milliseconds respectively.

device.h

dhcp.h

Defines constants and functions used for the Dynamic Host Configuration Protocol(DHCP).

dns.h

Defines constants and structures used for the Domain Name Service(DNS).

ether.h

Defines constants, structures and functions related to the Ethernet packet format. For more information about Ethernet packets, see the Ethernet Frame RFC.

ethloop.h

file.h

Defines constants needed for file permissions and control functions on local and remote file systems.

flash.h

icmp.h

Defines constants and structures needed for the Internet Control Message Protocol(ICMP).

icu.h and icu.s

Code related to the interrupt controller. The icu.h file defines constants for C functions, and the icu.s file defines constants for assembly language.

interrupt.h

ip.h

Defines constants and structures related to version 4 of the Internet Protocol, commonly known as IPv4.

kernel.h

Defines types, constants and system calls used throughout the Xinu kernel. Curious Xinu developers may want to start reading the Xinu code here, since the declarations within this file are used throughout the rest of the Xinu codebase. A reference sheet for these declarations can be found here.

lfilesys.h

limits.h

mark.h

memory.h

multiboot.h

name.h

net.h

pci.h

ports.h

process.h

prototypes.h

pxe.h

quark_eth.h

quark_irq.h

quark_pdat.h

queue.h

ramdisk.h

rdisksys.h

resched.h

rfilesys.h

sdmc.h

semaphore.h

shell.h

shprototypes.h

stdarg.h

stddef.h

stdio.h

stdlib.h

string.h

testsuite.h

tftp.h

tty.h

uart.h

udp.h

xinu.h

Functions

recvclr

Clears the incoming message and returns the message if there is a message waiting. The recvclr function is a non-blocking version of the receive function.