Re: [PATCH v3 10/21] KVM: arm64: Enable forcing page-level stage-2 mappings
From: Fuad Tabba <hidden>
Date: 2021-08-03 10:44:11
Also in:
kvmarm, lkml
From: Fuad Tabba <hidden>
Date: 2021-08-03 10:44:11
Also in:
kvmarm, lkml
Hi Quentin,
quoted
quoted
+static bool stage2_block_mapping_allowed(u64 addr, u64 end, u32 level, + struct stage2_map_data *data) +{ + if (data->force_pte && (level < (KVM_PGTABLE_MAX_LEVELS - 1))) + return false;I'm not sure I understand why checking the level is necessary. Can there be block mapping at the last possible level?That's probably just a matter of naming, but this function is in fact called at every level, just like kvm_block_mapping_supported() was before. And we rely on it returning true at the last level, so I need to do that check here. Maybe renaming this stage2_leaf_mapping_allowed() would clarify?
Yes it would. Thanks, /fuad _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel