public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] usb: xhci: save hcd_priv memory of shared_hcd
@ 2022-05-19  2:17 Tao Wang
  2022-05-19  3:43 ` kernel test robot
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Tao Wang @ 2022-05-19  2:17 UTC (permalink / raw)
  To: Mathias Nyman, Greg Kroah-Hartman, open list:USB XHCI DRIVER,
	open list
  Cc: quic_wat

The shared_hcd->hcd_priv is not used in xhci, so not
need to malloc hcd priv memory for shared_hcd.

Signed-off-by: Tao Wang <quic_wat@quicinc.com>
---
 drivers/usb/host/xhci-plat.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/drivers/usb/host/xhci-plat.c b/drivers/usb/host/xhci-plat.c
index 01dcfd7..a27dd3a 100644
--- a/drivers/usb/host/xhci-plat.c
+++ b/drivers/usb/host/xhci-plat.c
@@ -336,6 +336,11 @@ static int xhci_plat_probe(struct platform_device *pdev)
 	device_set_wakeup_capable(&pdev->dev, true);
 
 	xhci->main_hcd = hcd;
+	/*
+	 * The shared_hcd->hcd_priv is not used in xhci,
+	 * so not need to malloc hcd priv memory for shared_hcd.
+	 */
+	driver->hcd_priv_size = 0;
 	xhci->shared_hcd = __usb_create_hcd(driver, sysdev, &pdev->dev,
 			dev_name(&pdev->dev), hcd);
 	if (!xhci->shared_hcd) {
-- 
2.7.4


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-05-19 16:54 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-05-19  2:17 [PATCH] usb: xhci: save hcd_priv memory of shared_hcd Tao Wang
2022-05-19  3:43 ` kernel test robot
2022-05-19  7:47 ` Mathias Nyman
2022-05-19 16:53 ` 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