summaryrefslogtreecommitdiff
path: root/share
diff options
context:
space:
mode:
authorIan Moffett <ian@osmora.org>2024-06-24 22:55:29 -0400
committerIan Moffett <ian@osmora.org>2024-06-24 22:55:29 -0400
commit236963e7563be3e3f8220dac7bb4af446928e194 (patch)
treee521ea226db0345bbb3679fffe09d96254b7dc73 /share
parent214eadc62b5578f76c98a38a28f8b3d80ac4d6ad (diff)
Clean out for expt
Signed-off-by: Ian Moffett <ian@osmora.org>
Diffstat (limited to 'share')
-rw-r--r--share/man/man1/kconf.169
-rw-r--r--share/man/man1/meta-rip.161
-rw-r--r--share/man/man9/arch.9133
-rw-r--r--share/man/man9/device.964
-rw-r--r--share/man/man9/dynalloc.957
-rw-r--r--share/man/man9/mmio.963
-rw-r--r--share/man/man9/pmap.975
-rw-r--r--share/man/man9/syslog.961
-rw-r--r--share/man/man9/timer.956
-rw-r--r--share/man/man9/vm.967
-rw-r--r--share/misc/contrib134
-rw-r--r--share/misc/vimrc7
12 files changed, 0 insertions, 847 deletions
diff --git a/share/man/man1/kconf.1 b/share/man/man1/kconf.1
deleted file mode 100644
index 2f58bcb..0000000
--- a/share/man/man1/kconf.1
+++ /dev/null
@@ -1,69 +0,0 @@
-.\" Copyright (c) 2023-2024 Ian Marco Moffett and the Osmora Team.
-.\" All rights reserved.
-.\"
-.\" Redistribution and use in source and binary forms, with or without
-.\" modification, are permitted provided that the following conditions are met:
-.\"
-.\" 1. Redistributions of source code must retain the above copyright notice,
-.\" this list of conditions and the following disclaimer.
-.\" 2. Redistributions in binary form must reproduce the above copyright
-.\" notice, this list of conditions and the following disclaimer in the
-.\" documentation and/or other materials provided with the distribution.
-.\" 3. Neither the name of Hyra nor the names of its
-.\" contributors may be used to endorse or promote products derived from
-.\" this software without specific prior written permission.
-.\"
-.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-.\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-.\" ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
-.\" LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
-.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
-.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
-.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
-.\" POSSIBILITY OF SUCH DAMAGE.
-.Dd May 17 2024
-.Dt KCONF 1
-.Os Hyra
-.Sh NAME
-.Nm kconf - kernel configuration
-
-.Sh SYNOPSIS
-.Ft cat CONFIG_FILE | kconf
-
-.Sh DESCRIPTION
-During the kernel build process, kconf parses a config file and
-generates define flags that can be passed to the compiler.
-
-Example config file:
-
---
-.Bd -literal
-// Example of options that can be enabled
-// and disabled.
-option FOO yes
-option BLAH no
-
-// Example of constants that can be set
-// within the kernel.
-setval SOME_INT 32
-setval SOME_STR "foo"
-.Ed
---
-
-The above example will output the following:
-
--D__FOO=1 -D__BLAH=0 -D__SOME_INT=32 -D__SOME_STR="foo"
-
-The
-.Ft option
-keyword allows options to be toggled on or off (yes, no).
-
-The
-.Ft setval
-keyword sets a global constant within the kernel.
-
-.Sh AUTHORS
-.An Ian Moffett Aq Mt ian@osmora.org
diff --git a/share/man/man1/meta-rip.1 b/share/man/man1/meta-rip.1
deleted file mode 100644
index f945238..0000000
--- a/share/man/man1/meta-rip.1
+++ /dev/null
@@ -1,61 +0,0 @@
-.\" Copyright (c) 2023-2024 Ian Marco Moffett and the Osmora Team.
-.\" All rights reserved.
-.\"
-.\" Redistribution and use in source and binary forms, with or without
-.\" modification, are permitted provided that the following conditions are met:
-.\"
-.\" 1. Redistributions of source code must retain the above copyright notice,
-.\" this list of conditions and the following disclaimer.
-.\" 2. Redistributions in binary form must reproduce the above copyright
-.\" notice, this list of conditions and the following disclaimer in the
-.\" documentation and/or other materials provided with the distribution.
-.\" 3. Neither the name of Hyra nor the names of its
-.\" contributors may be used to endorse or promote products derived from
-.\" this software without specific prior written permission.
-.\"
-.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-.\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-.\" ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
-.\" LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
-.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
-.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
-.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
-.\" POSSIBILITY OF SUCH DAMAGE.
-.Dd Jan 12 2024
-.Dt META-RIP 1
-.Os Hyra
-.Sh NAME
-.Nm meta-rip - rip metadata from object file
-.Sh SYNOPSIS
-
-.Bd -literal
-meta-rip [FILE]
-.Ed
-
-.Sh DESCRIPTION
-This utility rips metadata from the .meta.note section of
-an object file that contains the following format:
-
-.Bd -literal
-$Hyra$: Filename, Author Of Module, Description Of Module
- \\
- Cookie (always first)
-.Ed
-
-Example assembly C code that uses inline assembly to embed
-a meta string:
-
-.Bd -literal
-#define __KERNEL_META(meta_str) \\
- __asm__ __volatile__(".section .meta.note\\n" \\
- ".align 4\\n" \\
- ".string \\"" meta_str "\\"\\n" \\
- ".previous" \\
- )
-.Ed
-
-.Sh AUTHORS
-.An Ian Moffett Aq Mt ian@osmora.org
diff --git a/share/man/man9/arch.9 b/share/man/man9/arch.9
deleted file mode 100644
index 5bcac2d..0000000
--- a/share/man/man9/arch.9
+++ /dev/null
@@ -1,133 +0,0 @@
-.\" Copyright (c) 2023-2024 Ian Marco Moffett and the Osmora Team.
-.\" All rights reserved.
-.\"
-.\" Redistribution and use in source and binary forms, with or without
-.\" modification, are permitted provided that the following conditions are met:
-.\"
-.\" 1. Redistributions of source code must retain the above copyright notice,
-.\" this list of conditions and the following disclaimer.
-.\" 2. Redistributions in binary form must reproduce the above copyright
-.\" notice, this list of conditions and the following disclaimer in the
-.\" documentation and/or other materials provided with the distribution.
-.\" 3. Neither the name of Hyra nor the names of its
-.\" contributors may be used to endorse or promote products derived from
-.\" this software without specific prior written permission.
-.\"
-.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-.\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-.\" ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
-.\" LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
-.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
-.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
-.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
-.\" POSSIBILITY OF SUCH DAMAGE.
-.Dd Mar 13 2024
-.Dt ARCH 9
-.Os Hyra
-.Sh NAME
-.Nm arch - hyra arch information
-.Sh SYNOPSIS
-.In sys/machdep.h
-.In machine/cpu.h
-.In machine/pmap.h
-.Sh DESCRIPTION
-NOTE: All examples will be for x86_64 but can be applied to others
-
-
-Information about how Hyra and architectures work together. This
-will describe headers and .c files that need to exist for all
-architectures and things they should include. The
-.Ft machine/cpu.h
-file contains information about the CPU for the specific
-architecture. Required structures in this header include the
-.Ft cpu_info
-struct which contains CPU specific fields.
-
-Example
-.Ft cpu_info
-structure shown below:
-
-.Bd -literal
-struct cpu_info {
- /* Per-arch fields */
- void *pmap; /* Current pmap */
- uint32_t id;
- struct spinlock lock;
- /* AMD64 */
- ...
-};
-.Ed
-
-There will be some per-architecture fields that, for the sake
-of keeping things tidy, should remain at the top of the struct.
-These fields will be described below.
-
-The
-.Ft pmap
-field points to the current virtual memory context
-which shall be NULL if not used.
-
-The
-.Ft id
-field simply identifies the CPU with a specific "ID".
-
-The
-.Ft lock
-field is a spinlock to prevent race conditions
-while accessing this structure. This must be acquired
-when accessing a
-.Ft cpu_info
-instance.
-
-There are also some common helper macros that shall
-be implemented, these are described below.
-
-The macro
-.Ft this_cpu()
-calls an internal function that fetches the
-cpu_info structure for the current CPU.
-
-The macro
-.Ft get_bsp()
-calls an internal function that fetches the
-cpu_info structure for the BSP.
-
-The macro
-.Ft hint_spinwait()
-hints the processor that it is currently
-in a spin-wait loop. This greatly reduces the
-processor’s power consumption and improves
-the performance of the spin-wait loop.
-
-The function these macros call must return a pointer
-to a
-.Ft cpu_info
-structure.
-
-In the
-.Ft machine/pmap.h
-header, should be a struct containing information
-about the address space. This header MUST be implemented
-or compiler errors will occur.
-
-There also exists a
-.Ft pcb
-(Process Control Block) structure in the
-.Ft machine/pcb.h
-header which contains arch specific information per thread.
-
-This structure must be implemented per arch, this structure shall be set up
-by the machdep subsystem, specifically in the
-.Ft processor_init_pcb()
-routine.
-
-The
-.Ft processor_free_pcb()
-routine shall also be implemented per arch to deallocate
-resources when the thread is killed.
-
-.Sh AUTHORS
-.An Ian Moffett Aq Mt ian@osmora.org
diff --git a/share/man/man9/device.9 b/share/man/man9/device.9
deleted file mode 100644
index 2152749..0000000
--- a/share/man/man9/device.9
+++ /dev/null
@@ -1,64 +0,0 @@
-.\" Copyright (c) 2023-2024 Ian Marco Moffett and the Osmora Team.
-.\" All rights reserved.
-.\"
-.\" Redistribution and use in source and binary forms, with or without
-.\" modification, are permitted provided that the following conditions are met:
-.\"
-.\" 1. Redistributions of source code must retain the above copyright notice,
-.\" this list of conditions and the following disclaimer.
-.\" 2. Redistributions in binary form must reproduce the above copyright
-.\" notice, this list of conditions and the following disclaimer in the
-.\" documentation and/or other materials provided with the distribution.
-.\" 3. Neither the name of Hyra nor the names of its
-.\" contributors may be used to endorse or promote products derived from
-.\" this software without specific prior written permission.
-.\"
-.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-.\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-.\" ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
-.\" LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
-.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
-.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
-.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
-.\" POSSIBILITY OF SUCH DAMAGE.
-.Dd Apr 29 2024
-.Dt DEVICE 9
-.Os Hyra
-.Sh NAME
-.Nm device - hyra device subsystem
-.Sh SYNOPSIS
-.In sys/device.h
-.Sh DESCRIPTION
-Devices registered with the kernel are represented by the device structure:
-
-.Bd -literal
-struct device {
- dev_t major, minor;
- size_t blocksize;
- int(*write)(struct device *dev, struct sio_txn *sio);
- int(*read)(struct device *dev, struct sio_txn *sio);
- int(*ioctl)(struct device *dev, uint32_t cmd, uintptr_t arg);
- ...
- TAILQ_ENTRY(device) link;
-};
-.Ed
-
-Device instances are to be allocated with the
-.Ft device_alloc()
-function. These instances are registered with the kernel by the
-.Ft device_create()
-function.
-
-The major number identifies the driver and the minor number identifies
-the device itself. The major number must be allocated with the
-.Ft device_alloc_major()
-function.
-
-If the device blocksize is greater than 1, this device is considered a block
-device, otherwise if it is 1, it is considered a character device.
-
-.Sh AUTHORS
-.An Ian Moffett Aq Mt ian@osmora.org
diff --git a/share/man/man9/dynalloc.9 b/share/man/man9/dynalloc.9
deleted file mode 100644
index 55b48eb..0000000
--- a/share/man/man9/dynalloc.9
+++ /dev/null
@@ -1,57 +0,0 @@
-.\" Copyright (c) 2023-2024 Ian Marco Moffett and the Osmora Team.
-.\" All rights reserved.
-.\"
-.\" Redistribution and use in source and binary forms, with or without
-.\" modification, are permitted provided that the following conditions are met:
-.\"
-.\" 1. Redistributions of source code must retain the above copyright notice,
-.\" this list of conditions and the following disclaimer.
-.\" 2. Redistributions in binary form must reproduce the above copyright
-.\" notice, this list of conditions and the following disclaimer in the
-.\" documentation and/or other materials provided with the distribution.
-.\" 3. Neither the name of Hyra nor the names of its
-.\" contributors may be used to endorse or promote products derived from
-.\" this software without specific prior written permission.
-.\"
-.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-.\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-.\" ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
-.\" LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
-.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
-.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
-.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
-.\" POSSIBILITY OF SUCH DAMAGE.
-.Dd Mar 28 2024
-.Dt DYNALLOC 9
-.Os Hyra
-.Sh NAME
-.Nm dynalloc - hyra kernel dynamic memory allocation
-.Sh SYNOPSIS
-.In vm/dynalloc.h
-
-.Sh DESCRIPTION
-This subsystem is an abstraction over the Two-Level Segregated
-Fit memory allocator and provides wrappers for allocating, reallocating
-and deallocating memory from a pool allocated per-core.
-
-The
-.Ft dynalloc()
-function is analogous to malloc() in other systems.
-
-The
-.Ft dynalloc_memalign()
-function allows you to allocate aligned memory
-
-The
-.Ft dynrealloc()
-function is analogous to realloc() in other systems.
-
-The
-.Ft dynfree()
-function is analogous to free() in other systems.
-
-.Sh AUTHORS
-.An Ian Moffett Aq Mt ian@osmora.org
diff --git a/share/man/man9/mmio.9 b/share/man/man9/mmio.9
deleted file mode 100644
index 42d0b41..0000000
--- a/share/man/man9/mmio.9
+++ /dev/null
@@ -1,63 +0,0 @@
-.\" Copyright (c) 2023-2024 Ian Marco Moffett and the Osmora Team.
-.\" All rights reserved.
-.\"
-.\" Redistribution and use in source and binary forms, with or without
-.\" modification, are permitted provided that the following conditions are met:
-.\"
-.\" 1. Redistributions of source code must retain the above copyright notice,
-.\" this list of conditions and the following disclaimer.
-.\" 2. Redistributions in binary form must reproduce the above copyright
-.\" notice, this list of conditions and the following disclaimer in the
-.\" documentation and/or other materials provided with the distribution.
-.\" 3. Neither the name of Hyra nor the names of its
-.\" contributors may be used to endorse or promote products derived from
-.\" this software without specific prior written permission.
-.\"
-.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-.\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-.\" ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
-.\" LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
-.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
-.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
-.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
-.\" POSSIBILITY OF SUCH DAMAGE.
-.Dd Jan 12 2024
-.Dt MMIO 9
-.Os Hyra
-.Sh NAME
-.Nm mmio - hyra MMIO interface
-.Sh SYNOPSIS
-.In sys/mmio.h
-
-.Bd -literal
-static inline void mmio_write8(void *addr, uint8_t val);
-static inline void mmio_write16(void *addr, uint16_t val);
-static inline void mmio_write32(void *addr, uint32_t val);
-#if __SIZEOF_SIZE_T__ == 8
-static inline void mmio_write64(void *addr, uint64_t val);
-#endif
-__extension__
-.Ed
-
-.Sh DESCRIPTION
-In short, MMIO is a method of writing to registers
-of an I/O device via a mapped porition of memory. MMIO
-should NOT be done on your own when doing Hyra kernel programming.
-Instead, rely on Hyra's MMIO interface and use
-.Ft mmio_read<n>()
-and
-.Ft mmio_write<n>()
-functions. Where `n` is 8 to 32 on 32-bit machines, and to 64
-on 64-bit machines.
-
-The
-.Ft addr
-argument can be either a physical address or virtual
-address; however, it is recommended to use virtual addresses
-for the sake of consistency.
-
-.Sh AUTHORS
-.An Ian Moffett Aq Mt ian@osmora.org
diff --git a/share/man/man9/pmap.9 b/share/man/man9/pmap.9
deleted file mode 100644
index e50a8ab..0000000
--- a/share/man/man9/pmap.9
+++ /dev/null
@@ -1,75 +0,0 @@
-.\" Copyright (c) 2023-2024 Ian Marco Moffett and the Osmora Team.
-.\" All rights reserved.
-.\"
-.\" Redistribution and use in source and binary forms, with or without
-.\" modification, are permitted provided that the following conditions are met:
-.\"
-.\" 1. Redistributions of source code must retain the above copyright notice,
-.\" this list of conditions and the following disclaimer.
-.\" 2. Redistributions in binary form must reproduce the above copyright
-.\" notice, this list of conditions and the following disclaimer in the
-.\" documentation and/or other materials provided with the distribution.
-.\" 3. Neither the name of Hyra nor the names of its
-.\" contributors may be used to endorse or promote products derived from
-.\" this software without specific prior written permission.
-.\"
-.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-.\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-.\" ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
-.\" LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
-.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
-.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
-.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
-.\" POSSIBILITY OF SUCH DAMAGE.
-.Dd Mar 13 2024
-.Dt PMAP 9
-.Os Hyra
-.Sh NAME
-.Nm pmap - hyra machine dependent virtual memory layer
-.Sh SYNOPSIS
-.In vm/pmap.h
-
-.Bd -literal
-int pmap_map(struct vm_ctx *, vaddr_t, paddr_t, vm_prot_t);
-int pmap_unmap(struct vm_ctx *, vaddr_t);
-.Ed
-
-.Sh DESCRIPTION
-The machine dependent virtual memory layer contains a standard set of
-functions that shall be implemented per architecture and left alone
-outside of vm(9). vm(9) uses pmap routines internally which allows for
-abstracting away machine dependent details.
-
-The
-.Ft pmap_map()
-function is used to map a physical address (paddr_t) to
-a virtual address (vaddr_t). The argument of type
-vm_prot_t is used to give a mapping certain access
-rules. These rules are described below:
-
-The
-.Ft PROT_WRITABLE
-bit tells pmap_map() to allow writes to the page.
-Writes to pages without this bit will result in an exception,
-on AMD64 a #PF will occur.
-
-The
-.Ft PROT_EXEC
-bit tells pmap_map() to allow this page to be
-executable. On platforms like AMD64, execution of pages
-without this bit will result in an exception from the
-instruction fetch, for AMD64, a #PF will occur.
-
-The
-.Ft pmap_unmap()
-function is used to unmap a virtual address which
-leaves the address invalid.
-
-.Sh AUTHORS
-.An Ian Moffett Aq Mt ian@osmora.org
-
-.Sh SEE ALSO
-.Xr vm 9
diff --git a/share/man/man9/syslog.9 b/share/man/man9/syslog.9
deleted file mode 100644
index 3fa8253..0000000
--- a/share/man/man9/syslog.9
+++ /dev/null
@@ -1,61 +0,0 @@
-.\" Copyright (c) 2023-2024 Ian Marco Moffett and the Osmora Team.
-.\" All rights reserved.
-.\"
-.\" Redistribution and use in source and binary forms, with or without
-.\" modification, are permitted provided that the following conditions are met:
-.\"
-.\" 1. Redistributions of source code must retain the above copyright notice,
-.\" this list of conditions and the following disclaimer.
-.\" 2. Redistributions in binary form must reproduce the above copyright
-.\" notice, this list of conditions and the following disclaimer in the
-.\" documentation and/or other materials provided with the distribution.
-.\" 3. Neither the name of Hyra nor the names of its
-.\" contributors may be used to endorse or promote products derived from
-.\" this software without specific prior written permission.
-.\"
-.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-.\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-.\" ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
-.\" LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
-.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
-.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
-.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
-.\" POSSIBILITY OF SUCH DAMAGE.
-.Dd Jan 12 2024
-.Dt SYSLOG 9
-.Os Hyra
-.Sh NAME
-.Nm syslog - hyra system logging interface
-.Sh SYNOPSIS
-.In sys/syslog.h
-
-.Bd -literal
-void kprintf(const char *fmt, ...);
-void vkprintf(const char *fmt, va_list *ap);
-.Ed
-
-.Sh DESCRIPTION
-The Hyra syslog interface allows kernel logging. The
-.Ft kprintf()
-function allows writing a string with formatting.
-
-The
-.Ft vkprintf()
-function allows passing a pointer to a
-.Ft va_list
-somewhere in memory. While essentially doing the same thing as
-.Ft kprintf()
-
-The "%c" format specifier is for characters (single byte)
-
-The "%s" format specifier is for strings
-
-The "%d" format specifier is for base-10 values
-
-The "%x" format specifier is for base-16 values
-
-.Sh AUTHORS
-.An Ian Moffett Aq Mt ian@osmora.org
diff --git a/share/man/man9/timer.9 b/share/man/man9/timer.9
deleted file mode 100644
index 90c7ba8..0000000
--- a/share/man/man9/timer.9
+++ /dev/null
@@ -1,56 +0,0 @@
-.\" Copyright (c) 2023-2024 Ian Marco Moffett and the Osmora Team.
-.\" All rights reserved.
-.\"
-.\" Redistribution and use in source and binary forms, with or without
-.\" modification, are permitted provided that the following conditions are met:
-.\"
-.\" 1. Redistributions of source code must retain the above copyright notice,
-.\" this list of conditions and the following disclaimer.
-.\" 2. Redistributions in binary form must reproduce the above copyright
-.\" notice, this list of conditions and the following disclaimer in the
-.\" documentation and/or other materials provided with the distribution.
-.\" 3. Neither the name of Hyra nor the names of its
-.\" contributors may be used to endorse or promote products derived from
-.\" this software without specific prior written permission.
-.\"
-.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-.\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-.\" ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
-.\" LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
-.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
-.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
-.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
-.\" POSSIBILITY OF SUCH DAMAGE.
-.Dd Jan 12 2024
-.Dt TIMER 9
-.Os Hyra
-.Sh NAME
-.Nm timer - hyra timer abstraction
-.Sh SYNOPSIS
-.In sys/timer.h
-.Sh DESCRIPTION
-The timer registry abstraction allows timers on the machine
-to be registered as a generic timer type allowing other parts
-of the kernel to request a timer of that type e.g scheduler reserved
-timers (TIMER_SCHED). All timers within the system are represented via
-a timer descriptor which is simply the
-.Ft timer
-struct.
-
-The timer struct pointer fields are optional and must
-be
-.Ft NULL
-if unused. Therefore it is the requesting kernel module's responsibility to verify
-a field is not unused before using it for obvious reasons.
-
-
-However, it is highly recommended to set the
-.Ft name
-field. This field on an HPET timer could be, for example:
-.Ft HIGH_PRECISION_EVENT_TIMER
-
-.Sh AUTHORS
-.An Ian Moffett Aq Mt ian@osmora.org
diff --git a/share/man/man9/vm.9 b/share/man/man9/vm.9
deleted file mode 100644
index d885895..0000000
--- a/share/man/man9/vm.9
+++ /dev/null
@@ -1,67 +0,0 @@
-.\" Copyright (c) 2023-2024 Ian Marco Moffett and the Osmora Team.
-.\" All rights reserved.
-.\"
-.\" Redistribution and use in source and binary forms, with or without
-.\" modification, are permitted provided that the following conditions are met:
-.\"
-.\" 1. Redistributions of source code must retain the above copyright notice,
-.\" this list of conditions and the following disclaimer.
-.\" 2. Redistributions in binary form must reproduce the above copyright
-.\" notice, this list of conditions and the following disclaimer in the
-.\" documentation and/or other materials provided with the distribution.
-.\" 3. Neither the name of Hyra nor the names of its
-.\" contributors may be used to endorse or promote products derived from
-.\" this software without specific prior written permission.
-.\"
-.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
-.\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-.\" ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
-.\" LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
-.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
-.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
-.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
-.\" POSSIBILITY OF SUCH DAMAGE.
-.Dd Jan 12 2024
-.Dt VM 9
-.Os Hyra
-.Sh NAME
-.Nm vm - hyra machine independent virtual memory layer
-.Sh SYNOPSIS
-.In vm/vm.h
-.Sh DESCRIPTION
-The Hyra virtual memory subsystem handles various aspects of
-virtual memory like memory mapping, keeping track of the virtual
-memory context per core, etc. It is split up into two layers, the
-machine independent layer (that this manpage describes), and the
-machine dependent layer called the pmap layer.
-
-The term `kernel physical address' will be used to describe physical
-addresses that are mapped to the higher half.
-
-The
-.Ft VM_HIGHER_HALF
-macro points to the higher half of the virtual memory space...
-The mapping of kernel physical addresses to virtual addresses are
-done with respect to the higher half, i.e., virtual = physical + hddm
-(where hddm is the higher half). This cleanly reserves the lower half
-of the virtual address space for userspace applications.
-
-The
-.Ft PHYS_TO_VIRT
-macro converts a kernel physical address to a higher half
-virtual address.
-
-The
-.Ft VIRT_TO_PHYS
-macro converts a higher half virtual address to a kernel
-physical address.
-
-.Sh AUTHORS
-.An Ian Moffett Aq Mt ian@osmora.org
-
-.Sh SEE ALSO
-.Xr dynalloc 9
-.Xr pmap 9
diff --git a/share/misc/contrib b/share/misc/contrib
deleted file mode 100644
index 625a83d..0000000
--- a/share/misc/contrib
+++ /dev/null
@@ -1,134 +0,0 @@
-==============================
-Hyra Contribution Guidelines
-==============================
-
-!! C PROGRAMMING STYLE !!
-
-The .vimrc file that follows this style can be found in
-share/misc/vimrc
-
-Indent width is 4-spaces (NO TABS)
-
-The typename must go above the function name like so:
-
-static inline bool
-is_power_of_two(uint8_t n)
-{
- if (g_foo) {
- ...
- }
-
- return ((n & 0x01) == 0);
-}
-
-When checking if an integer is 0 or not, *be explicit* unless it is a bool!
-Do not do this:
-
-#define BLAH 1
-
-if (!BLAH) {
- ...
-}
-
-Do this instead:
-
-if (BLAH == 0) {
- ...
-}
-
--- or if it is a bool:
-
-#define BLAH true
-
-if (!blah) {
- ...
-}
-
---
-
-Now, only use predefined integer types in sys/cdefs.h like so:
-
-uint8_t a;
-uint16_t b;
-uint32_t c;
---
-
-All includes must be done with '< >':
-
-#include <sys/cdefs.h>
---
-
-
-When including architecture specific things, it would be stupid
-to include for another architecture. Only include from machine/ which
-points to the architecture specific files for the current architecture.
-For example:
-
-/* AMD64-specific, in sys/include/arch/amd64/lapic.h */
-#include <machine/lapic.h>
---
-
-Avoid initializing variables to e.g. 0 unless it seems wise to do so.
-Try to avoid this:
-
-uint8_t foo = 0;
-...
-
-It is best to do this instead:
-
-uint8_t foo;
-...
-
-foo = some_calculation();
---
-
-One of the only times it is best to do that is when you have
-a pointer, like, for example:
-
-uint8_t *ptr = NULL;
-...
-
--- or if you have for example, some sort of counter value
- that must have a start:
-
-uint8_t countdown = COUNTDOWN_START;
---
-
-!! COMMIT STYLE !!
-
-Keep commits small if possible. Follow commit good practices.
-
-- Commit examples -
-1) Some manpage update:
- docs: man: Describe foo in foobar(9)
-
-2) Adding a tool in tools/
- build: tools: Create foo
-
- This commit adds a new script in tools/
- that does x and y ...
-
-- Kernel commits -
-An example of a commit title for a non architecture-specific commit:
- kernel: foo: Fix bar in foobar
-
-An example of an architecture specific commit e.g. for AMD64:
-kernel/amd64: foo: Add foo in bar
-
-- Ready to commit -
-
-(BE SURE TO TEST IT!! IDEALLY ON REAL HW TOO IF POSSIBLE!)
-
-* Commit with `git commit -sv`
-* Create patch with `git format-patch -1 HEAD`
-* Email patch to ian@osmora.org and for better response times,
- optionally CC to blazt@osmora.org and bion@osmora.org
-
-Done!
-
-------------------------------------------------
-NOTE TO MAINTAINERS
-
-For those who maintain the Hyra repo, when testing a patch, apply it like so:
-`git am -s patchfile.patch`. If all good, create a new patch and email it to
-ian@osmora.org
diff --git a/share/misc/vimrc b/share/misc/vimrc
deleted file mode 100644
index f8a2ba8..0000000
--- a/share/misc/vimrc
+++ /dev/null
@@ -1,7 +0,0 @@
-set cindent
-set cinoptions=(4200,u4200,+0.5s,*500,:0,t0,U4200
-set indentexpr=IgnoreParenIndent()
-set indentkeys=0{,0},0),:,0#,!^F,o,O,e
-set sw=4 ts=4
-set softtabstop=4
-set expandtab