diff --git a/lib/mammoth/CMakeLists.txt b/lib/mammoth/CMakeLists.txt index aea2e76..0029633 100644 --- a/lib/mammoth/CMakeLists.txt +++ b/lib/mammoth/CMakeLists.txt @@ -6,12 +6,12 @@ add_library(mammoth STATIC ipc/port_server.cpp proc/process.cpp proc/thread.cpp - src/debug.cpp - src/init.cpp - src/memory_region.cpp - src/new.cpp sync/mutex.cpp sync/semaphore.cpp + util/debug.cpp + util/init.cpp + util/memory_region.cpp + util/new.cpp ) target_include_directories(mammoth diff --git a/lib/mammoth/ipc/channel.cpp b/lib/mammoth/ipc/channel.cpp index a56b0ff..efd62a4 100644 --- a/lib/mammoth/ipc/channel.cpp +++ b/lib/mammoth/ipc/channel.cpp @@ -2,7 +2,7 @@ #include -#include "mammoth/debug.h" +#include "util/debug.h" namespace { diff --git a/lib/mammoth/ipc/endpoint_server.cpp b/lib/mammoth/ipc/endpoint_server.cpp index f108af5..e35e1fb 100644 --- a/lib/mammoth/ipc/endpoint_server.cpp +++ b/lib/mammoth/ipc/endpoint_server.cpp @@ -1,6 +1,6 @@ #include "ipc/endpoint_server.h" -#include "mammoth/debug.h" +#include "util/debug.h" // Declared as friend in EndpointServer. void EndpointServerThreadBootstrap(void* endpoint_server) { diff --git a/lib/mammoth/ipc/port_client.cpp b/lib/mammoth/ipc/port_client.cpp index a54a736..7d6b774 100644 --- a/lib/mammoth/ipc/port_client.cpp +++ b/lib/mammoth/ipc/port_client.cpp @@ -3,7 +3,7 @@ #include #include -#include "mammoth/debug.h" +#include "util/debug.h" PortClient PortClient::AdoptPort(z_cap_t cap) { return PortClient(cap); } PortClient::PortClient(z_cap_t port_cap) : port_cap_(port_cap) {} diff --git a/lib/mammoth/proc/process.cpp b/lib/mammoth/proc/process.cpp index 2e4b996..de7a71b 100644 --- a/lib/mammoth/proc/process.cpp +++ b/lib/mammoth/proc/process.cpp @@ -3,11 +3,11 @@ #include #include -#include "mammoth/debug.h" -#include "mammoth/init.h" -#include "mammoth/ipc/endpoint_server.h" -#include "mammoth/ipc/port_client.h" -#include "mammoth/ipc/port_server.h" +#include "ipc/endpoint_server.h" +#include "ipc/port_client.h" +#include "ipc/port_server.h" +#include "util/debug.h" +#include "util/init.h" #define MAM_PROC_DEBUG 0 diff --git a/lib/mammoth/proc/thread.cpp b/lib/mammoth/proc/thread.cpp index 849032c..dc0b517 100644 --- a/lib/mammoth/proc/thread.cpp +++ b/lib/mammoth/proc/thread.cpp @@ -2,8 +2,8 @@ #include -#include "mammoth/debug.h" -#include "mammoth/init.h" +#include "util/debug.h" +#include "util/init.h" namespace { diff --git a/lib/mammoth/sync/semaphore.cpp b/lib/mammoth/sync/semaphore.cpp index 5979902..1a9dbad 100644 --- a/lib/mammoth/sync/semaphore.cpp +++ b/lib/mammoth/sync/semaphore.cpp @@ -2,7 +2,7 @@ #include -#include "mammoth/debug.h" +#include "util/debug.h" Semaphore::Semaphore() { check(ZSemaphoreCreate(&semaphore_cap_)); } Semaphore::~Semaphore() { check(ZCapRelease(semaphore_cap_)); } diff --git a/lib/mammoth/src/debug.cpp b/lib/mammoth/util/debug.cpp similarity index 95% rename from lib/mammoth/src/debug.cpp rename to lib/mammoth/util/debug.cpp index 337580c..a9016ee 100644 --- a/lib/mammoth/src/debug.cpp +++ b/lib/mammoth/util/debug.cpp @@ -1,4 +1,4 @@ -#include "include/mammoth/debug.h" +#include "util/debug.h" #include #include diff --git a/lib/mammoth/include/mammoth/debug.h b/lib/mammoth/util/debug.h similarity index 100% rename from lib/mammoth/include/mammoth/debug.h rename to lib/mammoth/util/debug.h diff --git a/lib/mammoth/src/init.cpp b/lib/mammoth/util/init.cpp similarity index 93% rename from lib/mammoth/src/init.cpp rename to lib/mammoth/util/init.cpp index 6644f15..c103e91 100644 --- a/lib/mammoth/src/init.cpp +++ b/lib/mammoth/util/init.cpp @@ -1,10 +1,10 @@ -#include "mammoth/init.h" +#include "util/init.h" #include #include -#include "mammoth/debug.h" -#include "mammoth/ipc/port_server.h" +#include "ipc/port_server.h" +#include "util/debug.h" uint64_t gSelfProcCap = 0; uint64_t gSelfVmasCap = 0; diff --git a/lib/mammoth/include/mammoth/init.h b/lib/mammoth/util/init.h similarity index 100% rename from lib/mammoth/include/mammoth/init.h rename to lib/mammoth/util/init.h diff --git a/lib/mammoth/src/memory_region.cpp b/lib/mammoth/util/memory_region.cpp similarity index 95% rename from lib/mammoth/src/memory_region.cpp rename to lib/mammoth/util/memory_region.cpp index d4b88e0..067160f 100644 --- a/lib/mammoth/src/memory_region.cpp +++ b/lib/mammoth/util/memory_region.cpp @@ -1,9 +1,9 @@ -#include "mammoth/memory_region.h" +#include "util/memory_region.h" #include -#include "mammoth/debug.h" -#include "mammoth/init.h" +#include "util/debug.h" +#include "util/init.h" OwnedMemoryRegion::OwnedMemoryRegion(OwnedMemoryRegion&& other) : OwnedMemoryRegion(other.vmmo_cap_, other.vaddr_, other.size_) { diff --git a/lib/mammoth/include/mammoth/memory_region.h b/lib/mammoth/util/memory_region.h similarity index 100% rename from lib/mammoth/include/mammoth/memory_region.h rename to lib/mammoth/util/memory_region.h diff --git a/lib/mammoth/src/new.cpp b/lib/mammoth/util/new.cpp similarity index 100% rename from lib/mammoth/src/new.cpp rename to lib/mammoth/util/new.cpp diff --git a/sys/denali/ahci/ahci_device.cpp b/sys/denali/ahci/ahci_device.cpp index cc8e7a3..d2b1f82 100644 --- a/sys/denali/ahci/ahci_device.cpp +++ b/sys/denali/ahci/ahci_device.cpp @@ -1,7 +1,7 @@ #include "ahci/ahci_device.h" #include -#include +#include #include #include diff --git a/sys/denali/ahci/ahci_device.h b/sys/denali/ahci/ahci_device.h index 71f39aa..2d35da6 100644 --- a/sys/denali/ahci/ahci_device.h +++ b/sys/denali/ahci/ahci_device.h @@ -1,7 +1,7 @@ #pragma once #include -#include +#include #include #include "ahci/ahci.h" diff --git a/sys/denali/ahci/ahci_driver.cpp b/sys/denali/ahci/ahci_driver.cpp index 7430723..626d92b 100644 --- a/sys/denali/ahci/ahci_driver.cpp +++ b/sys/denali/ahci/ahci_driver.cpp @@ -2,7 +2,7 @@ #include #include -#include +#include #include #include diff --git a/sys/denali/denali.cpp b/sys/denali/denali.cpp index 907425a..3f1eeb3 100644 --- a/sys/denali/denali.cpp +++ b/sys/denali/denali.cpp @@ -1,6 +1,6 @@ -#include -#include +#include +#include #include #include diff --git a/sys/denali/denali_server.cpp b/sys/denali/denali_server.cpp index 7745219..37494ca 100644 --- a/sys/denali/denali_server.cpp +++ b/sys/denali/denali_server.cpp @@ -2,7 +2,7 @@ #include #include -#include +#include #include glcr::ErrorOr> DenaliServer::Create( diff --git a/sys/denali/lib/denali/denali.yunq.server.cpp b/sys/denali/lib/denali/denali.yunq.server.cpp index 0610cb3..9398599 100644 --- a/sys/denali/lib/denali/denali.yunq.server.cpp +++ b/sys/denali/lib/denali/denali.yunq.server.cpp @@ -1,7 +1,7 @@ // Generated file -- DO NOT MODIFY. #include "denali.yunq.server.h" -#include +#include #include namespace { diff --git a/sys/teton/framebuffer/console.cpp b/sys/teton/framebuffer/console.cpp index 0086cbc..b1713bd 100644 --- a/sys/teton/framebuffer/console.cpp +++ b/sys/teton/framebuffer/console.cpp @@ -1,6 +1,6 @@ #include "framebuffer/console.h" -#include +#include void Console::WriteChar(char c) { if (c == '\n') { diff --git a/sys/teton/framebuffer/framebuffer.h b/sys/teton/framebuffer/framebuffer.h index f0e1164..0edfa39 100644 --- a/sys/teton/framebuffer/framebuffer.h +++ b/sys/teton/framebuffer/framebuffer.h @@ -1,6 +1,6 @@ #pragma once -#include +#include #include class Framebuffer { diff --git a/sys/teton/framebuffer/psf.cpp b/sys/teton/framebuffer/psf.cpp index 0c78ac1..8f381c2 100644 --- a/sys/teton/framebuffer/psf.cpp +++ b/sys/teton/framebuffer/psf.cpp @@ -1,7 +1,7 @@ #include "framebuffer/psf.h" #include -#include +#include namespace { diff --git a/sys/teton/framebuffer/psf.h b/sys/teton/framebuffer/psf.h index 6d6fab7..f330984 100644 --- a/sys/teton/framebuffer/psf.h +++ b/sys/teton/framebuffer/psf.h @@ -1,6 +1,6 @@ #pragma once -#include +#include struct PsfHeader { uint32_t magic; /* magic bytes to identify PSF */ diff --git a/sys/teton/teton.cpp b/sys/teton/teton.cpp index 9152f8b..f3e3853 100644 --- a/sys/teton/teton.cpp +++ b/sys/teton/teton.cpp @@ -1,5 +1,5 @@ -#include -#include +#include +#include #include #include diff --git a/sys/victoriafalls/fs/ext2/ext2_block_reader.cpp b/sys/victoriafalls/fs/ext2/ext2_block_reader.cpp index 89f1d60..287e8e7 100644 --- a/sys/victoriafalls/fs/ext2/ext2_block_reader.cpp +++ b/sys/victoriafalls/fs/ext2/ext2_block_reader.cpp @@ -1,6 +1,6 @@ #include "fs/ext2/ext2_block_reader.h" -#include "mammoth/debug.h" +#include glcr::ErrorOr> Ext2BlockReader::Init( const DenaliInfo& denali_info) { diff --git a/sys/victoriafalls/fs/ext2/ext2_block_reader.h b/sys/victoriafalls/fs/ext2/ext2_block_reader.h index d30914a..f2da664 100644 --- a/sys/victoriafalls/fs/ext2/ext2_block_reader.h +++ b/sys/victoriafalls/fs/ext2/ext2_block_reader.h @@ -3,7 +3,7 @@ #include #include #include -#include +#include #include #include "fs/ext2/ext2.h" diff --git a/sys/victoriafalls/fs/ext2/ext2_driver.cpp b/sys/victoriafalls/fs/ext2/ext2_driver.cpp index 05e4091..beb4b5b 100644 --- a/sys/victoriafalls/fs/ext2/ext2_driver.cpp +++ b/sys/victoriafalls/fs/ext2/ext2_driver.cpp @@ -1,7 +1,7 @@ #include "fs/ext2/ext2_driver.h" #include -#include +#include glcr::ErrorOr Ext2Driver::Init(const DenaliInfo& denali_info) { ASSIGN_OR_RETURN(glcr::SharedPtr reader, diff --git a/sys/victoriafalls/fs/ext2/inode_table.cpp b/sys/victoriafalls/fs/ext2/inode_table.cpp index cfb5a15..521b635 100644 --- a/sys/victoriafalls/fs/ext2/inode_table.cpp +++ b/sys/victoriafalls/fs/ext2/inode_table.cpp @@ -1,7 +1,5 @@ #include "fs/ext2/inode_table.h" -#include - InodeTable::InodeTable(const glcr::SharedPtr& reader, OwnedMemoryRegion&& bgdt_region) : ext2_reader_(reader), diff --git a/sys/victoriafalls/fs/ext2/inode_table.h b/sys/victoriafalls/fs/ext2/inode_table.h index 401a3b3..5efc0f7 100644 --- a/sys/victoriafalls/fs/ext2/inode_table.h +++ b/sys/victoriafalls/fs/ext2/inode_table.h @@ -1,6 +1,7 @@ #pragma once #include +#include #include #include "fs/ext2/ext2_block_reader.h" diff --git a/sys/victoriafalls/lib/victoriafalls/victoriafalls.yunq.server.cpp b/sys/victoriafalls/lib/victoriafalls/victoriafalls.yunq.server.cpp index 19ca931..cdafc39 100644 --- a/sys/victoriafalls/lib/victoriafalls/victoriafalls.yunq.server.cpp +++ b/sys/victoriafalls/lib/victoriafalls/victoriafalls.yunq.server.cpp @@ -1,7 +1,7 @@ // Generated file -- DO NOT MODIFY. #include "victoriafalls.yunq.server.h" -#include +#include #include namespace { diff --git a/sys/victoriafalls/victoriafalls.cpp b/sys/victoriafalls/victoriafalls.cpp index 5d89d82..79090f6 100644 --- a/sys/victoriafalls/victoriafalls.cpp +++ b/sys/victoriafalls/victoriafalls.cpp @@ -1,5 +1,5 @@ -#include -#include +#include +#include #include #include "fs/ext2/ext2_driver.h" diff --git a/sys/victoriafalls/victoriafalls_server.cpp b/sys/victoriafalls/victoriafalls_server.cpp index bf16f2b..e885464 100644 --- a/sys/victoriafalls/victoriafalls_server.cpp +++ b/sys/victoriafalls/victoriafalls_server.cpp @@ -1,7 +1,7 @@ #include "victoriafalls_server.h" #include -#include +#include #include glcr::ErrorOr> VFSServer::Create( diff --git a/sys/yellowstone/hw/gpt.cpp b/sys/yellowstone/hw/gpt.cpp index 2ce326b..52e526b 100644 --- a/sys/yellowstone/hw/gpt.cpp +++ b/sys/yellowstone/hw/gpt.cpp @@ -2,8 +2,8 @@ #include #include -#include -#include +#include +#include #include #include diff --git a/sys/yellowstone/hw/pcie.cpp b/sys/yellowstone/hw/pcie.cpp index 2ab13ec..1a89233 100644 --- a/sys/yellowstone/hw/pcie.cpp +++ b/sys/yellowstone/hw/pcie.cpp @@ -1,7 +1,7 @@ #include "hw/pcie.h" -#include -#include +#include +#include #include #define PCI_DEBUG 0 diff --git a/sys/yellowstone/lib/yellowstone/yellowstone.yunq.server.cpp b/sys/yellowstone/lib/yellowstone/yellowstone.yunq.server.cpp index d57144f..f84bce4 100644 --- a/sys/yellowstone/lib/yellowstone/yellowstone.yunq.server.cpp +++ b/sys/yellowstone/lib/yellowstone/yellowstone.yunq.server.cpp @@ -1,7 +1,7 @@ // Generated file -- DO NOT MODIFY. #include "yellowstone.yunq.server.h" -#include +#include #include namespace { diff --git a/sys/yellowstone/yellowstone.cpp b/sys/yellowstone/yellowstone.cpp index 467974d..c4d2ef3 100644 --- a/sys/yellowstone/yellowstone.cpp +++ b/sys/yellowstone/yellowstone.cpp @@ -1,9 +1,9 @@ #include #include -#include -#include -#include #include +#include +#include +#include #include #include diff --git a/sys/yellowstone/yellowstone_server.cpp b/sys/yellowstone/yellowstone_server.cpp index d2ab8f5..db55998 100644 --- a/sys/yellowstone/yellowstone_server.cpp +++ b/sys/yellowstone/yellowstone_server.cpp @@ -2,9 +2,9 @@ #include #include -#include -#include -#include +#include +#include +#include #include #include diff --git a/yunq/server.cpp.jinja b/yunq/server.cpp.jinja index 358ce83..6f215d4 100644 --- a/yunq/server.cpp.jinja +++ b/yunq/server.cpp.jinja @@ -1,7 +1,7 @@ // Generated file -- DO NOT MODIFY. #include "{{file}}.server.h" -#include +#include #include namespace {