summaryrefslogtreecommitdiff
path: root/include/linux/cache.h
diff options
context:
space:
mode:
authorKent Overstreet <kent.overstreet@linux.dev>2024-01-16 17:00:02 -0500
committerKent Overstreet <kent.overstreet@linux.dev>2024-01-16 17:17:23 -0500
commitb5fd066153c40a70a29caa1ea7987723ab687763 (patch)
tree6d43a8b0a90d549a54c65565ac96c92b3e84b594 /include/linux/cache.h
parent06ff8b55b70fda44d91b31b5511fafd1680a8934 (diff)
Move c_src dirs back to toplevel
We just wanted c sourcefiles out of the top level, not c source directories. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'include/linux/cache.h')
-rw-r--r--include/linux/cache.h17
1 files changed, 17 insertions, 0 deletions
diff --git a/include/linux/cache.h b/include/linux/cache.h
new file mode 100644
index 00000000..c61167ca
--- /dev/null
+++ b/include/linux/cache.h
@@ -0,0 +1,17 @@
+#ifndef __TOOLS_LINUX_CACHE_H
+#define __TOOLS_LINUX_CACHE_H
+
+#define L1_CACHE_SHIFT 6
+#define L1_CACHE_BYTES (1 << L1_CACHE_SHIFT)
+#define SMP_CACHE_BYTES L1_CACHE_BYTES
+
+#define L1_CACHE_ALIGN(x) __ALIGN_KERNEL(x, L1_CACHE_BYTES)
+
+#define __read_mostly
+#define __ro_after_init
+
+#define ____cacheline_aligned __attribute__((__aligned__(SMP_CACHE_BYTES)))
+#define ____cacheline_aligned_in_smp ____cacheline_aligned
+
+#endif /* __TOOLS_LINUX_CACHE_H */
+