Re: [PATCH] KVM: SVM: Fix sev_pin_memory() error handling

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

 



On Tue, Jul 14, 2020 at 05:23:51PM +0300, Dan Carpenter wrote:
> The sev_pin_memory() function was modified to return error pointers
> instead of NULL but there are two problems.  The first problem is that
> if "npages" is zero then it still returns NULL.  Secondly, several of
> the callers were not updated to check for error pointers instead of
> NULL.
> 
> Either one of these issues will lead to an Oops.
> 
> Fixes: a8d908b5873c ("KVM: x86: report sev_pin_memory errors with PTR_ERR")

Explicit Cc: to stable needed for KVM patches.

> Signed-off-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx>

Reviewed-by: Sean Christopherson <sean.j.christopherson@xxxxxxxxx>



[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