Gentoo Archives: gentoo-commits

From: Mike Pagano <mpagano@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/linux-patches:5.11 commit in: /
Date: Fri, 30 Apr 2021 18:56:46
Message-Id: 1619808928.e35d7e29276d65f656f7cbbb54bc5957e250439d.mpagano@gentoo
1 commit: e35d7e29276d65f656f7cbbb54bc5957e250439d
2 Author: Mike Pagano <mpagano <AT> gentoo <DOT> org>
3 AuthorDate: Fri Apr 30 18:55:28 2021 +0000
4 Commit: Mike Pagano <mpagano <AT> gentoo <DOT> org>
5 CommitDate: Fri Apr 30 18:55:28 2021 +0000
6 URL: https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=e35d7e29
7
8 Rename cpu opt patch to standardize on naming format.
9
10 Remove redundant split patches
11
12 Signed-off-by: Mike Pagano <mpagano <AT> gentoo.org>
13
14 0000_README | 8 +-
15 ...> 5010_enable-cpu-optimizations-universal.patch | 0
16 5012_enable-cpu-optimizations-for-gcc91.patch | 549 ---------------------
17 3 files changed, 2 insertions(+), 555 deletions(-)
18
19 diff --git a/0000_README b/0000_README
20 index c4f4eb4..cd9328d 100644
21 --- a/0000_README
22 +++ b/0000_README
23 @@ -131,13 +131,9 @@ Patch: 4567_distro-Gentoo-Kconfig.patch
24 From: Tom Wijsman <TomWij@g.o>
25 Desc: Add Gentoo Linux support config settings and defaults.
26
27 -Patch: 5012_enable-cpu-optimizations-for-gcc91.patch
28 +Patch: 5010_enable-cpu-optimizations-universal.patch
29 From: https://github.com/graysky2/kernel_gcc_patch/
30 -Desc: Kernel patch enables gcc >= v9.1 optimizations for additional CPUs.
31 -
32 -Patch: 5013_enable-cpu-optimizations-for-gcc10.patch
33 -From: https://github.com/graysky2/kernel_gcc_patch/
34 -Desc: Kernel patch enables gcc = v10.1+ optimizations for additional CPUs.
35 +Desc: Kernel >= 5.8 patch enables gcc = v9+ optimizations for additional CPUs.
36
37 Patch: 5020_BMQ-and-PDS-io-scheduler-v5.11-r3.patch
38 From: https://gitlab.com/alfredchen/linux-prjc
39
40 diff --git a/5013_enable-cpu-optimizations-for-gcc10.patch b/5010_enable-cpu-optimizations-universal.patch
41 similarity index 100%
42 rename from 5013_enable-cpu-optimizations-for-gcc10.patch
43 rename to 5010_enable-cpu-optimizations-universal.patch
44
45 diff --git a/5012_enable-cpu-optimizations-for-gcc91.patch b/5012_enable-cpu-optimizations-for-gcc91.patch
46 deleted file mode 100644
47 index 56aff7e..0000000
48 --- a/5012_enable-cpu-optimizations-for-gcc91.patch
49 +++ /dev/null
50 @@ -1,549 +0,0 @@
51 -From 56af79dc8be395c6adf25a05de3566822dbb2947 Mon Sep 17 00:00:00 2001
52 -From: graysky <graysky@×××××××××.us>
53 -Date: Tue, 9 Mar 2021 01:57:33 -0500
54 -Subject: [PATCH] more-uarches-for-gcc-v9-and-kernel-5.8+
55 -
56 -WARNING
57 -This patch works with gcc versions 9.1+ and with kernel version 5.8+ and should
58 -NOT be applied when compiling on older versions of gcc due to key name changes
59 -of the march flags introduced with the version 4.9 release of gcc.[1]
60 -
61 -Use the older version of this patch hosted on the same github for older
62 -versions of gcc.
63 -
64 -FEATURES
65 -This patch adds additional CPU options to the Linux kernel accessible under:
66 - Processor type and features --->
67 - Processor family --->
68 -
69 -The expanded microarchitectures include:
70 -* AMD Improved K8-family
71 -* AMD K10-family
72 -* AMD Family 10h (Barcelona)
73 -* AMD Family 14h (Bobcat)
74 -* AMD Family 16h (Jaguar)
75 -* AMD Family 15h (Bulldozer)
76 -* AMD Family 15h (Piledriver)
77 -* AMD Family 15h (Steamroller)
78 -* AMD Family 15h (Excavator)
79 -* AMD Family 17h (Zen)
80 -* AMD Family 17h (Zen 2)
81 -* Intel Silvermont low-power processors
82 -* Intel Goldmont low-power processors (Apollo Lake and Denverton)
83 -* Intel Goldmont Plus low-power processors (Gemini Lake)
84 -* Intel 1st Gen Core i3/i5/i7 (Nehalem)
85 -* Intel 1.5 Gen Core i3/i5/i7 (Westmere)
86 -* Intel 2nd Gen Core i3/i5/i7 (Sandybridge)
87 -* Intel 3rd Gen Core i3/i5/i7 (Ivybridge)
88 -* Intel 4th Gen Core i3/i5/i7 (Haswell)
89 -* Intel 5th Gen Core i3/i5/i7 (Broadwell)
90 -* Intel 6th Gen Core i3/i5/i7 (Skylake)
91 -* Intel 6th Gen Core i7/i9 (Skylake X)
92 -* Intel 8th Gen Core i3/i5/i7 (Cannon Lake)
93 -* Intel 10th Gen Core i7/i9 (Ice Lake)
94 -* Intel Xeon (Cascade Lake)
95 -
96 -It also offers to compile passing the 'native' option which, "selects the CPU
97 -to generate code for at compilation time by determining the processor type of
98 -the compiling machine. Using -march=native enables all instruction subsets
99 -supported by the local machine and will produce code optimized for the local
100 -machine under the constraints of the selected instruction set."[2]
101 -
102 -Do NOT try using the 'native' option on AMD Piledriver, Steamroller, or
103 -Excavator CPUs (-march=bdver{2,3,4} flag). The build will error out due the
104 -kernel's objtool issue with these.[3a,b]
105 -
106 -MINOR NOTES
107 -This patch also changes 'atom' to 'bonnell' in accordance with the gcc v4.9
108 -changes. Note that upstream is using the deprecated 'match=atom' flags when I
109 -believe it should use the newer 'march=bonnell' flag for atom processors.[4]
110 -
111 -It is not recommended to compile on Atom-CPUs with the 'native' option.[5] The
112 -recommendation is to use the 'atom' option instead.
113 -
114 -BENEFITS
115 -Small but real speed increases are measurable using a make endpoint comparing
116 -a generic kernel to one built with one of the respective microarchs.
117 -
118 -See the following experimental evidence supporting this statement:
119 -https://github.com/graysky2/kernel_gcc_patch
120 -
121 -REQUIREMENTS
122 -linux version >=5.8
123 -gcc version >=9.1 and <10
124 -
125 -ACKNOWLEDGMENTS
126 -This patch builds on the seminal work by Jeroen.[6]
127 -
128 -REFERENCES
129 -1. https://gcc.gnu.org/gcc-4.9/changes.html
130 -2. https://gcc.gnu.org/onlinedocs/gcc/x86-Options.html
131 -3a. https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95671#c11
132 -3b. https://github.com/graysky2/kernel_gcc_patch/issues/55
133 -4. https://bugzilla.kernel.org/show_bug.cgi?id=77461
134 -5. https://github.com/graysky2/kernel_gcc_patch/issues/15
135 -6. http://www.linuxforge.net/docs/linux/linux-gcc.php
136 ----
137 - arch/x86/Kconfig.cpu | 240 ++++++++++++++++++++++++++++++--
138 - arch/x86/Makefile | 37 ++++-
139 - arch/x86/include/asm/vermagic.h | 52 +++++++
140 - 3 files changed, 312 insertions(+), 17 deletions(-)
141 -
142 -diff --git a/arch/x86/Kconfig.cpu b/arch/x86/Kconfig.cpu
143 -index 814fe0d349b0..aa7dd036e8a3 100644
144 ---- a/arch/x86/Kconfig.cpu
145 -+++ b/arch/x86/Kconfig.cpu
146 -@@ -157,7 +157,7 @@ config MPENTIUM4
147 -
148 -
149 - config MK6
150 -- bool "K6/K6-II/K6-III"
151 -+ bool "AMD K6/K6-II/K6-III"
152 - depends on X86_32
153 - help
154 - Select this for an AMD K6-family processor. Enables use of
155 -@@ -165,7 +165,7 @@ config MK6
156 - flags to GCC.
157 -
158 - config MK7
159 -- bool "Athlon/Duron/K7"
160 -+ bool "AMD Athlon/Duron/K7"
161 - depends on X86_32
162 - help
163 - Select this for an AMD Athlon K7-family processor. Enables use of
164 -@@ -173,12 +173,90 @@ config MK7
165 - flags to GCC.
166 -
167 - config MK8
168 -- bool "Opteron/Athlon64/Hammer/K8"
169 -+ bool "AMD Opteron/Athlon64/Hammer/K8"
170 - help
171 - Select this for an AMD Opteron or Athlon64 Hammer-family processor.
172 - Enables use of some extended instructions, and passes appropriate
173 - optimization flags to GCC.
174 -
175 -+config MK8SSE3
176 -+ bool "AMD Opteron/Athlon64/Hammer/K8 with SSE3"
177 -+ help
178 -+ Select this for improved AMD Opteron or Athlon64 Hammer-family processors.
179 -+ Enables use of some extended instructions, and passes appropriate
180 -+ optimization flags to GCC.
181 -+
182 -+config MK10
183 -+ bool "AMD 61xx/7x50/PhenomX3/X4/II/K10"
184 -+ help
185 -+ Select this for an AMD 61xx Eight-Core Magny-Cours, Athlon X2 7x50,
186 -+ Phenom X3/X4/II, Athlon II X2/X3/X4, or Turion II-family processor.
187 -+ Enables use of some extended instructions, and passes appropriate
188 -+ optimization flags to GCC.
189 -+
190 -+config MBARCELONA
191 -+ bool "AMD Barcelona"
192 -+ help
193 -+ Select this for AMD Family 10h Barcelona processors.
194 -+
195 -+ Enables -march=barcelona
196 -+
197 -+config MBOBCAT
198 -+ bool "AMD Bobcat"
199 -+ help
200 -+ Select this for AMD Family 14h Bobcat processors.
201 -+
202 -+ Enables -march=btver1
203 -+
204 -+config MJAGUAR
205 -+ bool "AMD Jaguar"
206 -+ help
207 -+ Select this for AMD Family 16h Jaguar processors.
208 -+
209 -+ Enables -march=btver2
210 -+
211 -+config MBULLDOZER
212 -+ bool "AMD Bulldozer"
213 -+ help
214 -+ Select this for AMD Family 15h Bulldozer processors.
215 -+
216 -+ Enables -march=bdver1
217 -+
218 -+config MPILEDRIVER
219 -+ bool "AMD Piledriver"
220 -+ help
221 -+ Select this for AMD Family 15h Piledriver processors.
222 -+
223 -+ Enables -march=bdver2
224 -+
225 -+config MSTEAMROLLER
226 -+ bool "AMD Steamroller"
227 -+ help
228 -+ Select this for AMD Family 15h Steamroller processors.
229 -+
230 -+ Enables -march=bdver3
231 -+
232 -+config MEXCAVATOR
233 -+ bool "AMD Excavator"
234 -+ help
235 -+ Select this for AMD Family 15h Excavator processors.
236 -+
237 -+ Enables -march=bdver4
238 -+
239 -+config MZEN
240 -+ bool "AMD Zen"
241 -+ help
242 -+ Select this for AMD Family 17h Zen processors.
243 -+
244 -+ Enables -march=znver1
245 -+
246 -+config MZEN2
247 -+ bool "AMD Zen 2"
248 -+ help
249 -+ Select this for AMD Family 17h Zen 2 processors.
250 -+
251 -+ Enables -march=znver2
252 -+
253 - config MCRUSOE
254 - bool "Crusoe"
255 - depends on X86_32
256 -@@ -270,7 +348,7 @@ config MPSC
257 - in /proc/cpuinfo. Family 15 is an older Xeon, Family 6 a newer one.
258 -
259 - config MCORE2
260 -- bool "Core 2/newer Xeon"
261 -+ bool "Intel Core 2"
262 - help
263 -
264 - Select this for Intel Core 2 and newer Core 2 Xeons (Xeon 51xx and
265 -@@ -278,6 +356,8 @@ config MCORE2
266 - family in /proc/cpuinfo. Newer ones have 6 and older ones 15
267 - (not a typo)
268 -
269 -+ Enables -march=core2
270 -+
271 - config MATOM
272 - bool "Intel Atom"
273 - help
274 -@@ -287,6 +367,132 @@ config MATOM
275 - accordingly optimized code. Use a recent GCC with specific Atom
276 - support in order to fully benefit from selecting this option.
277 -
278 -+config MNEHALEM
279 -+ bool "Intel Nehalem"
280 -+ select X86_P6_NOP
281 -+ help
282 -+
283 -+ Select this for 1st Gen Core processors in the Nehalem family.
284 -+
285 -+ Enables -march=nehalem
286 -+
287 -+config MWESTMERE
288 -+ bool "Intel Westmere"
289 -+ select X86_P6_NOP
290 -+ help
291 -+
292 -+ Select this for the Intel Westmere formerly Nehalem-C family.
293 -+
294 -+ Enables -march=westmere
295 -+
296 -+config MSILVERMONT
297 -+ bool "Intel Silvermont"
298 -+ select X86_P6_NOP
299 -+ help
300 -+
301 -+ Select this for the Intel Silvermont platform.
302 -+
303 -+ Enables -march=silvermont
304 -+
305 -+config MGOLDMONT
306 -+ bool "Intel Goldmont"
307 -+ select X86_P6_NOP
308 -+ help
309 -+
310 -+ Select this for the Intel Goldmont platform including Apollo Lake and Denverton.
311 -+
312 -+ Enables -march=goldmont
313 -+
314 -+config MGOLDMONTPLUS
315 -+ bool "Intel Goldmont Plus"
316 -+ select X86_P6_NOP
317 -+ help
318 -+
319 -+ Select this for the Intel Goldmont Plus platform including Gemini Lake.
320 -+
321 -+ Enables -march=goldmont-plus
322 -+
323 -+config MSANDYBRIDGE
324 -+ bool "Intel Sandy Bridge"
325 -+ select X86_P6_NOP
326 -+ help
327 -+
328 -+ Select this for 2nd Gen Core processors in the Sandy Bridge family.
329 -+
330 -+ Enables -march=sandybridge
331 -+
332 -+config MIVYBRIDGE
333 -+ bool "Intel Ivy Bridge"
334 -+ select X86_P6_NOP
335 -+ help
336 -+
337 -+ Select this for 3rd Gen Core processors in the Ivy Bridge family.
338 -+
339 -+ Enables -march=ivybridge
340 -+
341 -+config MHASWELL
342 -+ bool "Intel Haswell"
343 -+ select X86_P6_NOP
344 -+ help
345 -+
346 -+ Select this for 4th Gen Core processors in the Haswell family.
347 -+
348 -+ Enables -march=haswell
349 -+
350 -+config MBROADWELL
351 -+ bool "Intel Broadwell"
352 -+ select X86_P6_NOP
353 -+ help
354 -+
355 -+ Select this for 5th Gen Core processors in the Broadwell family.
356 -+
357 -+ Enables -march=broadwell
358 -+
359 -+config MSKYLAKE
360 -+ bool "Intel Skylake"
361 -+ select X86_P6_NOP
362 -+ help
363 -+
364 -+ Select this for 6th Gen Core processors in the Skylake family.
365 -+
366 -+ Enables -march=skylake
367 -+
368 -+config MSKYLAKEX
369 -+ bool "Intel Skylake X"
370 -+ select X86_P6_NOP
371 -+ help
372 -+
373 -+ Select this for 6th Gen Core processors in the Skylake X family.
374 -+
375 -+ Enables -march=skylake-avx512
376 -+
377 -+config MCANNONLAKE
378 -+ bool "Intel Cannon Lake"
379 -+ select X86_P6_NOP
380 -+ help
381 -+
382 -+ Select this for 8th Gen Core processors
383 -+
384 -+ Enables -march=cannonlake
385 -+
386 -+config MICELAKE
387 -+ bool "Intel Ice Lake"
388 -+ select X86_P6_NOP
389 -+ help
390 -+
391 -+ Select this for 10th Gen Core processors in the Ice Lake family.
392 -+
393 -+ Enables -march=icelake-client
394 -+
395 -+config MCASCADELAKE
396 -+ bool "Intel Cascade Lake"
397 -+ select X86_P6_NOP
398 -+ help
399 -+
400 -+ Select this for Xeon processors in the Cascade Lake family.
401 -+
402 -+ Enables -march=cascadelake
403 -+
404 - config GENERIC_CPU
405 - bool "Generic-x86-64"
406 - depends on X86_64
407 -@@ -294,6 +500,16 @@ config GENERIC_CPU
408 - Generic x86-64 CPU.
409 - Run equally well on all x86-64 CPUs.
410 -
411 -+config MNATIVE
412 -+ bool "Native optimizations autodetected by GCC"
413 -+ help
414 -+
415 -+ GCC 4.2 and above support -march=native, which automatically detects
416 -+ the optimum settings to use based on your processor. Do NOT use this
417 -+ for AMD CPUs. Intel Only!
418 -+
419 -+ Enables -march=native
420 -+
421 - endchoice
422 -
423 - config X86_GENERIC
424 -@@ -318,7 +534,7 @@ config X86_INTERNODE_CACHE_SHIFT
425 - config X86_L1_CACHE_SHIFT
426 - int
427 - default "7" if MPENTIUM4 || MPSC
428 -- default "6" if MK7 || MK8 || MPENTIUMM || MCORE2 || MATOM || MVIAC7 || X86_GENERIC || GENERIC_CPU
429 -+ default "6" if MK7 || MK8 || MPENTIUMM || MCORE2 || MATOM || MVIAC7 || MK8SSE3 || MK10 || MBARCELONA || MBOBCAT || MJAGUAR || MBULLDOZER || MPILEDRIVER || MSTEAMROLLER || MEXCAVATOR || MZEN || MZEN2 || MNEHALEM || MWESTMERE || MSILVERMONT || MGOLDMONT || MGOLDMONTPLUS || MSANDYBRIDGE || MIVYBRIDGE || MHASWELL || MBROADWELL || MSKYLAKE || MSKYLAKEX || MCANNONLAKE || MICELAKE || MCASCADELAKE || MNATIVE || X86_GENERIC || GENERIC_CPU
430 - default "4" if MELAN || M486SX || M486 || MGEODEGX1
431 - default "5" if MWINCHIP3D || MWINCHIPC6 || MCRUSOE || MEFFICEON || MCYRIXIII || MK6 || MPENTIUMIII || MPENTIUMII || M686 || M586MMX || M586TSC || M586 || MVIAC3_2 || MGEODE_LX
432 -
433 -@@ -336,11 +552,11 @@ config X86_ALIGNMENT_16
434 -
435 - config X86_INTEL_USERCOPY
436 - def_bool y
437 -- depends on MPENTIUM4 || MPENTIUMM || MPENTIUMIII || MPENTIUMII || M586MMX || X86_GENERIC || MK8 || MK7 || MEFFICEON || MCORE2
438 -+ depends on MPENTIUM4 || MPENTIUMM || MPENTIUMIII || MPENTIUMII || M586MMX || X86_GENERIC || MK8 || MK7 || MEFFICEON || MCORE2 || MNEHALEM || MWESTMERE || MSILVERMONT || MGOLDMONT || MGOLDMONTPLUS || MSANDYBRIDGE || MIVYBRIDGE || MHASWELL || MBROADWELL || MSKYLAKE || MSKYLAKEX || MCANNONLAKE || MICELAKE || MCASCADELAKE || MNATIVE
439 -
440 - config X86_USE_PPRO_CHECKSUM
441 - def_bool y
442 -- depends on MWINCHIP3D || MWINCHIPC6 || MCYRIXIII || MK7 || MK6 || MPENTIUM4 || MPENTIUMM || MPENTIUMIII || MPENTIUMII || M686 || MK8 || MVIAC3_2 || MVIAC7 || MEFFICEON || MGEODE_LX || MCORE2 || MATOM
443 -+ depends on MWINCHIP3D || MWINCHIPC6 || MCYRIXIII || MK7 || MK6 || MPENTIUM4 || MPENTIUMM || MPENTIUMIII || MPENTIUMII || M686 || MK8 || MVIAC3_2 || MVIAC7 || MEFFICEON || MGEODE_LX || MCORE2 || MATOM || MK8SSE3 || MK10 || MBARCELONA || MBOBCAT || MJAGUAR || MBULLDOZER || MPILEDRIVER || MSTEAMROLLER || MEXCAVATOR || MZEN || MZEN2 || MNEHALEM || MWESTMERE || MSILVERMONT || MGOLDMONT || MGOLDMONTPLUS || MSANDYBRIDGE || MIVYBRIDGE || MHASWELL || MBROADWELL || MSKYLAKE || MSKYLAKEX || MCANNONLAKE || MICELAKE || MCASCADELAKE || MNATIVE
444 -
445 - config X86_USE_3DNOW
446 - def_bool y
447 -@@ -360,26 +576,26 @@ config X86_USE_3DNOW
448 - config X86_P6_NOP
449 - def_bool y
450 - depends on X86_64
451 -- depends on (MCORE2 || MPENTIUM4 || MPSC)
452 -+ depends on (MCORE2 || MPENTIUM4 || MPSC || MNEHALEM || MWESTMERE || MSILVERMONT || MGOLDMONT || MGOLDMONTPLUS || MSANDYBRIDGE || MIVYBRIDGE || MHASWELL || MBROADWELL || MSKYLAKE || MSKYLAKEX || MCANNONLAKE || MICELAKE || MCASCADELAKE || MNATIVE)
453 -
454 - config X86_TSC
455 - def_bool y
456 -- depends on (MWINCHIP3D || MCRUSOE || MEFFICEON || MCYRIXIII || MK7 || MK6 || MPENTIUM4 || MPENTIUMM || MPENTIUMIII || MPENTIUMII || M686 || M586MMX || M586TSC || MK8 || MVIAC3_2 || MVIAC7 || MGEODEGX1 || MGEODE_LX || MCORE2 || MATOM) || X86_64
457 -+ depends on (MWINCHIP3D || MCRUSOE || MEFFICEON || MCYRIXIII || MK7 || MK6 || MPENTIUM4 || MPENTIUMM || MPENTIUMIII || MPENTIUMII || M686 || M586MMX || M586TSC || MK8 || MVIAC3_2 || MVIAC7 || MGEODEGX1 || MGEODE_LX || MCORE2 || MATOM || MK8SSE3 || MK10 || MBARCELONA || MBOBCAT || MJAGUAR || MBULLDOZER || MPILEDRIVER || MSTEAMROLLER || MEXCAVATOR || MZEN || MZEN2 || MNEHALEM || MWESTMERE || MSILVERMONT || MGOLDMONT || MGOLDMONTPLUS || MSANDYBRIDGE || MIVYBRIDGE || MHASWELL || MBROADWELL || MSKYLAKE || MSKYLAKEX || MCANNONLAKE || MICELAKE || MCASCADELAKE || MNATIVE) || X86_64
458 -
459 - config X86_CMPXCHG64
460 - def_bool y
461 -- depends on X86_PAE || X86_64 || MCORE2 || MPENTIUM4 || MPENTIUMM || MPENTIUMIII || MPENTIUMII || M686 || M586TSC || M586MMX || MATOM || MGEODE_LX || MGEODEGX1 || MK6 || MK7 || MK8
462 -+ depends on X86_PAE || X86_64 || MCORE2 || MPENTIUM4 || MPENTIUMM || MPENTIUMIII || MPENTIUMII || M686 || M586TSC || M586MMX || MATOM || MGEODE_LX || MGEODEGX1 || MK6 || MK7 || MK8 || MK8SSE3 || MK10 || MBARCELONA || MBOBCAT || MJAGUAR || MBULLDOZER || MPILEDRIVER || MSTEAMROLLER || MEXCAVATOR || MZEN || MZEN2 || MNEHALEM || MWESTMERE || MSILVERMONT || MGOLDMONT || MGOLDMONTPLUS || MSANDYBRIDGE || MIVYBRIDGE || MHASWELL || MBROADWELL || MSKYLAKE || MSKYLAKEX || MCANNONLAKE || MICELAKE || MCASCADELAKE || MNATIVE
463 -
464 - # this should be set for all -march=.. options where the compiler
465 - # generates cmov.
466 - config X86_CMOV
467 - def_bool y
468 -- depends on (MK8 || MK7 || MCORE2 || MPENTIUM4 || MPENTIUMM || MPENTIUMIII || MPENTIUMII || M686 || MVIAC3_2 || MVIAC7 || MCRUSOE || MEFFICEON || X86_64 || MATOM || MGEODE_LX)
469 -+ depends on (MK8 || MK7 || MCORE2 || MPENTIUM4 || MPENTIUMM || MPENTIUMIII || MPENTIUMII || M686 || MVIAC3_2 || MVIAC7 || MCRUSOE || MEFFICEON || X86_64 || MATOM || MGEODE_LX || MK8SSE3 || MK10 || MBARCELONA || MBOBCAT || MJAGUAR || MBULLDOZER || MPILEDRIVER || MSTEAMROLLER || MEXCAVATOR || MZEN || MZEN2 || MNEHALEM || MWESTMERE || MSILVERMONT || MGOLDMONT || MGOLDMONTPLUS || MSANDYBRIDGE || MIVYBRIDGE || MHASWELL || MBROADWELL || MSKYLAKE || MSKYLAKEX || MCANNONLAKE || MICELAKE || MCASCADELAKE || MNATIVE)
470 -
471 - config X86_MINIMUM_CPU_FAMILY
472 - int
473 - default "64" if X86_64
474 -- default "6" if X86_32 && (MPENTIUM4 || MPENTIUMM || MPENTIUMIII || MPENTIUMII || M686 || MVIAC3_2 || MVIAC7 || MEFFICEON || MATOM || MCRUSOE || MCORE2 || MK7 || MK8)
475 -+ default "6" if X86_32 && (MPENTIUM4 || MPENTIUMM || MPENTIUMIII || MPENTIUMII || M686 || MVIAC3_2 || MVIAC7 || MEFFICEON || MATOM || MCRUSOE || MCORE2 || MK7 || MK8 || MK8SSE3 || MK10 || MBARCELONA || MBOBCAT || MJAGUAR || MBULLDOZER || MPILEDRIVER || MSTEAMROLLER || MEXCAVATOR || MZEN || MZEN2 || MNEHALEM || MWESTMERE || MSILVERMONT || MGOLDMONT || MGOLDMONTPLUS || MSANDYBRIDGE || MIVYBRIDGE || MHASWELL || MBROADWELL || MSKYLAKE || MSKYLAKEX || MCANNONLAKE || MICELAKE || MCASCADELAKE || MNATIVE)
476 - default "5" if X86_32 && X86_CMPXCHG64
477 - default "4"
478 -
479 -diff --git a/arch/x86/Makefile b/arch/x86/Makefile
480 -index 00e378de8bc0..7602ef4a2dd4 100644
481 ---- a/arch/x86/Makefile
482 -+++ b/arch/x86/Makefile
483 -@@ -121,11 +121,38 @@ else
484 - # FIXME - should be integrated in Makefile.cpu (Makefile_32.cpu)
485 - cflags-$(CONFIG_MK8) += $(call cc-option,-march=k8)
486 - cflags-$(CONFIG_MPSC) += $(call cc-option,-march=nocona)
487 --
488 -- cflags-$(CONFIG_MCORE2) += \
489 -- $(call cc-option,-march=core2,$(call cc-option,-mtune=generic))
490 -- cflags-$(CONFIG_MATOM) += $(call cc-option,-march=atom) \
491 -- $(call cc-option,-mtune=atom,$(call cc-option,-mtune=generic))
492 -+ cflags-$(CONFIG_MK8SSE3) += $(call cc-option,-march=k8-sse3)
493 -+ cflags-$(CONFIG_MK10) += $(call cc-option,-march=amdfam10)
494 -+ cflags-$(CONFIG_MBARCELONA) += $(call cc-option,-march=barcelona)
495 -+ cflags-$(CONFIG_MBOBCAT) += $(call cc-option,-march=btver1)
496 -+ cflags-$(CONFIG_MJAGUAR) += $(call cc-option,-march=btver2)
497 -+ cflags-$(CONFIG_MBULLDOZER) += $(call cc-option,-march=bdver1)
498 -+ cflags-$(CONFIG_MPILEDRIVER) += $(call cc-option,-march=bdver2)
499 -+ cflags-$(CONFIG_MPILEDRIVER) += $(call cc-option,-mno-tbm)
500 -+ cflags-$(CONFIG_MSTEAMROLLER) += $(call cc-option,-march=bdver3)
501 -+ cflags-$(CONFIG_MSTEAMROLLER) += $(call cc-option,-mno-tbm)
502 -+ cflags-$(CONFIG_MEXCAVATOR) += $(call cc-option,-march=bdver4)
503 -+ cflags-$(CONFIG_MEXCAVATOR) += $(call cc-option,-mno-tbm)
504 -+ cflags-$(CONFIG_MZEN) += $(call cc-option,-march=znver1)
505 -+ cflags-$(CONFIG_MZEN2) += $(call cc-option,-march=znver2)
506 -+
507 -+ cflags-$(CONFIG_MNATIVE) += $(call cc-option,-march=native)
508 -+ cflags-$(CONFIG_MATOM) += $(call cc-option,-march=bonnell)
509 -+ cflags-$(CONFIG_MCORE2) += $(call cc-option,-march=core2)
510 -+ cflags-$(CONFIG_MNEHALEM) += $(call cc-option,-march=nehalem)
511 -+ cflags-$(CONFIG_MWESTMERE) += $(call cc-option,-march=westmere)
512 -+ cflags-$(CONFIG_MSILVERMONT) += $(call cc-option,-march=silvermont)
513 -+ cflags-$(CONFIG_MGOLDMONT) += $(call cc-option,-march=goldmont)
514 -+ cflags-$(CONFIG_MGOLDMONTPLUS) += $(call cc-option,-march=goldmont-plus)
515 -+ cflags-$(CONFIG_MSANDYBRIDGE) += $(call cc-option,-march=sandybridge)
516 -+ cflags-$(CONFIG_MIVYBRIDGE) += $(call cc-option,-march=ivybridge)
517 -+ cflags-$(CONFIG_MHASWELL) += $(call cc-option,-march=haswell)
518 -+ cflags-$(CONFIG_MBROADWELL) += $(call cc-option,-march=broadwell)
519 -+ cflags-$(CONFIG_MSKYLAKE) += $(call cc-option,-march=skylake)
520 -+ cflags-$(CONFIG_MSKYLAKEX) += $(call cc-option,-march=skylake-avx512)
521 -+ cflags-$(CONFIG_MCANNONLAKE) += $(call cc-option,-march=cannonlake)
522 -+ cflags-$(CONFIG_MICELAKE) += $(call cc-option,-march=icelake-client)
523 -+ cflags-$(CONFIG_MCASCADELAKE) += $(call cc-option,-march=cascadelake)
524 - cflags-$(CONFIG_GENERIC_CPU) += $(call cc-option,-mtune=generic)
525 - KBUILD_CFLAGS += $(cflags-y)
526 -
527 -diff --git a/arch/x86/include/asm/vermagic.h b/arch/x86/include/asm/vermagic.h
528 -index 75884d2cdec3..0cf864d2d110 100644
529 ---- a/arch/x86/include/asm/vermagic.h
530 -+++ b/arch/x86/include/asm/vermagic.h
531 -@@ -17,6 +17,36 @@
532 - #define MODULE_PROC_FAMILY "586MMX "
533 - #elif defined CONFIG_MCORE2
534 - #define MODULE_PROC_FAMILY "CORE2 "
535 -+#elif defined CONFIG_MNATIVE
536 -+#define MODULE_PROC_FAMILY "NATIVE "
537 -+#elif defined CONFIG_MNEHALEM
538 -+#define MODULE_PROC_FAMILY "NEHALEM "
539 -+#elif defined CONFIG_MWESTMERE
540 -+#define MODULE_PROC_FAMILY "WESTMERE "
541 -+#elif defined CONFIG_MSILVERMONT
542 -+#define MODULE_PROC_FAMILY "SILVERMONT "
543 -+#elif defined CONFIG_MGOLDMONT
544 -+#define MODULE_PROC_FAMILY "GOLDMONT "
545 -+#elif defined CONFIG_MGOLDMONTPLUS
546 -+#define MODULE_PROC_FAMILY "GOLDMONTPLUS "
547 -+#elif defined CONFIG_MSANDYBRIDGE
548 -+#define MODULE_PROC_FAMILY "SANDYBRIDGE "
549 -+#elif defined CONFIG_MIVYBRIDGE
550 -+#define MODULE_PROC_FAMILY "IVYBRIDGE "
551 -+#elif defined CONFIG_MHASWELL
552 -+#define MODULE_PROC_FAMILY "HASWELL "
553 -+#elif defined CONFIG_MBROADWELL
554 -+#define MODULE_PROC_FAMILY "BROADWELL "
555 -+#elif defined CONFIG_MSKYLAKE
556 -+#define MODULE_PROC_FAMILY "SKYLAKE "
557 -+#elif defined CONFIG_MSKYLAKEX
558 -+#define MODULE_PROC_FAMILY "SKYLAKEX "
559 -+#elif defined CONFIG_MCANNONLAKE
560 -+#define MODULE_PROC_FAMILY "CANNONLAKE "
561 -+#elif defined CONFIG_MICELAKE
562 -+#define MODULE_PROC_FAMILY "ICELAKE "
563 -+#elif defined CONFIG_MCASCADELAKE
564 -+#define MODULE_PROC_FAMILY "CASCADELAKE "
565 - #elif defined CONFIG_MATOM
566 - #define MODULE_PROC_FAMILY "ATOM "
567 - #elif defined CONFIG_M686
568 -@@ -35,6 +65,28 @@
569 - #define MODULE_PROC_FAMILY "K7 "
570 - #elif defined CONFIG_MK8
571 - #define MODULE_PROC_FAMILY "K8 "
572 -+#elif defined CONFIG_MK8SSE3
573 -+#define MODULE_PROC_FAMILY "K8SSE3 "
574 -+#elif defined CONFIG_MK10
575 -+#define MODULE_PROC_FAMILY "K10 "
576 -+#elif defined CONFIG_MBARCELONA
577 -+#define MODULE_PROC_FAMILY "BARCELONA "
578 -+#elif defined CONFIG_MBOBCAT
579 -+#define MODULE_PROC_FAMILY "BOBCAT "
580 -+#elif defined CONFIG_MBULLDOZER
581 -+#define MODULE_PROC_FAMILY "BULLDOZER "
582 -+#elif defined CONFIG_MPILEDRIVER
583 -+#define MODULE_PROC_FAMILY "PILEDRIVER "
584 -+#elif defined CONFIG_MSTEAMROLLER
585 -+#define MODULE_PROC_FAMILY "STEAMROLLER "
586 -+#elif defined CONFIG_MJAGUAR
587 -+#define MODULE_PROC_FAMILY "JAGUAR "
588 -+#elif defined CONFIG_MEXCAVATOR
589 -+#define MODULE_PROC_FAMILY "EXCAVATOR "
590 -+#elif defined CONFIG_MZEN
591 -+#define MODULE_PROC_FAMILY "ZEN "
592 -+#elif defined CONFIG_MZEN2
593 -+#define MODULE_PROC_FAMILY "ZEN2 "
594 - #elif defined CONFIG_MELAN
595 - #define MODULE_PROC_FAMILY "ELAN "
596 - #elif defined CONFIG_MCRUSOE
597 ---
598 -2.30.1
599 -