diff mbox

[5/6] arm64, defconfig: Enable PCI

Message ID 1411573068-12952-6-git-send-email-rric@kernel.org (mailing list archive)
State New, archived
Delegated to: Bjorn Helgaas
Headers show

Commit Message

Robert Richter Sept. 24, 2014, 3:37 p.m. UTC
From: Robert Richter <rrichter@cavium.com>

Enable the PCI subsystem in defconfig. There will be more and more
systems with pci support, so default enable it. This also implicitly
enables the MSI feature.

Signed-off-by: Robert Richter <rrichter@cavium.com>
---
 arch/arm64/Kconfig | 4 ++++
 1 file changed, 4 insertions(+)

Comments

Arnd Bergmann Sept. 24, 2014, 4:14 p.m. UTC | #1
On Wednesday 24 September 2014 17:37:47 Robert Richter wrote:
>  config PCI
>         bool "PCI support"
> +       default y
>         help
>           This feature enables support for PCIe bus system. If you say Y
>           here, the kernel will include drivers and infrastructure code
>           to support PCIe bus devices.
>  
> +config PCI_MSI
> +       def_bool PCI
> +
>  config PCI_DOMAINS
>         def_bool PCI

There is already a PCI_MSI symbol in drivers/pci/Kconfig. Just select that
from the PCI symbol above rather than defining a second one.

	Arnd
--
To unsubscribe from this list: send the line "unsubscribe linux-pci" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Robert Richter Sept. 24, 2014, 4:26 p.m. UTC | #2
On 24.09.14 18:14:11, Arnd Bergmann wrote:
> On Wednesday 24 September 2014 17:37:47 Robert Richter wrote:
> >  config PCI
> >         bool "PCI support"
> > +       default y
> >         help
> >           This feature enables support for PCIe bus system. If you say Y
> >           here, the kernel will include drivers and infrastructure code
> >           to support PCIe bus devices.
> >  
> > +config PCI_MSI
> > +       def_bool PCI
> > +
> >  config PCI_DOMAINS
> >         def_bool PCI
> 
> There is already a PCI_MSI symbol in drivers/pci/Kconfig. Just select that
> from the PCI symbol above rather than defining a second one.

The intention is not to have a second definition, instead this should
enable the default value just for arm64. Thus I put it to
arch/arm64/Kconfig. Otherwise it would be enabled per default on all
archs.

We could have used select in config ARM64, but I tried to avoid using
select due to the dependency issue and instead implement this with
default-y/depends-on. Doing so it can be manually disabled too.

-Robert
--
To unsubscribe from this list: send the line "unsubscribe linux-pci" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Catalin Marinas Sept. 24, 2014, 5:10 p.m. UTC | #3
On Wed, Sep 24, 2014 at 05:26:31PM +0100, Robert Richter wrote:
> On 24.09.14 18:14:11, Arnd Bergmann wrote:
> > On Wednesday 24 September 2014 17:37:47 Robert Richter wrote:
> > >  config PCI
> > >         bool "PCI support"
> > > +       default y
> > >         help
> > >           This feature enables support for PCIe bus system. If you say Y
> > >           here, the kernel will include drivers and infrastructure code
> > >           to support PCIe bus devices.
> > >  
> > > +config PCI_MSI
> > > +       def_bool PCI
> > > +
> > >  config PCI_DOMAINS
> > >         def_bool PCI
> > 
> > There is already a PCI_MSI symbol in drivers/pci/Kconfig. Just select that
> > from the PCI symbol above rather than defining a second one.
> 
> The intention is not to have a second definition, instead this should
> enable the default value just for arm64. Thus I put it to
> arch/arm64/Kconfig. Otherwise it would be enabled per default on all
> archs.
> 
> We could have used select in config ARM64, but I tried to avoid using
> select due to the dependency issue and instead implement this with
> default-y/depends-on. Doing so it can be manually disabled too.

It may be better to simply set PCI and PCI_MSI as defaults in defconfig
rather than "default y" and an additional config PCI_MSI entry.
Arnd Bergmann Sept. 24, 2014, 6:40 p.m. UTC | #4
On Wednesday 24 September 2014 18:10:48 Catalin Marinas wrote:
> On Wed, Sep 24, 2014 at 05:26:31PM +0100, Robert Richter wrote:
> > On 24.09.14 18:14:11, Arnd Bergmann wrote:
> > > On Wednesday 24 September 2014 17:37:47 Robert Richter wrote:
> > > >  config PCI
> > > >         bool "PCI support"
> > > > +       default y
> > > >         help
> > > >           This feature enables support for PCIe bus system. If you say Y
> > > >           here, the kernel will include drivers and infrastructure code
> > > >           to support PCIe bus devices.
> > > >  
> > > > +config PCI_MSI
> > > > +       def_bool PCI
> > > > +
> > > >  config PCI_DOMAINS
> > > >         def_bool PCI
> > > 
> > > There is already a PCI_MSI symbol in drivers/pci/Kconfig. Just select that
> > > from the PCI symbol above rather than defining a second one.
> > 
> > The intention is not to have a second definition, instead this should
> > enable the default value just for arm64. Thus I put it to
> > arch/arm64/Kconfig. Otherwise it would be enabled per default on all
> > archs.

