mirror of
https://github.com/torvalds/linux.git
synced 2026-05-05 23:05:25 -04:00
Merge branch 'for-next/sysreg' into for-next/core
* for-next/sysreg: : arm64 sysreg updates/cleanups arm64/sysreg: Remove unused define ARM64_FEATURE_FIELD_BITS KVM: arm64: selftests: Consider all 7 possible levels of cache KVM: arm64: selftests: Remove ARM64_FEATURE_FIELD_BITS and its last user arm64/sysreg: Add ICH_VMCR_EL2 arm64/sysreg: Move generation of RES0/RES1/UNKN to function arm64/sysreg: Support feature-specific fields with 'Prefix' descriptor arm64/sysreg: Fix checks for incomplete sysreg definitions arm64/sysreg: Replace TCR_EL1 field macros
This commit is contained in:
@@ -265,7 +265,9 @@ static void guest_code(void)
|
||||
/* Return a safe value to a given ftr_bits an ftr value */
|
||||
uint64_t get_safe_value(const struct reg_ftr_bits *ftr_bits, uint64_t ftr)
|
||||
{
|
||||
uint64_t ftr_max = GENMASK_ULL(ARM64_FEATURE_FIELD_BITS - 1, 0);
|
||||
uint64_t ftr_max = ftr_bits->mask >> ftr_bits->shift;
|
||||
|
||||
TEST_ASSERT(ftr_max > 1, "This test doesn't support single bit features");
|
||||
|
||||
if (ftr_bits->sign == FTR_UNSIGNED) {
|
||||
switch (ftr_bits->type) {
|
||||
@@ -317,7 +319,9 @@ uint64_t get_safe_value(const struct reg_ftr_bits *ftr_bits, uint64_t ftr)
|
||||
/* Return an invalid value to a given ftr_bits an ftr value */
|
||||
uint64_t get_invalid_value(const struct reg_ftr_bits *ftr_bits, uint64_t ftr)
|
||||
{
|
||||
uint64_t ftr_max = GENMASK_ULL(ARM64_FEATURE_FIELD_BITS - 1, 0);
|
||||
uint64_t ftr_max = ftr_bits->mask >> ftr_bits->shift;
|
||||
|
||||
TEST_ASSERT(ftr_max > 1, "This test doesn't support single bit features");
|
||||
|
||||
if (ftr_bits->sign == FTR_UNSIGNED) {
|
||||
switch (ftr_bits->type) {
|
||||
@@ -669,7 +673,7 @@ static void test_clidr(struct kvm_vcpu *vcpu)
|
||||
clidr = vcpu_get_reg(vcpu, KVM_ARM64_SYS_REG(SYS_CLIDR_EL1));
|
||||
|
||||
/* find the first empty level in the cache hierarchy */
|
||||
for (level = 1; level < 7; level++) {
|
||||
for (level = 1; level <= 7; level++) {
|
||||
if (!CLIDR_CTYPE(clidr, level))
|
||||
break;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user