diff mbox series

svm: Add warning message for AVIC IPI invalid target

Message ID 20190122102356.125085-1-Suravee.Suthikulpanit@amd.com (mailing list archive)
State New, archived
Headers show
Series svm: Add warning message for AVIC IPI invalid target | expand

Commit Message

Suthikulpanit, Suravee Jan. 22, 2019, 10:24 a.m. UTC
From: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>

Print warning message when IPI target ID is invalid due to one of
the following reasons:
  * In logical mode: cluster > max_cluster (64)
  * In physical mode: target > max_physical (512)
  * Address is not present in the physical or logical ID tables

Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>
---
 arch/x86/kvm/svm.c | 2 ++
 1 file changed, 2 insertions(+)

Comments

Paolo Bonzini Jan. 25, 2019, 5:51 p.m. UTC | #1
On 22/01/19 11:24, Suthikulpanit, Suravee wrote:
> From: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>
> 
> Print warning message when IPI target ID is invalid due to one of
> the following reasons:
>   * In logical mode: cluster > max_cluster (64)
>   * In physical mode: target > max_physical (512)
>   * Address is not present in the physical or logical ID tables
> 
> Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>
> ---
>  arch/x86/kvm/svm.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/arch/x86/kvm/svm.c b/arch/x86/kvm/svm.c
> index a157ca5b6869..2aff835a65ed 100644
> --- a/arch/x86/kvm/svm.c
> +++ b/arch/x86/kvm/svm.c
> @@ -4526,6 +4526,8 @@ static int avic_incomplete_ipi_interception(struct vcpu_svm *svm)
>  		break;
>  	}
>  	case AVIC_IPI_FAILURE_INVALID_TARGET:
> +		WARN_ONCE(1, "Invalid IPI target: index=%u, vcpu=%d, icr=%#0x:%#0x\n",
> +			  index, svm->vcpu.vcpu_id, icrh, icrl);
>  		break;
>  	case AVIC_IPI_FAILURE_INVALID_BACKING_PAGE:
>  		WARN_ONCE(1, "Invalid backing page\n");
> 

Queued, thanks.

Paolo
diff mbox series

Patch

diff --git a/arch/x86/kvm/svm.c b/arch/x86/kvm/svm.c
index a157ca5b6869..2aff835a65ed 100644
--- a/arch/x86/kvm/svm.c
+++ b/arch/x86/kvm/svm.c
@@ -4526,6 +4526,8 @@  static int avic_incomplete_ipi_interception(struct vcpu_svm *svm)
 		break;
 	}
 	case AVIC_IPI_FAILURE_INVALID_TARGET:
+		WARN_ONCE(1, "Invalid IPI target: index=%u, vcpu=%d, icr=%#0x:%#0x\n",
+			  index, svm->vcpu.vcpu_id, icrh, icrl);
 		break;
 	case AVIC_IPI_FAILURE_INVALID_BACKING_PAGE:
 		WARN_ONCE(1, "Invalid backing page\n");