1
0
linux/debian/patches/mixed-arch/0002-ZEN-Fixup-graysky-s-more-ISA-levels-and-uarches.patch
2024-11-22 20:01:53 +03:00

61 lines
2.2 KiB
Diff

From 44295ad130b8735cecb288dd7463a14892803d9b Mon Sep 17 00:00:00 2001
From: "Jan Alexander Steffens (heftig)" <heftig@archlinux.org>
Date: Tue, 1 Oct 2024 02:05:12 +0200
Subject: ZEN: Fixup graysky's more-ISA-levels-and-uarches
See: https://github.com/graysky2/kernel_compiler_patch/issues/105
---
arch/x86/Kconfig.cpu | 4 ----
arch/x86/Makefile | 4 ----
arch/x86/include/asm/vermagic.h | 6 ++++++
3 files changed, 6 insertions(+), 8 deletions(-)
--- a/arch/x86/Kconfig.cpu
+++ b/arch/x86/Kconfig.cpu
@@ -603,10 +603,6 @@ config MNATIVE_AMD
endchoice
-config SUPPORT_MARCH_CODEVERS
- bool
- default y if (CC_IS_GCC && GCC_VERSION > 110000) || (CC_IS_CLANG && CLANG_VERSION >= 120000)
-
config X86_GENERIC
bool "Generic x86 support"
depends on X86_32
--- a/arch/x86/Makefile
+++ b/arch/x86/Makefile
@@ -177,8 +177,6 @@ else
# FIXME - should be integrated in Makefile.cpu (Makefile_32.cpu)
cflags-$(CONFIG_MK8) += -march=k8
cflags-$(CONFIG_MPSC) += -march=nocona
- cflags-$(CONFIG_MCORE2) += -march=core2
- cflags-$(CONFIG_MATOM) += -march=atom
ifeq ($(CONFIG_X86_64_VERSION),1)
cflags-$(CONFIG_GENERIC_CPU) += -mtune=generic
rustflags-$(CONFIG_GENERIC_CPU) += -Ztune-cpu=generic
@@ -230,8 +228,6 @@ else
rustflags-$(CONFIG_MK8) += -Ctarget-cpu=k8
rustflags-$(CONFIG_MPSC) += -Ctarget-cpu=nocona
- rustflags-$(CONFIG_MCORE2) += -Ctarget-cpu=core2
- rustflags-$(CONFIG_MATOM) += -Ctarget-cpu=atom
rustflags-$(CONFIG_MK8SSE3) += -Ctarget-cpu=k8-sse3
rustflags-$(CONFIG_MK10) += -Ctarget-cpu=amdfam10
rustflags-$(CONFIG_MBARCELONA) += -Ctarget-cpu=barcelona
--- a/arch/x86/include/asm/vermagic.h
+++ b/arch/x86/include/asm/vermagic.h
@@ -105,6 +105,12 @@
#define MODULE_PROC_FAMILY "ZEN "
#elif defined CONFIG_MZEN2
#define MODULE_PROC_FAMILY "ZEN2 "
+#elif defined CONFIG_MZEN3
+#define MODULE_PROC_FAMILY "ZEN3 "
+#elif defined CONFIG_MZEN4
+#define MODULE_PROC_FAMILY "ZEN4 "
+#elif defined CONFIG_MZEN5
+#define MODULE_PROC_FAMILY "ZEN5 "
#elif defined CONFIG_MELAN
#define MODULE_PROC_FAMILY "ELAN "
#elif defined CONFIG_MCRUSOE