mirror of
https://github.com/torvalds/linux.git
synced 2026-04-28 19:42:31 -04:00
TC9563 is a PCIe switch that has one upstream and three downstream ports. One of the downstream ports is connected to an integrated ethernet MAC endpoint. The other two downstream ports are available to connect to external devices. One Host can connect to TC9563 by upstream port. The TC9563 switch needs to be configured after powering on and before the PCIe link is up. The PCIe controller driver already enables link training at the host side even before this driver probe happens. Due to this, when driver enables power to the switch, it participates in link training and the PCIe link may come up before configuring the switch through I2C. Once the link is up the configuration done through I2C will not have any effect. To prevent the host from participating in link training, disable link training on the host side to ensure the link does not come up before the switch is configured via I2C. Based on DT property and type of the port, TC9563 is configured through I2C. Signed-off-by: Krishna Chaitanya Chundru <krishna.chundru@oss.qualcomm.com> [bhelgaas: squash fixes from https://lore.kernel.org/r/20251120065116.13647-2-mani@kernel.org https://lore.kernel.org/r/20251120065116.13647-3-mani@kernel.org] Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Reviewed-by: Bjorn Andersson <andersson@kernel.org> Reviewed-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org> Reviewed-by: Manivannan Sadhasivam <mani@kernel.org> Link: https://patch.msgid.link/20251101-tc9563-v9-6-de3429f7787a@oss.qualcomm.com
49 lines
1.3 KiB
Plaintext
49 lines
1.3 KiB
Plaintext
# SPDX-License-Identifier: GPL-2.0-only
|
|
|
|
config HAVE_PWRCTRL
|
|
bool
|
|
|
|
config PCI_PWRCTRL
|
|
tristate
|
|
|
|
config PCI_PWRCTRL_PWRSEQ
|
|
tristate
|
|
select POWER_SEQUENCING
|
|
select PCI_PWRCTRL
|
|
|
|
config PCI_PWRCTRL_SLOT
|
|
tristate "PCI Power Control driver for PCI slots"
|
|
select PCI_PWRCTRL
|
|
help
|
|
Say Y here to enable the PCI Power Control driver to control the power
|
|
state of PCI slots.
|
|
|
|
This is a generic driver that controls the power state of different
|
|
PCI slots. The voltage regulators powering the rails of the PCI slots
|
|
are expected to be defined in the devicetree node of the PCI bridge.
|
|
|
|
config PCI_PWRCTRL_TC9563
|
|
tristate "PCI Power Control driver for TC9563 PCIe switch"
|
|
select PCI_PWRCTRL
|
|
default m if ARCH_QCOM
|
|
depends on I2C
|
|
help
|
|
Say Y here to enable the PCI Power Control driver of TC9563 PCIe
|
|
switch.
|
|
|
|
This driver enables power and configures the TC9563 PCIe switch
|
|
through i2c. TC9563 is a PCIe switch which has one upstream and three
|
|
downstream ports. To one of the downstream ports integrated ethernet
|
|
MAC is connected as endpoint device. Other two downstream ports are
|
|
supposed to connect to external device.
|
|
|
|
# deprecated
|
|
config HAVE_PWRCTL
|
|
bool
|
|
select HAVE_PWRCTRL
|
|
|
|
# deprecated
|
|
config PCI_PWRCTL_PWRSEQ
|
|
tristate
|
|
select PCI_PWRCTRL_PWRSEQ
|