summaryrefslogtreecommitdiff
path: root/Kernel
diff options
context:
space:
mode:
authorLinus Groh <mail@linusgroh.de>2020-10-02 22:14:37 +0100
committerAndreas Kling <kling@serenityos.org>2020-10-03 12:36:49 +0200
commitbcfc6f0c57f9d4ce4343cbb6ee0f0ab8de56c789 (patch)
treed3e16e6361f4693ae5362c10da05bc6a4ad30190 /Kernel
parent4e86c34ef0d1d227309f8e8d22be5ea737830c24 (diff)
downloadserenity-bcfc6f0c57f9d4ce4343cbb6ee0f0ab8de56c789.zip
Everywhere: Fix more typos
Diffstat (limited to 'Kernel')
-rw-r--r--Kernel/API/Syscall.h2
-rw-r--r--Kernel/Arch/i386/CPU.cpp2
-rw-r--r--Kernel/Devices/EBRPartitionTable.cpp2
-rw-r--r--Kernel/Devices/GPTPartitionTable.cpp2
-rw-r--r--Kernel/Devices/MBRPartitionTable.cpp2
-rw-r--r--Kernel/FileSystem/TmpFS.cpp2
-rw-r--r--Kernel/Net/RTL8139NetworkAdapter.cpp2
-rw-r--r--Kernel/Process.cpp2
-rw-r--r--Kernel/Scheduler.cpp2
-rw-r--r--Kernel/Syscalls/execve.cpp12
-rw-r--r--Kernel/TTY/TTY.cpp6
-rw-r--r--Kernel/Thread.cpp2
-rw-r--r--Kernel/Time/RTC.cpp2
13 files changed, 20 insertions, 20 deletions
diff --git a/Kernel/API/Syscall.h b/Kernel/API/Syscall.h
index 7be30ad81c..c322d1bbd6 100644
--- a/Kernel/API/Syscall.h
+++ b/Kernel/API/Syscall.h
@@ -330,7 +330,7 @@ struct SC_setkeymap_params {
struct SC_create_thread_params {
unsigned int m_detach_state = 0; // JOINABLE or DETACHED
int m_schedule_priority = 30; // THREAD_PRIORITY_NORMAL
- // FIXME: Implment guard pages in create_thread (unreadable pages at "overflow" end of stack)
+ // FIXME: Implement guard pages in create_thread (unreadable pages at "overflow" end of stack)
// "If an implementation rounds up the value of guardsize to a multiple of {PAGESIZE},
// a call to pthread_attr_getguardsize() specifying attr shall store in the guardsize
// parameter the guard size specified by the previous pthread_attr_setguardsize() function call"
diff --git a/Kernel/Arch/i386/CPU.cpp b/Kernel/Arch/i386/CPU.cpp
index 52951f0167..2634c9eecd 100644
--- a/Kernel/Arch/i386/CPU.cpp
+++ b/Kernel/Arch/i386/CPU.cpp
@@ -1590,7 +1590,7 @@ void Processor::initialize_context_switching(Thread& initial_thread)
m_scheduler_initialized = true;
asm volatile(
- "movl %[new_esp], %%esp \n" // swich to new stack
+ "movl %[new_esp], %%esp \n" // switch to new stack
"pushl %[from_to_thread] \n" // to_thread
"pushl %[from_to_thread] \n" // from_thread
"pushl $" __STRINGIFY(GDT_SELECTOR_CODE0) " \n"
diff --git a/Kernel/Devices/EBRPartitionTable.cpp b/Kernel/Devices/EBRPartitionTable.cpp
index 48826636de..bfaf999162 100644
--- a/Kernel/Devices/EBRPartitionTable.cpp
+++ b/Kernel/Devices/EBRPartitionTable.cpp
@@ -192,7 +192,7 @@ RefPtr<DiskPartition> EBRPartitionTable::partition(unsigned index)
auto& header = this->header();
if (header.mbr_signature != MBR_SIGNATURE) {
- klog() << "EBRPartitionTable::initialize: bad MBR signature - not initalized? 0x" << String::format("%x", header.mbr_signature);
+ klog() << "EBRPartitionTable::initialize: bad MBR signature - not initialized? 0x" << String::format("%x", header.mbr_signature);
return nullptr;
}
if (index_is_extended_partition(index))
diff --git a/Kernel/Devices/GPTPartitionTable.cpp b/Kernel/Devices/GPTPartitionTable.cpp
index f442952cd6..9031269031 100644
--- a/Kernel/Devices/GPTPartitionTable.cpp
+++ b/Kernel/Devices/GPTPartitionTable.cpp
@@ -76,7 +76,7 @@ RefPtr<DiskPartition> GPTPartitionTable::partition(unsigned index)
unsigned lba = header.partition_array_start_lba + (((index - 1) * header.partition_entry_size) / BytesPerSector);
if (header.sig[0] != GPT_SIGNATURE) {
- klog() << "GPTPartitionTable::initialize: bad gpt signature - not initalized? 0x" << String::format("%x", header.sig);
+ klog() << "GPTPartitionTable::initialize: bad gpt signature - not initialized? 0x" << String::format("%x", header.sig);
return nullptr;
}
diff --git a/Kernel/Devices/MBRPartitionTable.cpp b/Kernel/Devices/MBRPartitionTable.cpp
index a57a5db310..716e02119e 100644
--- a/Kernel/Devices/MBRPartitionTable.cpp
+++ b/Kernel/Devices/MBRPartitionTable.cpp
@@ -90,7 +90,7 @@ RefPtr<DiskPartition> MBRPartitionTable::partition(unsigned index)
auto& entry = header.entry[index - 1];
if (header.mbr_signature != MBR_SIGNATURE) {
- klog() << "MBRPartitionTable::initialize: bad mbr signature - not initalized? 0x" << String::format("%x", header.mbr_signature);
+ klog() << "MBRPartitionTable::initialize: bad mbr signature - not initialized? 0x" << String::format("%x", header.mbr_signature);
return nullptr;
}
diff --git a/Kernel/FileSystem/TmpFS.cpp b/Kernel/FileSystem/TmpFS.cpp
index 24b7acc638..2109cfce2a 100644
--- a/Kernel/FileSystem/TmpFS.cpp
+++ b/Kernel/FileSystem/TmpFS.cpp
@@ -181,7 +181,7 @@ ssize_t TmpFSInode::write_bytes(off_t offset, ssize_t size, const UserOrKernelBu
if (m_content.has_value() && m_content.value().capacity() >= (size_t)new_size) {
m_content.value().set_size(new_size);
} else {
- // Grow the content buffer 2x the new sizeto accomodate repeating write() calls.
+ // Grow the content buffer 2x the new sizeto accommodate repeating write() calls.
// Note that we're not actually committing physical memory to the buffer
// until it's needed. We only grow VM here.
diff --git a/Kernel/Net/RTL8139NetworkAdapter.cpp b/Kernel/Net/RTL8139NetworkAdapter.cpp
index 7d749fe11f..efb26fdb92 100644
--- a/Kernel/Net/RTL8139NetworkAdapter.cpp
+++ b/Kernel/Net/RTL8139NetworkAdapter.cpp
@@ -359,7 +359,7 @@ void RTL8139NetworkAdapter::receive()
// we never have to worry about the packet wrapping around the buffer,
// since we set RXCFG_WRAP_INHIBIT, which allows the rtl8139 to write data
- // past the end of the alloted space.
+ // past the end of the allotted space.
memcpy(m_packet_buffer->vaddr().as_ptr(), (const u8*)(start_of_packet + 4), length - 4);
// let the card know that we've read this data
m_rx_buffer_offset = ((m_rx_buffer_offset + length + 4 + 3) & ~3) % RX_BUFFER_SIZE;
diff --git a/Kernel/Process.cpp b/Kernel/Process.cpp
index 2efa041f9c..e427316652 100644
--- a/Kernel/Process.cpp
+++ b/Kernel/Process.cpp
@@ -397,7 +397,7 @@ void signal_trampoline_dummy(void)
// then calls the signal handler. We do this because, when interrupting a
// blocking syscall, that syscall may return some special error code in eax;
// This error code would likely be overwritten by the signal handler, so it's
- // neccessary to preserve it here.
+ // necessary to preserve it here.
asm(
".intel_syntax noprefix\n"
"asm_signal_trampoline:\n"
diff --git a/Kernel/Scheduler.cpp b/Kernel/Scheduler.cpp
index 2a48537b59..c510743b6b 100644
--- a/Kernel/Scheduler.cpp
+++ b/Kernel/Scheduler.cpp
@@ -699,7 +699,7 @@ void Scheduler::enter_current(Thread& prev_thread)
void Scheduler::leave_on_first_switch(u32 flags)
{
- // This is called when a thread is swiched into for the first time.
+ // This is called when a thread is switched into for the first time.
// At this point, enter_current has already be called, but because
// Scheduler::context_switch is not in the call stack we need to
// clean up and release locks manually here
diff --git a/Kernel/Syscalls/execve.cpp b/Kernel/Syscalls/execve.cpp
index e398259238..cb2562b1b7 100644
--- a/Kernel/Syscalls/execve.cpp
+++ b/Kernel/Syscalls/execve.cpp
@@ -104,8 +104,8 @@ int Process::do_exec(NonnullRefPtr<FileDescription> main_program_description, Ve
InodeMetadata loader_metadata;
// FIXME: Hoooo boy this is a hack if I ever saw one.
- // This is the 'random' offset we're giving to our ET_DYN exectuables to start as.
- // It also happens to be the static Virtual Addresss offset every static exectuable gets :)
+ // This is the 'random' offset we're giving to our ET_DYN executables to start as.
+ // It also happens to be the static Virtual Address offset every static executable gets :)
// Without this, some assumptions by the ELF loading hooks below are severely broken.
// 0x08000000 is a verified random number chosen by random dice roll https://xkcd.com/221/
m_load_offset = interpreter_description ? 0x08000000 : 0;
@@ -113,7 +113,7 @@ int Process::do_exec(NonnullRefPtr<FileDescription> main_program_description, Ve
// FIXME: We should be able to load both the PT_INTERP interpreter and the main program... once the RTLD is smart enough
if (interpreter_description) {
loader_metadata = interpreter_description->metadata();
- // we don't need the interpreter file desciption after we've loaded (or not) it into memory
+ // we don't need the interpreter file description after we've loaded (or not) it into memory
interpreter_description = nullptr;
} else {
loader_metadata = main_program_description->metadata();
@@ -176,10 +176,10 @@ int Process::do_exec(NonnullRefPtr<FileDescription> main_program_description, Ve
// FIXME: Move TLS region allocation to userspace: LibC and the dynamic loader.
// LibC if we end up with a statically linked executable, and the
- // dynamic loader so that it can create new TLS blocks for each shared libarary
+ // dynamic loader so that it can create new TLS blocks for each shared library
// that gets loaded as part of DT_NEEDED processing, and via dlopen()
// If that doesn't happen quickly, at least pass the location of the TLS region
- // some ELF Auxilliary Vector so the loader can use it/create new ones as necessary.
+ // some ELF Auxiliary Vector so the loader can use it/create new ones as necessary.
loader->tls_section_hook = [&](size_t size, size_t alignment) {
ASSERT(size);
master_tls_region = allocate_region({}, size, String(), PROT_READ | PROT_WRITE);
@@ -195,7 +195,7 @@ int Process::do_exec(NonnullRefPtr<FileDescription> main_program_description, Ve
}
// FIXME: Validate that this virtual address is within executable region,
// instead of just non-null. You could totally have a DSO with entry point of
- // the beginning of the text segement.
+ // the beginning of the text segment.
if (!loader->entry().offset(m_load_offset).get()) {
klog() << "do_exec: Failure loading " << path.characters() << ", entry pointer is invalid! (" << loader->entry().offset(m_load_offset) << ")";
return -ENOEXEC;
diff --git a/Kernel/TTY/TTY.cpp b/Kernel/TTY/TTY.cpp
index 3130b3cceb..7e9d8aefcf 100644
--- a/Kernel/TTY/TTY.cpp
+++ b/Kernel/TTY/TTY.cpp
@@ -55,7 +55,7 @@ void TTY::set_default_termios()
KResultOr<size_t> TTY::read(FileDescription&, size_t, UserOrKernelBuffer& buffer, size_t size)
{
if (Process::current()->pgid() != pgid()) {
- // FIXME: Should we propigate this error path somehow?
+ // FIXME: Should we propagate this error path somehow?
(void)Process::current()->send_signal(SIGTTIN, nullptr);
return KResult(-EINTR);
}
@@ -203,8 +203,8 @@ void TTY::emit(u8 ch)
bool TTY::can_do_backspace() const
{
- //can't do back space if we're empty. Plus, we don't want to
- //removing any lines "commited" by newlines or ^D.
+ // can't do back space if we're empty. Plus, we don't want to
+ // remove any lines "committed" by newlines or ^D.
if (!m_input_buffer.is_empty() && !is_eol(m_input_buffer.last()) && m_input_buffer.last() != '\0') {
return true;
}
diff --git a/Kernel/Thread.cpp b/Kernel/Thread.cpp
index 43ebc169ce..6347a7a9ae 100644
--- a/Kernel/Thread.cpp
+++ b/Kernel/Thread.cpp
@@ -231,7 +231,7 @@ void Thread::relock_process(bool did_unlock)
process().big_lock().lock();
}
- // NOTE: We may be on a differenct CPU now!
+ // NOTE: We may be on a different CPU now!
Processor::current().restore_critical(prev_crit, prev_flags);
}
diff --git a/Kernel/Time/RTC.cpp b/Kernel/Time/RTC.cpp
index 726c437a64..a34cfc9f54 100644
--- a/Kernel/Time/RTC.cpp
+++ b/Kernel/Time/RTC.cpp
@@ -65,7 +65,7 @@ void RealTimeClock::reset_to_default_ticks_per_second()
ASSERT(success);
}
-// FIXME: This is a quick & dirty log base 2 with a paramater. Please provide something better in the future.
+// FIXME: This is a quick & dirty log base 2 with a parameter. Please provide something better in the future.
static int quick_log2(size_t number)
{
int count = 0;