Skip to content

Commit 82affc9

Browse files
ouptontorvalds
authored andcommitted
Revert "KVM: arm64: Snapshot all non-zero RES0/RES1 sysreg fields for later checking"
This reverts commits 99101dd and b80b701. Linus reports that the sysreg reserved bit checks in KVM have led to build failures, arising from commit fdd867f ("arm64/sysreg: Add register fields for ID_AA64DFR1_EL1") giving meaning to fields that were previously RES0. Of course, this is a genuine issue, since KVM's sysreg emulation depends heavily on the definition of reserved fields. But at this point the build breakage is far more offensive, and the right course of action is to revert and retry later. All of these build-time assertions were on by default before commit 99101dd ("KVM: arm64: Make build-time check of RES0/RES1 bits optional"), so deliberately revert it all atomically to avoid introducing further breakage of bisection. Link: https://lore.kernel.org/all/CAHk-=whCvkhc8BbFOUf1ddOsgSGgEjwoKv77=HEY1UiVCydGqw@mail.gmail.com/ Acked-by: Marc Zyngier <maz@kernel.org> Signed-off-by: Oliver Upton <oliver.upton@linux.dev> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
1 parent 277100b commit 82affc9

File tree

3 files changed

+0
-139
lines changed

3 files changed

+0
-139
lines changed

arch/arm64/kvm/Kconfig

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -65,15 +65,4 @@ config PROTECTED_NVHE_STACKTRACE
6565

6666
If unsure, or not using protected nVHE (pKVM), say N.
6767

68-
config KVM_ARM64_RES_BITS_PARANOIA
69-
bool "Build-time check of RES0/RES1 bits"
70-
depends on KVM
71-
default n
72-
help
73-
Say Y here to validate that KVM's knowledge of most system
74-
registers' RES0/RES1 bits matches when the rest of the kernel
75-
defines. Expect the build to fail badly if you enable this.
76-
77-
Just say N.
78-
7968
endif # VIRTUALIZATION

arch/arm64/kvm/check-res-bits.h

Lines changed: 0 additions & 125 deletions
This file was deleted.

arch/arm64/kvm/sys_regs.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@
3232

3333
#include <trace/events/kvm.h>
3434

35-
#include "check-res-bits.h"
3635
#include "sys_regs.h"
3736

3837
#include "trace.h"
@@ -4110,8 +4109,6 @@ int __init kvm_sys_reg_table_init(void)
41104109
unsigned int i;
41114110
int ret = 0;
41124111

4113-
check_res_bits();
4114-
41154112
/* Make sure tables are unique and in order. */
41164113
valid &= check_sysreg_table(sys_reg_descs, ARRAY_SIZE(sys_reg_descs), false);
41174114
valid &= check_sysreg_table(cp14_regs, ARRAY_SIZE(cp14_regs), true);

0 commit comments

Comments
 (0)