[1/3] x86/cpu/zhaoxin: Introduce macros for Zhaoxin family numbers

Message ID 20230323024026.823-2-silviazhao-oc@zhaoxin.com
State New
Headers
Series Add PMC support for Zhaoxin Yongfeng architecture |

Commit Message

silviazhao March 23, 2023, 2:40 a.m. UTC
  Create zhaoxin-family.h to define Zhaoxin family numbers in one header
file. So we can use the macros instead of open-coded model numbers in
other files.

Signed-off-by: silviazhao <silviazhao-oc@zhaoxin.com>
---
 arch/x86/include/asm/zhaoxin-family.h | 19 +++++++++++++++++++
 1 file changed, 19 insertions(+)
 create mode 100644 arch/x86/include/asm/zhaoxin-family.h
  

Patch

diff --git a/arch/x86/include/asm/zhaoxin-family.h b/arch/x86/include/asm/zhaoxin-family.h
new file mode 100644
index 000000000000..d54e0112207a
--- /dev/null
+++ b/arch/x86/include/asm/zhaoxin-family.h
@@ -0,0 +1,19 @@ 
+/* SPDX-License-Identifier: GPL-2.0 */
+#ifndef _ASM_X86_ZHAOXIN_FAMILY_H
+#define _ASM_X86_ZHAOXIN_FAMILY_H
+
+/*
+ * The defined symbol names have the following form:
+ *             ZHAOXIN_FAM7{OPTFAMILY}_{MICROARCH}
+ * where:
+ * OPTFAMILY   Describes the family of CPUs that this belongs to. Default
+ *             is assumed to be omitted.
+ * MICROARCH   Is the code name for the micro-architecture for this core.
+ */
+
+
+#define ZHAOXIN_FAM7_WUDAOKOU		0x1B
+#define ZHAOXIN_FAM7_LUJIAZUI		0x3B
+#define ZHAOXIN_FAM7_YONGFENG		0x5B
+
+#endif /* _ASM_X86_ZHAOXIN_FAMILY_H */