I don't think other architectures actually see the PCI symbol that is
defined in the arm64 Kconfig file, but I might be wrong.

> > We could have used select in config ARM64, but I tried to avoid using
> > select due to the dependency issue and instead implement this with
> > default-y/depends-on. Doing so it can be manually disabled too.

How about adding a new symbol like

config ARM64_PCI
	def_bool PCI
	select PCI_MSI


> It may be better to simply set PCI and PCI_MSI as defaults in defconfig
> rather than "default y" and an additional config PCI_MSI entry.

Selecting PCI_MSI unconditionally seems fine to me. We won't have any
ARM64 systems that only do classic PCI, and MSI is mandatory for PCIe.

	Arnd
--
To unsubscribe from this list: send the line "unsubscribe linux-pci" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Catalin Marinas Sept. 25, 2014, 9:35 a.m. UTC | #5
On Wed, Sep 24, 2014 at 07:40:18PM +0100, Arnd Bergmann wrote:
> On Wednesday 24 September 2014 18:10:48 Catalin Marinas wrote:
> > On Wed, Sep 24, 2014 at 05:26:31PM +0100, Robert Richter wrote:
> > > On 24.09.14 18:14:11, Arnd Bergmann wrote:
> > > > On Wednesday 24 September 2014 17:37:47 Robert Richter wrote:
> > > > >  config PCI
> > > > >         bool "PCI support"
> > > > > +       default y
> > > > >         help
> > > > >           This feature enables support for PCIe bus system. If you say Y
> > > > >           here, the kernel will include drivers and infrastructure code
> > > > >           to support PCIe bus devices.
> > > > >  
> > > > > +config PCI_MSI
> > > > > +       def_bool PCI
> > > > > +
> > > > >  config PCI_DOMAINS
> > > > >         def_bool PCI
> > > > 
> > > > There is already a PCI_MSI symbol in drivers/pci/Kconfig. Just select that
> > > > from the PCI symbol above rather than defining a second one.
> > > 
> > > The intention is not to have a second definition, instead this should
> > > enable the default value just for arm64. Thus I put it to
> > > arch/arm64/Kconfig. Otherwise it would be enabled per default on all
> > > archs.
> 
> I don't think other architectures actually see the PCI symbol that is
> defined in the arm64 Kconfig file, but I might be wrong.

Other archs wouldn't see the symbols in arch/arm64/Kconfig.

> > > We could have used select in config ARM64, but I tried to avoid using
> > > select due to the dependency issue and instead implement this with
> > > default-y/depends-on. Doing so it can be manually disabled too.
> 
> How about adding a new symbol like
> 
> config ARM64_PCI
> 	def_bool PCI
> 	select PCI_MSI

How is this different from just selecting PCI_MSI in config PCI in
arch/arm64/Kconfig? I don't see what another symbol brings.

> > It may be better to simply set PCI and PCI_MSI as defaults in defconfig
> > rather than "default y" and an additional config PCI_MSI entry.
> 
> Selecting PCI_MSI unconditionally seems fine to me. We won't have any
> ARM64 systems that only do classic PCI, and MSI is mandatory for PCIe.

OK then, we can go with a select.
Arnd Bergmann Sept. 25, 2014, 10:45 a.m. UTC | #6
On Thursday 25 September 2014 10:35:45 Catalin Marinas wrote:
> On Wed, Sep 24, 2014 at 07:40:18PM +0100, Arnd Bergmann wrote:
> > On Wednesday 24 September 2014 18:10:48 Catalin Marinas wrote:
> > > > The intention is not to have a second definition, instead this should
> > > > enable the default value just for arm64. Thus I put it to
> > > > arch/arm64/Kconfig. Otherwise it would be enabled per default on all
> > > > archs.
> > 
> > I don't think other architectures actually see the PCI symbol that is
> > defined in the arm64 Kconfig file, but I might be wrong.
> 
> Other archs wouldn't see the symbols in arch/arm64/Kconfig.

Ok.

> > > > We could have used select in config ARM64, but I tried to avoid using
> > > > select due to the dependency issue and instead implement this with
> > > > default-y/depends-on. Doing so it can be manually disabled too.
> > 
> > How about adding a new symbol like
> > 
> > config ARM64_PCI
> >       def_bool PCI
> >       select PCI_MSI
> 
> How is this different from just selecting PCI_MSI in config PCI in
> arch/arm64/Kconfig? I don't see what another symbol brings.

That suggestion was just in case I was wrong above. If the symbol
is indeed hidden elsewhere, we don't need it.

	Arnd
--
To unsubscribe from this list: send the line "unsubscribe linux-pci" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/arch/arm64/Kconfig b/arch/arm64/Kconfig
index ca3f7e9afd4d..97777e1ef5a7 100644
--- a/arch/arm64/Kconfig
+++ b/arch/arm64/Kconfig
@@ -163,11 +163,15 @@  config ARM_AMBA
 
 config PCI
 	bool "PCI support"
+	default y
 	help
 	  This feature enables support for PCIe bus system. If you say Y
 	  here, the kernel will include drivers and infrastructure code
 	  to support PCIe bus devices.
 
+config PCI_MSI
+	def_bool PCI
+
 config PCI_DOMAINS
 	def_bool PCI