sandbox: Add generic asm/atomic.h

In order to compile code that uses <asm/atomic.h> on sandbox, we must
provide this header. RISC-V shows us today how to do so with the generic
header implementation, so copy that.

Signed-off-by: Tom Rini <trini@konsulko.com>
This commit is contained in:
Tom Rini
2025-08-19 11:25:28 -06:00
parent 58998fed9e
commit 66ff673a8e
+15
View File
@@ -0,0 +1,15 @@
/* SPDX-License-Identifier: GPL-2.0+ */
/*
* Based on arch/riscv/include/asm/atomic.h which is:
* Copyright 2023 SiFive, Inc.
*/
#ifndef __SANDBOX_ATOMIC_H
#define __SANDBOX_ATOMIC_H
/* use the generic asm/atomic.h until we define a better one */
#include <asm/system.h>
#include <asm-generic/atomic.h>
#endif