Skip to content

Commit

Permalink
xhci: dbc: Improve performance by removing delay in transfer event po…
Browse files Browse the repository at this point in the history
…lling.

[ Upstream commit 03e3d9c ]

Queue event polling work with 0 delay in case there are pending transfers
queued up. This is part 2 of a 3 part series that roughly triples dbc
performace when using adb push and pull over dbc.

Max/min push rate after patches is 210/118 MB/s, pull rate 171/133 MB/s,
tested with large files (300MB-9GB) by Łukasz Bartosik

First performance improvement patch was commit 31128e7
("xhci: dbc: add dbgtty request to end of list once it completes")

Cc: Łukasz Bartosik <ukaszb@chromium.org>
Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com>
Link: https://lore.kernel.org/r/20241227120142.1035206-2-mathias.nyman@linux.intel.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Stable-dep-of: cab6393 ("xhci: dbc: Avoid event polling busyloop if pending rx transfers are inactive.")
Signed-off-by: Sasha Levin <sashal@kernel.org>
  • Loading branch information
Mathias Nyman authored and Greg Kroah-Hartman committed May 22, 2025
1 parent 5d9d623 commit 651eaaa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/usb/host/xhci-dbgcap.c
Original file line number Diff line number Diff line change
Expand Up @@ -954,7 +954,7 @@ static void xhci_dbc_handle_events(struct work_struct *work)
/* set fast poll rate if there are pending data transfers */
if (!list_empty(&dbc->eps[BULK_OUT].list_pending) ||
!list_empty(&dbc->eps[BULK_IN].list_pending))
poll_interval = 1;
poll_interval = 0;
break;
default:
dev_info(dbc->dev, "stop handling dbc events\n");
Expand Down

0 comments on commit 651eaaa

Please sign in to comment.