aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/sync_core.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/sync_core.h')
-rw-r--r--include/linux/sync_core.h16
1 files changed, 15 insertions, 1 deletions
diff --git a/include/linux/sync_core.h b/include/linux/sync_core.h
index 013da4b8b3272c..67bb9794b87585 100644
--- a/include/linux/sync_core.h
+++ b/include/linux/sync_core.h
@@ -17,5 +17,19 @@ static inline void sync_core_before_usermode(void)
}
#endif
-#endif /* _LINUX_SYNC_CORE_H */
+#ifdef CONFIG_ARCH_HAS_PREPARE_SYNC_CORE_CMD
+#include <asm/sync_core.h>
+#else
+/*
+ * This is a dummy prepare_sync_core_cmd() implementation that can be used on
+ * all architectures which provide unconditional core serializing instructions
+ * in switch_mm().
+ * If your architecture doesn't provide such core serializing instructions in
+ * switch_mm(), you may need to write your own functions.
+ */
+static inline void prepare_sync_core_cmd(struct mm_struct *mm)
+{
+}
+#endif
+#endif /* _LINUX_SYNC_CORE_H */