Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1642687 > unrolled thread

[PATCH] PCI: endpoint: PCI_ENDPOINT should depend on HAS_DMA

Started byGeert Uytterhoeven <geert@linux-m68k.org>
First post2017-05-16 19:30 +0200
Last post2017-05-23 09:20 +0200
Articles 4 — 3 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH] PCI: endpoint: PCI_ENDPOINT should depend on HAS_DMA Geert Uytterhoeven <geert@linux-m68k.org> - 2017-05-16 19:30 +0200
    Re: [PATCH] PCI: endpoint: PCI_ENDPOINT should depend on HAS_DMA Bjorn Helgaas <helgaas@kernel.org> - 2017-05-22 23:30 +0200
      Re: [PATCH] PCI: endpoint: PCI_ENDPOINT should depend on HAS_DMA Kishon Vijay Abraham I <kishon@ti.com> - 2017-05-23 08:50 +0200
        Re: [PATCH] PCI: endpoint: PCI_ENDPOINT should depend on HAS_DMA Geert Uytterhoeven <geert@linux-m68k.org> - 2017-05-23 09:20 +0200

#1642687 — [PATCH] PCI: endpoint: PCI_ENDPOINT should depend on HAS_DMA

FromGeert Uytterhoeven <geert@linux-m68k.org>
Date2017-05-16 19:30 +0200
Subject[PATCH] PCI: endpoint: PCI_ENDPOINT should depend on HAS_DMA
Message-ID<tHOsi-8uX-17@gated-at.bofh.it>
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>
---
Should PCI_ENDPOINT depend on CONFIG_PCI instead?
---
 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

[toc] | [next] | [standalone]


#1647412

FromBjorn Helgaas <helgaas@kernel.org>
Date2017-05-22 23:30 +0200
Message-ID<tK33Q-2tD-21@gated-at.bofh.it>
In reply to#1642687
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
> 

[toc] | [prev] | [next] | [standalone]


#1647686

FromKishon Vijay Abraham I <kishon@ti.com>
Date2017-05-23 08:50 +0200
Message-ID<tKbNM-7U4-13@gated-at.bofh.it>
In reply to#1647412
Hi Bjorn,

On Tuesday 23 May 2017 02:56 AM, Bjorn Helgaas wrote:
> 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?

right. CONFIG_PCI is for enabling the host infrastructure and PCI_ENDPOINT and
CONFIG_PCI should be completely independent of each other.

Thanks
Kishon

[toc] | [prev] | [next] | [standalone]


#1647718

FromGeert Uytterhoeven <geert@linux-m68k.org>
Date2017-05-23 09:20 +0200
Message-ID<tKcgO-8mw-33@gated-at.bofh.it>
In reply to#1647686
Hi Kishon,

On Tue, May 23, 2017 at 8:43 AM, Kishon Vijay Abraham I <kishon@ti.com> wrote:
> On Tuesday 23 May 2017 02:56 AM, Bjorn Helgaas wrote:
>> 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?
>
> right. CONFIG_PCI is for enabling the host infrastructure and PCI_ENDPOINT and
> CONFIG_PCI should be completely independent of each other.

OK, so HAS_DMA is the right dependency.
Thanks for confirming!

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web