Re: [PATCH v4 18/43] arm64: RME: Handle realm enter/exit

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Steven Price <steven.price@xxxxxxx> writes:

> +	/* Exit to VMM to complete the change */
> +	kvm_prepare_memory_fault_exit(vcpu, base, top_ipa - base, false, false,
> +				      ripas == 1);
> +


s/1/RMI_RAM ?

May be we can make it an enum like rsi_ripas

modified   arch/arm64/include/asm/rmi_smc.h
@@ -62,9 +62,11 @@
 #define RMI_ERROR_REC		3
 #define RMI_ERROR_RTT		4
 
-#define RMI_EMPTY		0
-#define RMI_RAM			1
-#define RMI_DESTROYED		2
+enum rmi_ripas {
+	RMI_EMPTY,
+	RMI_RAM,
+	RMI_DESTROYED,
+};
 
 #define RMI_NO_MEASURE_CONTENT	0
 #define RMI_MEASURE_CONTENT	1
modified   arch/arm64/kvm/rme-exit.c
@@ -112,7 +112,7 @@ static int rec_exit_ripas_change(struct kvm_vcpu *vcpu)
 
 	/* Exit to VMM to complete the change */
 	kvm_prepare_memory_fault_exit(vcpu, base, top_ipa - base, false, false,
-				      ripas == 1);
+				      ripas == RMI_RAM);
 
 	return 0;
 }




[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux