[PATCH] um: borrow bitops from the x86 tree
anton.ivanov at cambridgegreys.com
anton.ivanov at cambridgegreys.com
Mon Nov 16 09:44:26 EST 2020
From: Anton Ivanov <anton.ivanov at cambridgegreys.com>
Using x86 bitops instead of the asm-generic allows to squeeze
a couple of percents improvement on fs IO in UML. It should
improve other areas as well.
Signed-off-by: Anton Ivanov <anton.ivanov at cambridgegreys.com>
---
arch/um/include/asm/bitops-x86.h | 1 +
arch/um/include/asm/bitops.h | 20 ++++++++++++++++++++
2 files changed, 21 insertions(+)
create mode 120000 arch/um/include/asm/bitops-x86.h
create mode 100644 arch/um/include/asm/bitops.h
diff --git a/arch/um/include/asm/bitops-x86.h b/arch/um/include/asm/bitops-x86.h
new file mode 120000
index 000000000000..15a96ff554b2
--- /dev/null
+++ b/arch/um/include/asm/bitops-x86.h
@@ -0,0 +1 @@
+../../../x86/include/asm/bitops.h
\ No newline at end of file
diff --git a/arch/um/include/asm/bitops.h b/arch/um/include/asm/bitops.h
new file mode 100644
index 000000000000..e578c628a6d5
--- /dev/null
+++ b/arch/um/include/asm/bitops.h
@@ -0,0 +1,20 @@
+/* SPDX-License-Identifier: GPL-2.0 */
+#ifndef _ASM_UM_BITOPS_H
+#define _ASM_UM_BITOPS_H
+
+#ifdef CONFIG_64BIT
+
+#undef CONFIG_X86_32
+
+#ifndef CONFIG_X86_64
+#define CONFIG_X86_64
+#endif
+
+#else
+#define CONFIG_X86_32
+#endif
+
+#include <asm/bitops-x86.h>
+
+
+#endif
--
2.20.1
More information about the linux-um
mailing list