xhci: dbc: Pass dbc pointer to get_in/out_ep() helper functions to get endpoints
Pass dbc pointer instead of struct xhci_hcd pointer to the get_in_ep() and get_out_ep() helper functions. No functional changes This change helps decoupling xhci and DbC Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Link: https://lore.kernel.org/r/20200723144530.9992-17-mathias.nyman@linux.intel.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:

committed by
Greg Kroah-Hartman

parent
b396fa39de
commit
91aaf97471
@@ -593,7 +593,7 @@ static void dbc_handle_xfer_event(struct xhci_dbc *dbc, union xhci_trb *event)
|
||||
remain_length = EVENT_TRB_LEN(le32_to_cpu(event->generic.field[2]));
|
||||
ep_id = TRB_TO_EP_ID(le32_to_cpu(event->generic.field[3]));
|
||||
dep = (ep_id == EPID_OUT) ?
|
||||
get_out_ep(xhci) : get_in_ep(xhci);
|
||||
get_out_ep(dbc) : get_in_ep(dbc);
|
||||
ring = dep->ring;
|
||||
|
||||
switch (comp_code) {
|
||||
@@ -710,12 +710,12 @@ static enum evtreturn xhci_dbc_do_handle_events(struct xhci_dbc *dbc)
|
||||
dbc->state = DS_STALLED;
|
||||
|
||||
if (ctrl & DBC_CTRL_HALT_IN_TR) {
|
||||
dep = get_in_ep(xhci);
|
||||
dep = get_in_ep(dbc);
|
||||
xhci_dbc_flush_endpoint_requests(dep);
|
||||
}
|
||||
|
||||
if (ctrl & DBC_CTRL_HALT_OUT_TR) {
|
||||
dep = get_out_ep(xhci);
|
||||
dep = get_out_ep(dbc);
|
||||
xhci_dbc_flush_endpoint_requests(dep);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user