1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 13:28:11 +00:00
serenity/Kernel/FileSystem
Ben Wiederhake 42b057b0c9 Kernel: Mark compilation-unit-only functions as static
This enables a nice warning in case a function becomes dead code. Also, in case
of signal_trampoline_dummy, marking it external (non-static) prevents it from
being 'optimized away', which would lead to surprising and weird linker errors.

I found these places by using -Wmissing-declarations.

The Kernel still shows these issues, which I think are false-positives,
but don't want to touch:
- Kernel/Arch/i386/CPU.cpp:1081:17: void Kernel::enter_thread_context(Kernel::Thread*, Kernel::Thread*)
- Kernel/Arch/i386/CPU.cpp:1170:17: void Kernel::context_first_init(Kernel::Thread*, Kernel::Thread*, Kernel::TrapFrame*)
- Kernel/Arch/i386/CPU.cpp:1304:16: u32 Kernel::do_init_context(Kernel::Thread*, u32)
- Kernel/Arch/i386/CPU.cpp:1347:17: void Kernel::pre_init_finished()
- Kernel/Arch/i386/CPU.cpp:1360:17: void Kernel::post_init_finished()
	No idea, not gonna touch it.
- Kernel/init.cpp:104:30: void Kernel::init()
- Kernel/init.cpp:167:30: void Kernel::init_ap(u32, Kernel::Processor*)
- Kernel/init.cpp:184:17: void Kernel::init_finished(u32)
	Called by boot.S.
- Kernel/init.cpp:383:16: int Kernel::__cxa_atexit(void (*)(void*), void*, void*)
- Kernel/StdLib.cpp:285:19: void __cxa_pure_virtual()
- Kernel/StdLib.cpp:300:19: void __stack_chk_fail()
- Kernel/StdLib.cpp:305:19: void __stack_chk_fail_local()
	Not sure how to tell the compiler that the compiler is already using them.
	Also, maybe __cxa_atexit should go into StdLib.cpp?
- Kernel/Modules/TestModule.cpp:31:17: void module_init()
- Kernel/Modules/TestModule.cpp:40:17: void module_fini()
	Could maybe go into a new header. This would also provide type-checking for new modules.
2020-08-12 20:40:59 +02:00
..
BlockBasedFileSystem.cpp Kernel: Fix build break from missing KResult [[nodiscard]] suppressions 2020-08-05 14:06:54 +02:00
BlockBasedFileSystem.h Kernel: Split BlockBasedFileSystem off FileBackedFileSystem 2020-07-05 12:26:27 +02:00
Custody.cpp Kernel: Support read-only filesystem mounts 2020-05-29 07:53:30 +02:00
Custody.h Kernel: Support read-only filesystem mounts 2020-05-29 07:53:30 +02:00
DevPtsFS.cpp Kernel: Make Inode::directory_entry_count errors observable. 2020-08-05 10:26:29 +02:00
DevPtsFS.h Kernel: Make Inode::directory_entry_count errors observable. 2020-08-05 10:26:29 +02:00
ext2_fs.h Meta: Remove some copyright headers added in error 2020-01-25 10:34:32 +01:00
ext2_types.h Meta: Add a script check the presence of "#pragma once" in header files 2020-05-29 07:59:45 +02:00
Ext2FileSystem.cpp Kernel: Suppress remaining unobserved KResult return codes 2020-08-05 14:36:48 +02:00
Ext2FileSystem.h Kernel: Make Inode::directory_entry_count errors observable. 2020-08-05 10:26:29 +02:00
FIFO.cpp Kernel: Mark compilation-unit-only functions as static 2020-08-12 20:40:59 +02:00
FIFO.h Kernel: Make File::write() and File::read() return KResultOr<size_t> 2020-08-04 18:17:16 +02:00
File.cpp Kernel: Allow File::close() to fail 2020-06-02 21:49:47 +02:00
File.h Kernel: Make File::write() and File::read() return KResultOr<size_t> 2020-08-04 18:17:16 +02:00
FileBackedFileSystem.cpp Kernel: Split BlockBasedFileSystem off FileBackedFileSystem 2020-07-05 12:26:27 +02:00
FileBackedFileSystem.h Kernel: Split BlockBasedFileSystem off FileBackedFileSystem 2020-07-05 12:26:27 +02:00
FileDescription.cpp Kernel: Make Inode::read_entire() return a KBuffer (not ByteBuffer) 2020-08-11 20:29:14 +02:00
FileDescription.h Kernel: Make Inode::read_entire() return a KBuffer (not ByteBuffer) 2020-08-11 20:29:14 +02:00
FileSystem.cpp Kernel: Make FS::block_size a size_t 2020-05-19 11:07:35 +02:00
FileSystem.h Kernel: Port mounts to reference inodes directly 2020-06-25 15:49:04 +02:00
Inode.cpp Kernel: Mark compilation-unit-only functions as static 2020-08-12 20:40:59 +02:00
Inode.h Kernel: Make Inode::read_entire() return a KBuffer (not ByteBuffer) 2020-08-11 20:29:14 +02:00
InodeFile.cpp Kernel: Make File::write() and File::read() return KResultOr<size_t> 2020-08-04 18:17:16 +02:00
InodeFile.h Kernel: Make File::write() and File::read() return KResultOr<size_t> 2020-08-04 18:17:16 +02:00
InodeIdentifier.h Kernel: Deemphasize inode identifiers 2020-06-25 15:49:04 +02:00
InodeMetadata.h Kernel: Use symbolic constants for file modes 2020-06-17 15:02:03 +02:00
InodeWatcher.cpp Kernel: Make File::write() and File::read() return KResultOr<size_t> 2020-08-04 18:17:16 +02:00
InodeWatcher.h Kernel: Make File::write() and File::read() return KResultOr<size_t> 2020-08-04 18:17:16 +02:00
Plan9FileSystem.cpp Kernel: Suppress remaining unobserved KResult return codes 2020-08-05 14:36:48 +02:00
Plan9FileSystem.h Kernel: Make Inode::directory_entry_count errors observable. 2020-08-05 10:26:29 +02:00
ProcFS.cpp Kernel: Mark compilation-unit-only functions as static 2020-08-12 20:40:59 +02:00
ProcFS.h Kernel: Make Inode::directory_entry_count errors observable. 2020-08-05 10:26:29 +02:00
TmpFS.cpp Kernel: Make Inode::directory_entry_count errors observable. 2020-08-05 10:26:29 +02:00
TmpFS.h Kernel: Make Inode::directory_entry_count errors observable. 2020-08-05 10:26:29 +02:00
VirtualFileSystem.cpp Kernel: Propagate a few KResults properly in FileSystem subsystems 2020-08-05 14:36:48 +02:00
VirtualFileSystem.h Kernel: Propagate a few KResults properly in FileSystem subsystems 2020-08-05 14:36:48 +02:00