Files
horinux/kernel/horizon_futex.c
Kent Hall 4754f8d812 Horizon patch 0.1
Able to run some homebrew stuff, and also the first commercial game,
Puyo Puyo Tetris
2022-09-02 00:18:24 -04:00

28 lines
582 B
C

// SPDX-License-Identifier: GPL-2.0
/*
* Copyright (C) 2022
* Kent Hall <kjh2166@columbia.edu>
*/
#include <uapi/linux/futex.h>
#include <linux/sched.h>
#define HANDLE_WAIT_MASK ((u32)(1u << 30))
#undef FUTEX_WAITERS
#define FUTEX_WAITERS HANDLE_WAIT_MASK
#undef FUTEX_OWNER_DIED
#define FUTEX_OWNER_DIED 0
#undef FUTEX_TID_MASK
#define FUTEX_TID_MASK (0xFFFFFFFF - HANDLE_WAIT_MASK)
#define futex_exit_recursive horizon_futex_exit_recursive
#define futex_exit_release horizon_futex_exit_release
#define do_futex do_horizon_futex
#define HORIZON_FUTEX
#include "futex.c"