]> www.infradead.org Git - users/jedix/linux-maple.git/commit
usb: xhci: rework xhci_link_segments()
authorNiklas Neronin <niklas.neronin@linux.intel.com>
Wed, 6 Nov 2024 10:14:41 +0000 (12:14 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 6 Nov 2024 12:26:15 +0000 (13:26 +0100)
commit90e91ccbdd0018481624d24a0e1b7528797ac2c7
tree6be25d394ae94565ca9d7552eac616d6f10aff4e
parentfe688e5006133b2609c136f599e120a95cc450cb
usb: xhci: rework xhci_link_segments()

Prepare for splitting ring segments allocation and initialization by
reworking the xhci_link_segments() function. Segment linking and ring type
checks are moved out of xhci_link_segments(), and the function is renamed
to "xhci_set_link_trb()".

The goal is to keep ring linking within xhci_alloc_segments_for_ring() and
move initialization into a separate function.

Additionally, reorder and simplify xhci_set_link_trb() for better
readability.

Signed-off-by: Niklas Neronin <niklas.neronin@linux.intel.com>
Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com>
Link: https://lore.kernel.org/r/20241106101459.775897-16-mathias.nyman@linux.intel.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/host/xhci-mem.c