        /*
 * @author  xamidev <xamidev@riseup.net>
 * @brief   Spinlock implementation
 * @license GPL-3.0-only
 */

#ifndef SPINLOCK_H
#define SPINLOCK_H

#include <stdbool.h>
#include <stdint.h>

struct spinlock
{
    bool locked;
    uint64_t rflags;
};

void spinlock_acquire(struct spinlock* lock);
void spinlock_release(struct spinlock* lock);

#endif