* On Wednesday 08 Oct 2008 12:09:20 Sheng Yang wrote:
> Signed-off-by: Sheng Yang <[EMAIL PROTECTED]>
> ---
>  arch/x86/kvm/x86.c |    4 +++-
>  1 files changed, 3 insertions(+), 1 deletions(-)
>
> diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c
> index 675fcc1..c5763d7 100644
> --- a/arch/x86/kvm/x86.c
> +++ b/arch/x86/kvm/x86.c
> @@ -176,7 +176,9 @@ static void kvm_free_assigned_device(struct kvm *kvm,
>       if (irqchip_in_kernel(kvm) && assigned_dev->irq_requested)
>               free_irq(assigned_dev->host_irq, (void *)assigned_dev);
>
> -     kvm_unregister_irq_ack_notifier(kvm, &assigned_dev->ack_notifier);
> +     if (irqchip_in_kernel(kvm))
> +             kvm_unregister_irq_ack_notifier(kvm,
> +                             &assigned_dev->ack_notifier);

The unregister API should perform the check whether the said notifier exists 
so this shouldn't be necessary.
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to