fix make for a21, PIDs are always ints, linter things

This commit is contained in:
Niklas Gollenstede
2026-01-05 10:41:27 +01:00
parent 7ae806fa01
commit 598f97cd78
16 changed files with 155 additions and 104 deletions

View File

@@ -28,14 +28,12 @@ class Thread {
/*! \brief pointer to the next element of the readylist
*/
Thread* queue_link;
friend class Queue<Thread>;
friend class Semaphore;
/*! \brief Memory reserved for this threads stack
*/
alignas(16) char reserved_stack_space[STACK_SIZE];
protected:
/*! \brief Context of the thread, used for saving and restoring the register
* values when context switching.
*/
@@ -56,17 +54,25 @@ class Thread {
* \param param1 Thread to be started
* \param param2 Second parameter (will be used later)
* \param param3 Third parameter (will be used later)
*
*/
static void kickoff(uintptr_t param1, uintptr_t param2, uintptr_t param3);
public:
/*! \brief Unique thread id */
const size_t id;
const int id;
/*! \brief Marker for a dying thread
*/
volatile bool kill_flag;
// Naively moving or copying esp. the (user) stack of a thread would be a
// bad idea:
Thread(const Thread&) = delete;
Thread(Thread&&) = delete;
Thread& operator=(const Thread&) = delete;
Thread& operator=(Thread&&) = delete;
/*! \brief Constructor
* Initializes the context using \ref prepareContext with the thread's
* stack space.