Commit 0c2bca09 authored by yangjinqian's avatar yangjinqian Committed by Jinqian Yang
Browse files

KVM: arm64: Add new HiSi CPU type to support DVMBM

virt inclusion
category: feature
bugzilla: https://gitee.com/openeuler/kernel/issues/IBTXY2



------------------------------------------------------------------------

Add new HiSi CPU type HIP12 for supporting DVMBM.
Function kvm_get_pg_cfg() is used to get configuration
for translating logic cluster id to physical cluster id
which is not needed by hip12, so skip it for hip12.

Signed-off-by: default avatarJinqian Yang <yangjinqian1@huawei.com>
parent 2671ba22
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -159,7 +159,8 @@ static void hardware_disable_dvmbm(void *data)

bool hisi_dvmbm_supported(void)
{
	if (cpu_type != HI_IP10 && cpu_type != HI_IP10C)
	if (cpu_type != HI_IP10 && cpu_type != HI_IP10C &&
	    cpu_type != HI_IP12)
		return false;

	if (!is_kernel_in_hyp_mode()) {
@@ -519,6 +520,9 @@ void kvm_get_pg_cfg(void)
	u64 mn_phy_base;
	u32 val;

	if (cpu_type == HI_IP12)
		return;

	socket_num = kvm_get_socket_num();
	die_num = kvm_get_die_num();