All of lore.kernel.org
 help / color / mirror / Atom feed
From: Punit Agrawal <punitagrawal@gmail.com>
To: lorenzo.pieralisi@arm.com, bhelgaas@google.com
Cc: Punit Agrawal <punitagrawal@gmail.com>,
	robh@kernel.org, kw@linux.com, linux-pci@vger.kernel.org,
	linux-kernel@vger.kernel.org, shawn.lin@rock-chips.com,
	linux-rockchip@lists.infradead.org
Subject: [PATCH] PCI: rockchip: Enable the phy driver when controller is enabled
Date: Tue, 19 Oct 2021 21:02:15 +0900	[thread overview]
Message-ID: <20211019120215.793794-1-punitagrawal@gmail.com> (raw)

The PCI controller on rk3399 requires the phy to correctly initialise
the PCIE phy. Without phy initialisation the host and end-point
controllers cannot be used.

To prevent building an unusable PCIe driver on rk3399, enable the phy
driver when the host or end-point driver is enabled.

Signed-off-by: Punit Agrawal <punitagrawal@gmail.com>
---
Hi,

I've been caught out many times when booting off of PCI and finding
that the kernel cannot find rootfs due to the missing phy driver. The
patch should prevents this by fixing the Kconfig dependency
enablement. 

Thanks,
Punit

 drivers/pci/controller/Kconfig | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/pci/controller/Kconfig b/drivers/pci/controller/Kconfig
index 326f7d13024f..1965df38c4a3 100644
--- a/drivers/pci/controller/Kconfig
+++ b/drivers/pci/controller/Kconfig
@@ -214,6 +214,7 @@ config PCIE_ROCKCHIP_HOST
 	depends on PCI_MSI_IRQ_DOMAIN
 	select MFD_SYSCON
 	select PCIE_ROCKCHIP
+	select PHY_ROCKCHIP_PCIE
 	help
 	  Say Y here if you want internal PCI support on Rockchip SoC.
 	  There is 1 internal PCIe port available to support GEN2 with
@@ -226,6 +227,7 @@ config PCIE_ROCKCHIP_EP
 	depends on PCI_ENDPOINT
 	select MFD_SYSCON
 	select PCIE_ROCKCHIP
+	select PHY_ROCKCHIP_PCIE
 	help
 	  Say Y here if you want to support Rockchip PCIe controller in
 	  endpoint mode on Rockchip SoC. There is 1 internal PCIe port
-- 
2.33.0


WARNING: multiple messages have this Message-ID (diff)
From: Punit Agrawal <punitagrawal@gmail.com>
To: lorenzo.pieralisi@arm.com, bhelgaas@google.com
Cc: Punit Agrawal <punitagrawal@gmail.com>,
	robh@kernel.org, kw@linux.com, linux-pci@vger.kernel.org,
	linux-kernel@vger.kernel.org, shawn.lin@rock-chips.com,
	linux-rockchip@lists.infradead.org
Subject: [PATCH] PCI: rockchip: Enable the phy driver when controller is enabled
Date: Tue, 19 Oct 2021 21:02:15 +0900	[thread overview]
Message-ID: <20211019120215.793794-1-punitagrawal@gmail.com> (raw)

The PCI controller on rk3399 requires the phy to correctly initialise
the PCIE phy. Without phy initialisation the host and end-point
controllers cannot be used.

To prevent building an unusable PCIe driver on rk3399, enable the phy
driver when the host or end-point driver is enabled.

Signed-off-by: Punit Agrawal <punitagrawal@gmail.com>
---
Hi,

I've been caught out many times when booting off of PCI and finding
that the kernel cannot find rootfs due to the missing phy driver. The
patch should prevents this by fixing the Kconfig dependency
enablement. 

Thanks,
Punit

 drivers/pci/controller/Kconfig | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/pci/controller/Kconfig b/drivers/pci/controller/Kconfig
index 326f7d13024f..1965df38c4a3 100644
--- a/drivers/pci/controller/Kconfig
+++ b/drivers/pci/controller/Kconfig
@@ -214,6 +214,7 @@ config PCIE_ROCKCHIP_HOST
 	depends on PCI_MSI_IRQ_DOMAIN
 	select MFD_SYSCON
 	select PCIE_ROCKCHIP
+	select PHY_ROCKCHIP_PCIE
 	help
 	  Say Y here if you want internal PCI support on Rockchip SoC.
 	  There is 1 internal PCIe port available to support GEN2 with
@@ -226,6 +227,7 @@ config PCIE_ROCKCHIP_EP
 	depends on PCI_ENDPOINT
 	select MFD_SYSCON
 	select PCIE_ROCKCHIP
+	select PHY_ROCKCHIP_PCIE
 	help
 	  Say Y here if you want to support Rockchip PCIe controller in
 	  endpoint mode on Rockchip SoC. There is 1 internal PCIe port
-- 
2.33.0


_______________________________________________
Linux-rockchip mailing list
Linux-rockchip@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-rockchip

             reply	other threads:[~2021-10-19 12:02 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-19 12:02 Punit Agrawal [this message]
2021-10-19 12:02 ` [PATCH] PCI: rockchip: Enable the phy driver when controller is enabled Punit Agrawal
2022-04-08 14:18 ` Lorenzo Pieralisi
2022-04-08 14:18   ` Lorenzo Pieralisi

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=20211019120215.793794-1-punitagrawal@gmail.com \
    --to=punitagrawal@gmail.com \
    --cc=bhelgaas@google.com \
    --cc=kw@linux.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=linux-rockchip@lists.infradead.org \
    --cc=lorenzo.pieralisi@arm.com \
    --cc=robh@kernel.org \
    --cc=shawn.lin@rock-chips.com \
    /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.