mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Bjorn Helgaas <helgaas@kernel.org>
To: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Kishon Vijay Abraham I <kishon@ti.com>,
	Bjorn Helgaas <bhelgaas@google.com>,
	linux-pci@vger.kernel.org, Arnd Bergmann <arnd@arndb.de>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] PCI: endpoint: PCI_ENDPOINT should depend on HAS_DMA
Date: Mon, 22 May 2017 16:26:40 -0500	[thread overview]
Message-ID: <20170522212640.GD19733@bhelgaas-glaptop.roam.corp.google.com> (raw)
In-Reply-To: <1494955268-1262-1-git-send-email-geert@linux-m68k.org>

On Tue, May 16, 2017 at 07:21:08PM +0200, Geert Uytterhoeven wrote:
> If NO_DMA=y:
> 
>     drivers/built-in.o: In function `__pci_epc_create':
>     (.text+0xef4e): undefined reference to `bad_dma_ops'
>     drivers/built-in.o: In function `pci_epc_add_epf':
>     (.text+0xf676): undefined reference to `bad_dma_ops'
>     drivers/built-in.o: In function `pci_epf_alloc_space':
>     (.text+0xfa32): undefined reference to `bad_dma_ops'
>     drivers/built-in.o: In function `pci_epf_free_space':
>     (.text+0xfac4): undefined reference to `bad_dma_ops'
> 
> Add a dependency on HAS_DMA to fix this.
> 
> Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>

Applied to for-linus for v4.12, thanks!

> ---
> Should PCI_ENDPOINT depend on CONFIG_PCI instead?

I *think* we want HAS_DMA, not CONFIG_PCI, because CONFIG_PCI means we
want the infrastructure for PCI host bridges, enumerating children of
the bridges, etc.  I think we want to allow PCI_ENDPOINT without all
that.

Kishon?

> ---
>  drivers/pci/endpoint/Kconfig | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/pci/endpoint/Kconfig b/drivers/pci/endpoint/Kconfig
> index c23f146fb5a668b3..c09623ca8c3b14b9 100644
> --- a/drivers/pci/endpoint/Kconfig
> +++ b/drivers/pci/endpoint/Kconfig
> @@ -6,6 +6,7 @@ menu "PCI Endpoint"
>  
>  config PCI_ENDPOINT
>  	bool "PCI Endpoint Support"
> +	depends on HAS_DMA
>  	help
>  	   Enable this configuration option to support configurable PCI
>  	   endpoint. This should be enabled if the platform has a PCI
> -- 
> 2.7.4
> 

  reply	other threads:[~2017-05-22 21:26 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-05-16 17:21 Geert Uytterhoeven
2017-05-22 21:26 ` Bjorn Helgaas [this message]
2017-05-23  6:43   ` Kishon Vijay Abraham I
2017-05-23  7:12     ` Geert Uytterhoeven

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=20170522212640.GD19733@bhelgaas-glaptop.roam.corp.google.com \
    --to=helgaas@kernel.org \
    --cc=arnd@arndb.de \
    --cc=bhelgaas@google.com \
    --cc=geert@linux-m68k.org \
    --cc=kishon@ti.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®