* [PATCH 0/4] Support USB wakeup function for Tegra234
@ 2025-08-01 9:57 Haotien Hsu
2025-08-01 9:57 ` [PATCH 1/4] dt-bindings: usb: Add wake-up support for Tegra234 XUSB host controller Haotien Hsu
` (3 more replies)
0 siblings, 4 replies; 7+ messages in thread
From: Haotien Hsu @ 2025-08-01 9:57 UTC (permalink / raw)
To: Greg Kroah-Hartman, Rob Herring, Krzysztof Kozlowski,
Conor Dooley, Thierry Reding, Jonathan Hunter, Mathias Nyman,
Brad Griffis, Sumit Gupta, Vedant Deshpande, Akhil R, Jinjie Ruan,
linux-usb, devicetree, linux-tegra, linux-kernel
Cc: Haotien Hsu, Henry Lin, Jui Chang Kuo, Wayne Chang, WK Tsai
This patch series enables USB wakeup for Tegra234.
Haotien Hsu (4):
dt-bindings: usb: Add wake-up support for Tegra234 XUSB host
controller
arm64: tegra: Add interrupts for Tegra234 USB wake events
soc/tegra: pmc: Add USB wake events for Tegra234
usb: xhci: tegra: Support USB wakeup function for Tegra234
.../bindings/usb/nvidia,tegra234-xusb.yaml | 28 ++++++-
arch/arm64/boot/dts/nvidia/tegra234.dtsi | 11 ++-
drivers/soc/tegra/pmc.c | 7 ++
drivers/usb/host/xhci-tegra.c | 83 ++++++++++++++++++-
4 files changed, 123 insertions(+), 6 deletions(-)
--
2.34.1
^ permalink raw reply [flat|nested] 7+ messages in thread
* [PATCH 1/4] dt-bindings: usb: Add wake-up support for Tegra234 XUSB host controller
2025-08-01 9:57 [PATCH 0/4] Support USB wakeup function for Tegra234 Haotien Hsu
@ 2025-08-01 9:57 ` Haotien Hsu
2025-08-01 19:34 ` Conor Dooley
2025-08-01 9:57 ` [PATCH 2/4] arm64: tegra: Add interrupts for Tegra234 USB wake events Haotien Hsu
` (2 subsequent siblings)
3 siblings, 1 reply; 7+ messages in thread
From: Haotien Hsu @ 2025-08-01 9:57 UTC (permalink / raw)
To: Greg Kroah-Hartman, Rob Herring, Krzysztof Kozlowski,
Conor Dooley, Thierry Reding, Jonathan Hunter, Mathias Nyman,
Brad Griffis, Sumit Gupta, Vedant Deshpande, Akhil R, Jinjie Ruan,
linux-usb, devicetree, linux-tegra, linux-kernel
Cc: Haotien Hsu, Henry Lin, Jui Chang Kuo, Wayne Chang, WK Tsai
Populate USB wake events for Tegra234 XUSB host controller.
These wake-up events are optional to maintain backward compatibility and
because the USB controller does not require them for normal operation.
Signed-off-by: Haotien Hsu <haotienh@nvidia.com>
---
.../bindings/usb/nvidia,tegra234-xusb.yaml | 28 +++++++++++++++++--
1 file changed, 26 insertions(+), 2 deletions(-)
diff --git a/Documentation/devicetree/bindings/usb/nvidia,tegra234-xusb.yaml b/Documentation/devicetree/bindings/usb/nvidia,tegra234-xusb.yaml
index db761dcbf72a..6365c6647cd7 100644
--- a/Documentation/devicetree/bindings/usb/nvidia,tegra234-xusb.yaml
+++ b/Documentation/devicetree/bindings/usb/nvidia,tegra234-xusb.yaml
@@ -32,9 +32,32 @@ properties:
- const: bar2
interrupts:
+ minItems: 2
items:
- description: xHCI host interrupt
- description: mailbox interrupt
+ - description: USB wake event 0
+ - description: USB wake event 1
+ - description: USB wake event 2
+ - description: USB wake event 3
+ - description: USB wake event 4
+ - description: USB wake event 5
+ - description: USB wake event 6
+ description: |
+ The first two interrupts are required for the USB host controller. The remaining USB wake
+ event interrupts are optional. Each USB wake event is independent; it is not necessary to use
+ all of these events on a platform. The USB host controller can function even if no wake-up
+ events are defined. The USB wake event interrupts are handled by the Tegra PMC; hence, the
+ interrupt controller for these is the PMC and the interrupt IDs correspond to the PMC wake
+ event IDs. A complete list of wake event IDs is provided below, and this information is also
+ present in the Tegra TRM document.
+ PMC wake-up 76 for USB3 port 0 wakeup
+ PMC wake-up 77 for USB3 port 1 wakeup
+ PMC wake-up 78 for USB3 port 2 and port 3 wakeup
+ PMC wake-up 79 for USB2 port 0 wakeup
+ PMC wake-up 80 for USB2 port 1 wakeup
+ PMC wake-up 81 for USB2 port 2 wakeup
+ PMC wake-up 82 for USB2 port 3 wakeup
clocks:
items:
@@ -127,8 +150,9 @@ examples:
<0x03650000 0x10000>;
reg-names = "hcd", "fpci", "bar2";
- interrupts = <GIC_SPI 163 IRQ_TYPE_LEVEL_HIGH>,
- <GIC_SPI 164 IRQ_TYPE_LEVEL_HIGH>;
+ interrupts-extended = <&gic GIC_SPI 163 IRQ_TYPE_LEVEL_HIGH>,
+ <&gic GIC_SPI 164 IRQ_TYPE_LEVEL_HIGH>,
+ <&pmc 76 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&bpmp TEGRA234_CLK_XUSB_CORE_HOST>,
<&bpmp TEGRA234_CLK_XUSB_FALCON>,
--
2.34.1
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH 2/4] arm64: tegra: Add interrupts for Tegra234 USB wake events
2025-08-01 9:57 [PATCH 0/4] Support USB wakeup function for Tegra234 Haotien Hsu
2025-08-01 9:57 ` [PATCH 1/4] dt-bindings: usb: Add wake-up support for Tegra234 XUSB host controller Haotien Hsu
@ 2025-08-01 9:57 ` Haotien Hsu
2025-08-01 9:57 ` [PATCH 3/4] soc/tegra: pmc: Add USB wake events for Tegra234 Haotien Hsu
2025-08-01 9:57 ` [PATCH 4/4] usb: xhci: tegra: Support USB wakeup function " Haotien Hsu
3 siblings, 0 replies; 7+ messages in thread
From: Haotien Hsu @ 2025-08-01 9:57 UTC (permalink / raw)
To: Greg Kroah-Hartman, Rob Herring, Krzysztof Kozlowski,
Conor Dooley, Thierry Reding, Jonathan Hunter, Mathias Nyman,
Brad Griffis, Sumit Gupta, Vedant Deshpande, Akhil R, Jinjie Ruan,
linux-usb, devicetree, linux-tegra, linux-kernel
Cc: Haotien Hsu, Henry Lin, Jui Chang Kuo, Wayne Chang, WK Tsai
Add interrupts for Tegra234 USB wake events to support the USB wake-up
function.
Signed-off-by: Haotien Hsu <haotienh@nvidia.com>
---
arch/arm64/boot/dts/nvidia/tegra234.dtsi | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/arch/arm64/boot/dts/nvidia/tegra234.dtsi b/arch/arm64/boot/dts/nvidia/tegra234.dtsi
index 2601b43b2d8c..9cf573fed6cb 100644
--- a/arch/arm64/boot/dts/nvidia/tegra234.dtsi
+++ b/arch/arm64/boot/dts/nvidia/tegra234.dtsi
@@ -3254,8 +3254,15 @@ usb@3610000 {
<0x0 0x03650000 0x0 0x10000>;
reg-names = "hcd", "fpci", "bar2";
- interrupts = <GIC_SPI 163 IRQ_TYPE_LEVEL_HIGH>,
- <GIC_SPI 164 IRQ_TYPE_LEVEL_HIGH>;
+ interrupts-extended = <&gic GIC_SPI 163 IRQ_TYPE_LEVEL_HIGH>,
+ <&gic GIC_SPI 164 IRQ_TYPE_LEVEL_HIGH>,
+ <&pmc 76 IRQ_TYPE_LEVEL_HIGH>,
+ <&pmc 77 IRQ_TYPE_LEVEL_HIGH>,
+ <&pmc 78 IRQ_TYPE_LEVEL_HIGH>,
+ <&pmc 79 IRQ_TYPE_LEVEL_HIGH>,
+ <&pmc 80 IRQ_TYPE_LEVEL_HIGH>,
+ <&pmc 81 IRQ_TYPE_LEVEL_HIGH>,
+ <&pmc 82 IRQ_TYPE_LEVEL_HIGH>;
clocks = <&bpmp TEGRA234_CLK_XUSB_CORE_HOST>,
<&bpmp TEGRA234_CLK_XUSB_FALCON>,
--
2.34.1
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH 3/4] soc/tegra: pmc: Add USB wake events for Tegra234
2025-08-01 9:57 [PATCH 0/4] Support USB wakeup function for Tegra234 Haotien Hsu
2025-08-01 9:57 ` [PATCH 1/4] dt-bindings: usb: Add wake-up support for Tegra234 XUSB host controller Haotien Hsu
2025-08-01 9:57 ` [PATCH 2/4] arm64: tegra: Add interrupts for Tegra234 USB wake events Haotien Hsu
@ 2025-08-01 9:57 ` Haotien Hsu
2025-08-01 9:57 ` [PATCH 4/4] usb: xhci: tegra: Support USB wakeup function " Haotien Hsu
3 siblings, 0 replies; 7+ messages in thread
From: Haotien Hsu @ 2025-08-01 9:57 UTC (permalink / raw)
To: Greg Kroah-Hartman, Rob Herring, Krzysztof Kozlowski,
Conor Dooley, Thierry Reding, Jonathan Hunter, Mathias Nyman,
Brad Griffis, Sumit Gupta, Vedant Deshpande, Akhil R, Jinjie Ruan,
linux-usb, devicetree, linux-tegra, linux-kernel
Cc: Haotien Hsu, Henry Lin, Jui Chang Kuo, Wayne Chang, WK Tsai
Add USB wake events for Tegra234 so that system can be woken up from
suspend when USB devices hot-plug/unplug event is detected.
Signed-off-by: Haotien Hsu <haotienh@nvidia.com>
---
drivers/soc/tegra/pmc.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/drivers/soc/tegra/pmc.c b/drivers/soc/tegra/pmc.c
index 51b9d852bb6a..bf3a46e24aa3 100644
--- a/drivers/soc/tegra/pmc.c
+++ b/drivers/soc/tegra/pmc.c
@@ -4209,6 +4209,13 @@ static const struct tegra_wake_event tegra234_wake_events[] = {
TEGRA_WAKE_GPIO("power", 29, 1, TEGRA234_AON_GPIO(EE, 4)),
TEGRA_WAKE_GPIO("mgbe", 56, 0, TEGRA234_MAIN_GPIO(Y, 3)),
TEGRA_WAKE_IRQ("rtc", 73, 10),
+ TEGRA_WAKE_IRQ("usb3-port-0", 76, 167),
+ TEGRA_WAKE_IRQ("usb3-port-1", 77, 167),
+ TEGRA_WAKE_IRQ("usb3-port-2-3", 78, 167),
+ TEGRA_WAKE_IRQ("usb2-port-0", 79, 167),
+ TEGRA_WAKE_IRQ("usb2-port-1", 80, 167),
+ TEGRA_WAKE_IRQ("usb2-port-2", 81, 167),
+ TEGRA_WAKE_IRQ("usb2-port-3", 82, 167),
TEGRA_WAKE_IRQ("sw-wake", SW_WAKE_ID, 179),
};
--
2.34.1
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH 4/4] usb: xhci: tegra: Support USB wakeup function for Tegra234
2025-08-01 9:57 [PATCH 0/4] Support USB wakeup function for Tegra234 Haotien Hsu
` (2 preceding siblings ...)
2025-08-01 9:57 ` [PATCH 3/4] soc/tegra: pmc: Add USB wake events for Tegra234 Haotien Hsu
@ 2025-08-01 9:57 ` Haotien Hsu
2025-08-02 5:30 ` kernel test robot
3 siblings, 1 reply; 7+ messages in thread
From: Haotien Hsu @ 2025-08-01 9:57 UTC (permalink / raw)
To: Greg Kroah-Hartman, Rob Herring, Krzysztof Kozlowski,
Conor Dooley, Thierry Reding, Jonathan Hunter, Mathias Nyman,
Brad Griffis, Sumit Gupta, Vedant Deshpande, Akhil R, Jinjie Ruan,
linux-usb, devicetree, linux-tegra, linux-kernel
Cc: Haotien Hsu, Henry Lin, Jui Chang Kuo, Wayne Chang, WK Tsai
When the system is suspended, USB hot-plugging/unplugging can trigger
wake events of the Tegra USB host controller.
Enable support for USB wake-up events by parsing device-tree to see if
the interrupts for the wake-up events are present and if so configure
those interrupts. Note that if wake-up events are not present, still
allow the USB host controller to probe as normal.
Signed-off-by: Haotien Hsu <haotienh@nvidia.com>
---
drivers/usb/host/xhci-tegra.c | 83 ++++++++++++++++++++++++++++++++++-
1 file changed, 81 insertions(+), 2 deletions(-)
diff --git a/drivers/usb/host/xhci-tegra.c b/drivers/usb/host/xhci-tegra.c
index b5c362c2051d..0a3ac770ab4f 100644
--- a/drivers/usb/host/xhci-tegra.c
+++ b/drivers/usb/host/xhci-tegra.c
@@ -155,6 +155,8 @@
#define FW_IOCTL_TYPE_SHIFT 24
#define FW_IOCTL_CFGTBL_READ 17
+#define WAKE_IRQ_START_INDEX 2
+
struct tegra_xusb_fw_header {
__le32 boot_loadaddr_in_imem;
__le32 boot_codedfi_offset;
@@ -228,6 +230,7 @@ struct tegra_xusb_soc {
unsigned int num_supplies;
const struct tegra_xusb_phy_type *phy_types;
unsigned int num_types;
+ unsigned int max_num_wakes;
const struct tegra_xusb_context_soc *context;
struct {
@@ -263,6 +266,7 @@ struct tegra_xusb {
int xhci_irq;
int mbox_irq;
int padctl_irq;
+ int *wake_irqs;
void __iomem *ipfs_base;
void __iomem *fpci_base;
@@ -313,6 +317,7 @@ struct tegra_xusb {
bool suspended;
struct tegra_xusb_context context;
u8 lp0_utmi_pad_mask;
+ int num_wakes;
};
static struct hc_driver __read_mostly tegra_xhci_hc_driver;
@@ -1534,6 +1539,58 @@ static void tegra_xusb_deinit_usb_phy(struct tegra_xusb *tegra)
otg_set_host(tegra->usbphy[i]->otg, NULL);
}
+static int tegra_xusb_setup_wakeup(struct platform_device *pdev, struct tegra_xusb *tegra)
+{
+ unsigned int i;
+
+ if (tegra->soc->max_num_wakes == 0)
+ return 0;
+
+ tegra->wake_irqs = devm_kcalloc(tegra->dev,
+ tegra->soc->max_num_wakes,
+ sizeof(*tegra->wake_irqs), GFP_KERNEL);
+ if (!tegra->wake_irqs)
+ return -ENOMEM;
+
+ /*
+ * USB wake events are independent of each other, so it is not necessary for a platform
+ * to utilize all wake-up events supported for a given device. The USB host can operate
+ * even if wake-up events are not defined or fail to be configured. Therefore, we only
+ * return critical errors, such as -ENOMEM.
+ */
+ for (i = 0; i < tegra->soc->max_num_wakes; i++) {
+ struct irq_data *data;
+
+ tegra->wake_irqs[i] = platform_get_irq(pdev, i + WAKE_IRQ_START_INDEX);
+ if (tegra->wake_irqs[i] < 0)
+ break;
+
+ data = irq_get_irq_data(tegra->wake_irqs[i]);
+ if (!data) {
+ dev_warn(tegra->dev, "get wake event %d irq data fail\n", i);
+ irq_dispose_mapping(tegra->wake_irqs[i]);
+ break;
+ }
+
+ irq_set_irq_type(tegra->wake_irqs[i], irqd_get_trigger_type(data));
+ }
+
+ tegra->num_wakes = i;
+ dev_dbg(tegra->dev, "setup %d wake events\n", tegra->num_wakes);
+
+ return 0;
+}
+
+static void tegra_xusb_dispose_wake(struct tegra_xusb *tegra)
+{
+ unsigned int i;
+
+ for (i = 0; i < tegra->num_wakes; i++)
+ irq_dispose_mapping(tegra->wake_irqs[i]);
+
+ tegra->num_wakes = 0;
+}
+
static int tegra_xusb_probe(struct platform_device *pdev)
{
struct tegra_xusb *tegra;
@@ -1584,9 +1641,15 @@ static int tegra_xusb_probe(struct platform_device *pdev)
if (tegra->mbox_irq < 0)
return tegra->mbox_irq;
+ err = tegra_xusb_setup_wakeup(pdev, tegra);
+ if (err)
+ return err;
+
tegra->padctl = tegra_xusb_padctl_get(&pdev->dev);
- if (IS_ERR(tegra->padctl))
- return PTR_ERR(tegra->padctl);
+ if (IS_ERR(tegra->padctl)) {
+ err = PTR_ERR(tegra->padctl);
+ goto dispose_wake;
+ }
np = of_parse_phandle(pdev->dev.of_node, "nvidia,xusb-padctl", 0);
if (!np) {
@@ -1910,6 +1973,8 @@ static int tegra_xusb_probe(struct platform_device *pdev)
put_padctl:
of_node_put(np);
tegra_xusb_padctl_put(tegra->padctl);
+dispose_wake:
+ tegra_xusb_dispose_wake(tegra);
return err;
}
@@ -1926,6 +1991,7 @@ static void tegra_xusb_remove(struct platform_device *pdev)
{
struct tegra_xusb *tegra = platform_get_drvdata(pdev);
struct xhci_hcd *xhci = hcd_to_xhci(tegra->hcd);
+ unsigned int i;
tegra_xusb_deinit_usb_phy(tegra);
@@ -1942,6 +2008,8 @@ static void tegra_xusb_remove(struct platform_device *pdev)
if (tegra->padctl_irq)
pm_runtime_disable(&pdev->dev);
+ tegra_xusb_dispose_wake(tegra);
+
pm_runtime_put(&pdev->dev);
tegra_xusb_disable(tegra);
@@ -2352,8 +2420,13 @@ static __maybe_unused int tegra_xusb_suspend(struct device *dev)
pm_runtime_disable(dev);
if (device_may_wakeup(dev)) {
+ unsigned int i;
+
if (enable_irq_wake(tegra->padctl_irq))
dev_err(dev, "failed to enable padctl wakes\n");
+
+ for (i = 0; i < tegra->num_wakes; i++)
+ enable_irq_wake(tegra->wake_irqs[i]);
}
}
@@ -2381,8 +2454,13 @@ static __maybe_unused int tegra_xusb_resume(struct device *dev)
}
if (device_may_wakeup(dev)) {
+ unsigned int i;
+
if (disable_irq_wake(tegra->padctl_irq))
dev_err(dev, "failed to disable padctl wakes\n");
+
+ for (i = 0; i < tegra->num_wakes; i++)
+ disable_irq_wake(tegra->wake_irqs[i]);
}
tegra->suspended = false;
mutex_unlock(&tegra->lock);
@@ -2633,6 +2711,7 @@ static const struct tegra_xusb_soc tegra234_soc = {
.num_supplies = ARRAY_SIZE(tegra194_supply_names),
.phy_types = tegra194_phy_types,
.num_types = ARRAY_SIZE(tegra194_phy_types),
+ .max_num_wakes = 7,
.context = &tegra186_xusb_context,
.ports = {
.usb3 = { .offset = 0, .count = 4, },
--
2.34.1
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH 1/4] dt-bindings: usb: Add wake-up support for Tegra234 XUSB host controller
2025-08-01 9:57 ` [PATCH 1/4] dt-bindings: usb: Add wake-up support for Tegra234 XUSB host controller Haotien Hsu
@ 2025-08-01 19:34 ` Conor Dooley
0 siblings, 0 replies; 7+ messages in thread
From: Conor Dooley @ 2025-08-01 19:34 UTC (permalink / raw)
To: Haotien Hsu
Cc: Greg Kroah-Hartman, Rob Herring, Krzysztof Kozlowski,
Conor Dooley, Thierry Reding, Jonathan Hunter, Mathias Nyman,
Brad Griffis, Sumit Gupta, Vedant Deshpande, Akhil R, Jinjie Ruan,
linux-usb, devicetree, linux-tegra, linux-kernel, Henry Lin,
Jui Chang Kuo, Wayne Chang, WK Tsai
[-- Attachment #1: Type: text/plain, Size: 386 bytes --]
On Fri, Aug 01, 2025 at 05:57:45PM +0800, Haotien Hsu wrote:
> Populate USB wake events for Tegra234 XUSB host controller.
> These wake-up events are optional to maintain backward compatibility and
> because the USB controller does not require them for normal operation.
>
> Signed-off-by: Haotien Hsu <haotienh@nvidia.com>
Acked-by: Conor Dooley <conor.dooley@microchip.com>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH 4/4] usb: xhci: tegra: Support USB wakeup function for Tegra234
2025-08-01 9:57 ` [PATCH 4/4] usb: xhci: tegra: Support USB wakeup function " Haotien Hsu
@ 2025-08-02 5:30 ` kernel test robot
0 siblings, 0 replies; 7+ messages in thread
From: kernel test robot @ 2025-08-02 5:30 UTC (permalink / raw)
To: Haotien Hsu, Greg Kroah-Hartman, Rob Herring, Krzysztof Kozlowski,
Conor Dooley, Thierry Reding, Jonathan Hunter, Mathias Nyman,
Brad Griffis, Sumit Gupta, Vedant Deshpande, Akhil R, Jinjie Ruan,
linux-usb, devicetree, linux-tegra, linux-kernel
Cc: llvm, oe-kbuild-all, Haotien Hsu, Henry Lin, Jui Chang Kuo,
Wayne Chang, WK Tsai
Hi Haotien,
kernel test robot noticed the following build warnings:
[auto build test WARNING on robh/for-next]
[also build test WARNING on usb/usb-testing usb/usb-next usb/usb-linus tegra/for-next linus/master v6.16 next-20250801]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Haotien-Hsu/dt-bindings-usb-Add-wake-up-support-for-Tegra234-XUSB-host-controller/20250801-180040
base: https://git.kernel.org/pub/scm/linux/kernel/git/robh/linux.git for-next
patch link: https://lore.kernel.org/r/20250801095748.385437-5-haotienh%40nvidia.com
patch subject: [PATCH 4/4] usb: xhci: tegra: Support USB wakeup function for Tegra234
config: arm-defconfig (https://download.01.org/0day-ci/archive/20250802/202508021305.3ENY5oQC-lkp@intel.com/config)
compiler: clang version 22.0.0git (https://github.com/llvm/llvm-project 8f09b03aebb71c154f3bbe725c29e3f47d37c26e)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250802/202508021305.3ENY5oQC-lkp@intel.com/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202508021305.3ENY5oQC-lkp@intel.com/
All warnings (new ones prefixed by >>):
>> drivers/usb/host/xhci-tegra.c:1997:15: warning: unused variable 'i' [-Wunused-variable]
1997 | unsigned int i;
| ^
1 warning generated.
vim +/i +1997 drivers/usb/host/xhci-tegra.c
1992
1993 static void tegra_xusb_remove(struct platform_device *pdev)
1994 {
1995 struct tegra_xusb *tegra = platform_get_drvdata(pdev);
1996 struct xhci_hcd *xhci = hcd_to_xhci(tegra->hcd);
> 1997 unsigned int i;
1998
1999 tegra_xusb_deinit_usb_phy(tegra);
2000
2001 pm_runtime_get_sync(&pdev->dev);
2002 usb_remove_hcd(xhci->shared_hcd);
2003 usb_put_hcd(xhci->shared_hcd);
2004 xhci->shared_hcd = NULL;
2005 usb_remove_hcd(tegra->hcd);
2006 usb_put_hcd(tegra->hcd);
2007
2008 dma_free_coherent(&pdev->dev, tegra->fw.size, tegra->fw.virt,
2009 tegra->fw.phys);
2010
2011 if (tegra->padctl_irq)
2012 pm_runtime_disable(&pdev->dev);
2013
2014 tegra_xusb_dispose_wake(tegra);
2015
2016 pm_runtime_put(&pdev->dev);
2017
2018 tegra_xusb_disable(tegra);
2019 tegra_xusb_padctl_put(tegra->padctl);
2020 }
2021
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2025-08-02 5:31 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-01 9:57 [PATCH 0/4] Support USB wakeup function for Tegra234 Haotien Hsu
2025-08-01 9:57 ` [PATCH 1/4] dt-bindings: usb: Add wake-up support for Tegra234 XUSB host controller Haotien Hsu
2025-08-01 19:34 ` Conor Dooley
2025-08-01 9:57 ` [PATCH 2/4] arm64: tegra: Add interrupts for Tegra234 USB wake events Haotien Hsu
2025-08-01 9:57 ` [PATCH 3/4] soc/tegra: pmc: Add USB wake events for Tegra234 Haotien Hsu
2025-08-01 9:57 ` [PATCH 4/4] usb: xhci: tegra: Support USB wakeup function " Haotien Hsu
2025-08-02 5:30 ` kernel test robot
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).