Re: [RFC PATCH] KVM: introduce kvm_check_device

2015-01-08 Thread Andre Przywara
Hi Scott, On 07/01/15 18:16, Scott Wood wrote: On Wed, 2015-01-07 at 18:11 +, Andre Przywara wrote: On 07/01/15 17:45, Scott Wood wrote: On Wed, 2015-01-07 at 10:55 +, Andre Przywara wrote: Hi Scott, thanks for looking at the patch. On 06/01/15 20:52, Scott Wood wrote: Out of

Re: [RFC PATCH] KVM: introduce kvm_check_device

2015-01-07 Thread Andre Przywara
Hi Scott, thanks for looking at the patch. On 06/01/15 20:52, Scott Wood wrote: On Tue, 2015-01-06 at 16:12 +, Andre Przywara wrote: While we can easily register and unregister KVM devices, there is currently no easy way of checking whether a device has been registered. Introduce

Re: [RFC PATCH] KVM: introduce kvm_check_device

2015-01-07 Thread Scott Wood
On Wed, 2015-01-07 at 10:55 +, Andre Przywara wrote: Hi Scott, thanks for looking at the patch. On 06/01/15 20:52, Scott Wood wrote: Out of curiosity, why do you need to test it from inside the kernel but outside kvm_main.c? I need it from arch/arm/kvm/arm.c or alternatively

Re: [RFC PATCH] KVM: introduce kvm_check_device

2015-01-07 Thread Andre Przywara
On 07/01/15 17:45, Scott Wood wrote: On Wed, 2015-01-07 at 10:55 +, Andre Przywara wrote: Hi Scott, thanks for looking at the patch. On 06/01/15 20:52, Scott Wood wrote: Out of curiosity, why do you need to test it from inside the kernel but outside kvm_main.c? I need it from

Re: [RFC PATCH] KVM: introduce kvm_check_device

2015-01-07 Thread Scott Wood
On Wed, 2015-01-07 at 18:11 +, Andre Przywara wrote: On 07/01/15 17:45, Scott Wood wrote: On Wed, 2015-01-07 at 10:55 +, Andre Przywara wrote: Hi Scott, thanks for looking at the patch. On 06/01/15 20:52, Scott Wood wrote: Out of curiosity, why do you need to test it from

Re: [RFC PATCH] KVM: introduce kvm_check_device

2015-01-06 Thread Scott Wood
On Tue, 2015-01-06 at 16:12 +, Andre Przywara wrote: While we can easily register and unregister KVM devices, there is currently no easy way of checking whether a device has been registered. Introduce kvm_check_device() for that purpose and use it in two existing functions. Also change

[RFC PATCH] KVM: introduce kvm_check_device

2015-01-06 Thread Andre Przywara
While we can easily register and unregister KVM devices, there is currently no easy way of checking whether a device has been registered. Introduce kvm_check_device() for that purpose and use it in two existing functions. Also change the return code for an invalid type number from ENOSPC to