Age | Commit message (Collapse) | Author |
|
|
|
Remove the duplicate/extraneous access specifier.
|
|
A request of `GET_DESCRIPTOR` should be sending the entire configuration
chain, and not just the configuration descriptor.
|
|
This creates all interfaces when the device is enumerated, with a link
to the configuration that it is a part of. As such, a new class,
`USBInterface` has been introduced to express this state.
|
|
|
|
Some other parts of the USB stack may require us to perform a control
transfer. Instead of abusing `friend` to expose the default pipe, let's
just expose it via a function.
|
|
This also introduces a new class, `USBConfiguration` that stores a
configuration. The device, when instructed, sets this configuration and
holds a pointer to it so we have a record of what configuration is
currently active.
|
|
Previously, we required local socket addresses to be exactly
sizeof(sockaddr_un). There was no real reason for this, so let's not
enforce it.
|
|
Previously we just wrote the local socket bind path into the sockaddr_un
buffer. With this patch, we actually report the family as well.
|
|
AnonymousFile always allocates in multiples of a page size when created
with anon_create. This is especially an issue if we use AnonymousFile
shared memory to store a shared data structure that isn't exactly a
multiple of a page in size. Therefore, we can just allow mmaps of
AnonymousFile to map only an initial part of the shared memory.
This makes SharedSingleProducerCircularQueue work when it's introduced
later.
|
|
|
|
|
|
In most cases it's safe to abort the requested operation and go forward,
however, in some places it's not clear yet how to handle these failures,
therefore, we use the MUST() wrapper to force a kernel panic for now.
|
|
|
|
On the QEMU microvm machine type, it became apparent that the BIOS was
not setting the i8042 controller to function as expected. To ensure that
the controller is always outputting correct scan codes, set it to scan
code 2 and enable first port translation to ensure all scan codes are
translated to scan code set 1. This is the expected behavior when using
SeaBIOS, but on qboot (the BIOS for the QEMU microvm machine type), the
firmware doesn't take care of this so we need to do this ourselves.
|
|
This makes the main thread stack size the same as the default stack
size when creating new threads.
|
|
This keeps us from accidentally overwriting an already set region name,
for example when we are mapping a file (as, in this case, the file name
is already stored in the region).
|
|
Since KASLR was added kernel_load_base only signifies the address at
which the kernel image start, not the start of kernel memory, meaning
that a valid kernel stack can be allocated before it in memory.
We use kernel_mapping_base, the lowest address covered by the kernel
page directory, as the minimal address when performing safety checks
during backtrace generation.
|
|
This syscall doesn't access any unprotected shared data.
|
|
This syscall doesn't access any unprotected shared data.
|
|
This syscall doesn't access any unprotected shared data.
|
|
This syscall doesn't access any unprotected shared data.
|
|
This syscall doesn't access any unprotected shared data.
|
|
This syscall doesn't access any unprotected shared data.
|
|
This syscall doesn't access any unprotected shared data.
|
|
This syscall doesn't access any unprotected shared data.
|
|
This syscall doesn't access any unprotected shared data.
|
|
This syscall doesn't access any unprotected shared data.
|
|
This syscall doesn't access any unprotected shared data.
|
|
This syscall doesn't access any unprotected shared data.
|
|
This syscall doesn't access any unprotected shared data.
|
|
This syscall doesn't access any unprotected shared data.
|
|
This syscall doesn't access any unprotected shared data.
|
|
|
|
This value is always non-null, so let's make it explicit.
|
|
The only requirement for this syscall is to make
Process::m_coredump_properties SpinlockProtected.
|
|
The only thing we needed to check is whether `socket.accept()` returns
a socket, and if not, we go back to blocking again.
|
|
These two methods are big lock specific, so verify our mutex' behavior.
|
|
If the regular exclusive and shared lists were empty (which they
always should be for the big lock), we were not unblocking any waiters.
|
|
For OSPKE this is a no-op as we don't enable PKU yet, but the state of
the OSXSAVE flag might have changed if we enabled XSAVE.
|
|
Unlike "XSAVE enabled by OS" being indicated by the OSXSAVE flag, in
this case it's "PKU enabled by OS" being indicated by the OSPKE flag.
|
|
|
|
When we lock a mutex, eventually `Thread::block` is invoked which could
in turn invoke `Process::big_lock().restore_exclusive_lock()`. This
would then try to add the current thread to a different blocked thread
list then the one in use for the original mutex being locked, and
because it's an intrusive list, the thread is removed from its original
list during the `.append()`. When the original mutex eventually
unblocks, we no longer have the thread in the intrusive blocked threads
list and we panic.
Solve this by making the big lock mutex special and giving it its own
blocked thread list. Because the process big lock is temporary and is
being actively removed from e.g. syscalls, it's a matter of time before
we can also remove the fix introduced by this commit.
Fixes issue #9401.
|
|
|
|
This fixes an issue where File::mmap() overrides would fail because they
were expecting to be called with a size evenly divisible by PAGE_SIZE.
|
|
|
|
If we unregister from the RegionTree before unmapping, there's a race
where a new region can get inserted at the same address that we're about
to unmap. If this happens, ~Region() will then unmap the newly inserted
region, which now finds itself with cleared-out page table entries.
|
|
Let's not have a way to grab at the RegionTree from outside of MM.
|
|
This didn't need to be in RegionTree, and since it's specific to kernel
VM anyway, let's move it to MemoryManager.
|
|
This had no business being in RegionTree, since RegionTree doesn't track
identity-mapped regions anyway. (We allow *any* address to be identity
mapped, not just the ones that are part of the RegionTree's range.)
|