From: Wei-Cheng Chen <weichengc@nvidia.com>
To: <mathias.nyman@intel.com>, <gregkh@linuxfoundation.org>,
<thierry.reding@gmail.com>, <jonathanh@nvidia.com>
Cc: <waynec@nvidia.com>, <linux-usb@vger.kernel.org>,
<linux-tegra@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
Wei-Cheng Chen <weichengc@nvidia.com>
Subject: [PATCH] usb: host: tegra: Remove manual wake IRQ disposal
Date: Thu, 15 Jan 2026 18:36:21 +0800 [thread overview]
Message-ID: <20260115103621.587366-1-weichengc@nvidia.com> (raw)
From: Wayne Chang <waynec@nvidia.com>
We found that calling irq_dispose_mapping() caused a kernel warning
when removing the driver. The IRQs are obtained using
platform_get_irq(), which returns a Linux virtual IRQ number directly
managed by the device core, not by the OF subsystem. Therefore, the
driver should not call irq_dispose_mapping() for these IRQs.
Fixes: 5df186e2ef11 ("usb: xhci: tegra: Support USB wakeup function for Tegra234")
Cc: stable@vger.kernel.org
Signed-off-by: Wayne Chang <waynec@nvidia.com>
Signed-off-by: Wei-Cheng Chen <weichengc@nvidia.com>
---
drivers/usb/host/xhci-tegra.c | 21 ++-------------------
1 file changed, 2 insertions(+), 19 deletions(-)
diff --git a/drivers/usb/host/xhci-tegra.c b/drivers/usb/host/xhci-tegra.c
index 31ccced5125..2fab3c49e52 100644
--- a/drivers/usb/host/xhci-tegra.c
+++ b/drivers/usb/host/xhci-tegra.c
@@ -1570,7 +1570,6 @@ static int tegra_xusb_setup_wakeup(struct platform_device *pdev, struct tegra_xu
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;
}
@@ -1583,16 +1582,6 @@ static int tegra_xusb_setup_wakeup(struct platform_device *pdev, struct tegra_xu
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;
@@ -1648,10 +1637,8 @@ static int tegra_xusb_probe(struct platform_device *pdev)
return err;
tegra->padctl = tegra_xusb_padctl_get(&pdev->dev);
- if (IS_ERR(tegra->padctl)) {
- err = PTR_ERR(tegra->padctl);
- goto dispose_wake;
- }
+ if (IS_ERR(tegra->padctl))
+ return PTR_ERR(tegra->padctl);
np = of_parse_phandle(pdev->dev.of_node, "nvidia,xusb-padctl", 0);
if (!np) {
@@ -1975,8 +1962,6 @@ 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;
}
@@ -2009,8 +1994,6 @@ 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);
--
2.43.0
reply other threads:[~2026-01-15 10:36 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20260115103621.587366-1-weichengc@nvidia.com \
--to=weichengc@nvidia.com \
--cc=gregkh@linuxfoundation.org \
--cc=jonathanh@nvidia.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-tegra@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=mathias.nyman@intel.com \
--cc=thierry.reding@gmail.com \
--cc=waynec@nvidia.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®