-
Notifications
You must be signed in to change notification settings - Fork 122
[Deepin-Kernel-SIG] [linux 6.6-y] [HISI] [Backport] Backport FEAT_NMI/perf DDRC/perf CORE/perf uncore/perf BRBE/minios/FEAT_HAFT and FEAT_LS64 module for Kunpeng new SOC #1475
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 93 commits
a296a2d
ec154b3
ee34373
e7d8889
40efa49
f9171c8
2a0c41f
99b0d70
39970c7
534c87e
3dccb9a
16b6cc6
8064f24
966cba9
b60a0e5
138647f
94dbcc3
d4738b8
ac54b74
545e4bb
187c91f
aaf9ac0
6b96639
c26479e
f08e399
c2f8873
f92e179
5cb94fa
65dc8b8
96d7481
73a1dbd
5e4f602
2e80f79
f0a9b99
6416186
b796bd4
a944d2f
dd0e1a4
f25cc8f
c55ac54
2ba1dc2
6f634a8
45c3054
a08ce98
4507e8a
9ccbbee
8138331
94f70c4
aed26b7
9adbc0c
e9e199f
19d4e9c
2b84ce4
c7bbce1
b43819c
fd16ce1
350a46e
865b459
a2d7853
72b8f60
90075ab
3602840
ba341b3
067c7b9
32589c5
73a3ec0
550e2bf
9d24a96
e1e07d5
f21229b
e6c537f
0e71d35
626fa7d
63f6f3d
43e26ec
6f006a2
17e9d3a
2f8eb21
3aef22c
6cfd43b
2bc9208
f2a7a84
0da1bdf
6e24b87
04c92bf
65c46f5
b9ea2e9
68c4bb0
6b63a6e
ed45119
f243d6f
f390b95
d78838c
2e6b1c4
9d05ee6
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -10,6 +10,7 @@ | |
| #include <asm/arch_gicv3.h> | ||
| #include <asm/barrier.h> | ||
| #include <asm/cpufeature.h> | ||
| #include <asm/nmi.h> | ||
| #include <asm/ptrace.h> | ||
|
|
||
| #define DAIF_PROCCTX 0 | ||
|
|
@@ -35,6 +36,9 @@ static inline void local_daif_mask(void) | |
| if (system_uses_irq_prio_masking()) | ||
| gic_write_pmr(GIC_PRIO_IRQON | GIC_PRIO_PSR_I_SET); | ||
|
|
||
| if (system_uses_nmi()) | ||
| _allint_set(); | ||
|
|
||
| trace_hardirqs_off(); | ||
| } | ||
|
|
||
|
|
@@ -116,6 +120,14 @@ static inline void local_daif_restore(unsigned long flags) | |
|
|
||
| write_sysreg(flags, daif); | ||
|
|
||
| /* If we can take asynchronous errors we can take NMIs */ | ||
| if (system_uses_nmi()) { | ||
| if (flags & PSR_A_BIT) | ||
| _allint_set(); | ||
| else | ||
| _allint_clear(); | ||
| } | ||
|
|
||
| if (irq_disabled) | ||
| trace_hardirqs_off(); | ||
| } | ||
|
|
@@ -140,5 +152,14 @@ static inline void local_daif_inherit(struct pt_regs *regs) | |
| * use the pmr instead. | ||
| */ | ||
| write_sysreg(flags, daif); | ||
|
|
||
| /* The ALLINT field is at the same position in pstate and ALLINT */ | ||
| if (system_uses_nmi()) { | ||
| if (regs->pstate & ALLINT_ALLINT) | ||
| _allint_set(); | ||
|
Comment on lines
+156
to
+159
|
||
| else | ||
| _allint_clear(); | ||
| } | ||
| } | ||
|
|
||
| #endif | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The new
select ARCH_HAS_NONLEAF_PMD_YOUNG if ARM64_HAFline references a Kconfig symbolARM64_HAFthat does not exist (the feature config added below isARM64_HAFTand the existing AF/DBM option isARM64_HW_AFDBM). This will cause Kconfig warnings or errors and prevent the intended selection from taking effect; the condition should be updated to use the correct symbol name (likelyARM64_HAFT).