summaryrefslogtreecommitdiff
path: root/Kernel/WorkQueue.cpp
AgeCommit message (Collapse)Author
2022-08-20Kernel: Make self-contained locking smart pointers their own classesAndreas Kling
Until now, our kernel has reimplemented a number of AK classes to provide automatic internal locking: - RefPtr - NonnullRefPtr - WeakPtr - Weakable This patch renames the Kernel classes so that they can coexist with the original AK classes: - RefPtr => LockRefPtr - NonnullRefPtr => NonnullLockRefPtr - WeakPtr => LockWeakPtr - Weakable => LockWeakable The goal here is to eventually get rid of the Lock* classes in favor of using external locking.
2022-07-19Kernel/Storage: Introduce basic abstraction layer for ATA componentsLiav A
This abstraction layer is mainly for ATA ports (AHCI ports, IDE ports). The goal is to create a convenient and flexible framework so it's possible to expand to support other types of controller (e.g. Intel PIIX and ICH IDE controllers) and to abstract operations that are possible on each component. Currently only the ATA IDE code is affected by this, making it much cleaner and readable - the ATA bus mastering code is moved to the ATAPort code so more implementations in the near future can take advantage of such functionality easily. In addition to that, the hierarchy of the ATA IDE code resembles more of the SATA AHCI code now, which means the IDEChannel class is solely responsible for getting interrupts, passing them for further processing in the ATAPort code to take care of the rest of the handling logic.
2022-07-12Everywhere: Add sv suffix to strings relying on StringView(char const*)sin-ack
Each of these strings would previously rely on StringView's char const* constructor overload, which would call __builtin_strlen on the string. Since we now have operator ""sv, we can replace these with much simpler versions. This opens the door to being able to remove StringView(char const*). No functional changes.
2022-06-05Kernel: Unify Kernel task names for consistencyBrian Gianforcaro
This change unifies the naming convention for kernel tasks. The goal of this change is to: - Make the task names more descriptive, so users can more easily understand their purpose in System Monitor. - Unify the naming convention so they are consistent.
2022-04-20Kernel: Take WorkQueue item as reference instead of pointer in do_queueLiav A
2021-12-05Kernel: Mark kernel smart-pointer classes as [[nodiscard]]Sam Atkins
And cast the unused return values to void.
2021-10-26Kernel: Use SpinlockProtected<T> in WorkQueueAndreas Kling
2021-09-07Kernel: Store process names as KStringAndreas Kling
2021-08-22Kernel: Rename ScopedSpinlock => SpinlockLockerAndreas Kling
This matches MutexLocker, and doesn't sound like it's a lock itself.
2021-08-22Kernel: Rename SpinLock => SpinlockAndreas Kling
2021-08-07Kernel: Move SpinLock.h into Locking/Jean-Baptiste Boric
2021-06-24Kernel: Move special sections into Sections.hHendiadyoin1
This also removes a lot of CPU.h includes infavor for Sections.h
2021-06-09Kernel: Mark WorkQueue initailzation functions as UNMAP_AFTER_INITBrian Gianforcaro
2021-05-19Kernel: Use plain Function objects for the WorkQueueGunnar Beutner
The WorkQueue class previously had its own inline storage functionality for function pointers. With the recent changes to the Function class this is no longer necessary.
2021-04-29Everywhere: Use "the SerenityOS developers." in copyright headersLinus Groh
We had some inconsistencies before: - Sometimes "The", sometimes "the" - Sometimes trailing ".", sometimes no trailing "." I picked the most common one (lowecase "the", trailing ".") and applied it to all copyright headers. By using the exact same string everywhere we can ensure nothing gets missed during a global search (and replace), and that these inconsistencies are not spread any further (as copyright headers are commonly copied to new files).
2021-04-22Everything: Move to SPDX license identifiers in all files.Brian Gianforcaro
SPDX License Identifiers are a more compact / standardized way of representing file license information. See: https://spdx.dev/resources/use/#identifiers This was done with the `ambr` search and replace tool. ambr --no-parent-ignore --key-from-file --rep-from-file key.txt rep.txt *
2021-03-26Kernel: Remove unused WorkQueue::m_name.Michel Hermier
2021-03-21Kernel: Add simplistic work queuesTom
We can't use deferred functions for anything that may require preemption, such as copying from/to user or accessing the disk. For those purposes we should use a work queue, which is essentially a kernel thread that may be preempted or blocked.