All of lore.kernel.org
 help / color / mirror / Atom feed
From: Randy Dunlap <rdunlap@infradead.org>
To: Alex Williamson <alex.williamson@redhat.com>
Cc: gleb@redhat.com, kvm@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] kvm: KVM_CAP_IOMMU only available with device assignment
Date: Mon, 29 Apr 2013 09:59:30 -0700	[thread overview]
Message-ID: <517EA6F2.706@infradead.org> (raw)
In-Reply-To: <20130429165334.19404.54557.stgit@bling.home>

On 04/29/13 09:54, Alex Williamson wrote:
> Fix build with CONFIG_PCI unset by linking KVM_CAP_IOMMU to
> device assignment config option.  It has no purpose otherwise.
> 
> Signed-off-by: Alex Williamson <alex.williamson@redhat.com>

Reported-by: Randy Dunlap <rdunlap@infradead.org>
Acked-by: Randy Dunlap <rdunlap@infradead.org>

Thanks.


> ---
>  arch/ia64/kvm/kvm-ia64.c |    2 ++
>  arch/x86/kvm/x86.c       |    2 ++
>  2 files changed, 4 insertions(+)
> 
> diff --git a/arch/ia64/kvm/kvm-ia64.c b/arch/ia64/kvm/kvm-ia64.c
> index dcc5607..5b2dc0d 100644
> --- a/arch/ia64/kvm/kvm-ia64.c
> +++ b/arch/ia64/kvm/kvm-ia64.c
> @@ -204,9 +204,11 @@ int kvm_dev_ioctl_check_extension(long ext)
>  	case KVM_CAP_COALESCED_MMIO:
>  		r = KVM_COALESCED_MMIO_PAGE_OFFSET;
>  		break;
> +#ifdef CONFIG_KVM_DEVICE_ASSIGNMENT
>  	case KVM_CAP_IOMMU:
>  		r = iommu_present(&pci_bus_type);
>  		break;
> +#endif
>  	default:
>  		r = 0;
>  	}
> diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c
> index 73e443f..f83a8e0 100644
> --- a/arch/x86/kvm/x86.c
> +++ b/arch/x86/kvm/x86.c
> @@ -2543,9 +2543,11 @@ int kvm_dev_ioctl_check_extension(long ext)
>  	case KVM_CAP_PV_MMU:	/* obsolete */
>  		r = 0;
>  		break;
> +#ifdef CONFIG_KVM_DEVICE_ASSIGNMENT
>  	case KVM_CAP_IOMMU:
>  		r = iommu_present(&pci_bus_type);
>  		break;
> +#endif
>  	case KVM_CAP_MCE:
>  		r = KVM_MAX_MCE_BANKS;
>  		break;
> 
> --


-- 
~Randy

  reply	other threads:[~2013-04-29 16:59 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-04-29 16:54 [PATCH] kvm: KVM_CAP_IOMMU only available with device assignment Alex Williamson
2013-04-29 16:59 ` Randy Dunlap [this message]
2013-04-30  2:10   ` Marcelo Tosatti

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=517EA6F2.706@infradead.org \
    --to=rdunlap@infradead.org \
    --cc=alex.williamson@redhat.com \
    --cc=gleb@redhat.com \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.