As a part of adding stream timeout timer for stream capable endpoints stream_capable flag is added into struct usb_ep. Replace the usage of dep->stream_capable in with usb_ep->stream_capable. Signed-off-by: Anurag Kumar Vulisha <anurag.kumar.vulisha@xxxxxxxxxx> --- Changes in v6: 1. This patch is newly added in this series --- drivers/usb/dwc3/core.h | 2 -- drivers/usb/dwc3/gadget.c | 6 +++--- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/drivers/usb/dwc3/core.h b/drivers/usb/dwc3/core.h index 5bfb625..89a2ee6 100644 --- a/drivers/usb/dwc3/core.h +++ b/drivers/usb/dwc3/core.h @@ -655,7 +655,6 @@ struct dwc3_event_buffer { * @interval: the interval on which the ISOC transfer is started * @name: a human readable name e.g. ep1out-bulk * @direction: true for TX, false for RX - * @stream_capable: true when streams are enabled */ struct dwc3_ep { struct usb_ep endpoint; @@ -704,7 +703,6 @@ struct dwc3_ep { char name[20]; unsigned direction:1; - unsigned stream_capable:1; }; enum dwc3_phy { diff --git a/drivers/usb/dwc3/gadget.c b/drivers/usb/dwc3/gadget.c index aab2970..ac752d4 100644 --- a/drivers/usb/dwc3/gadget.c +++ b/drivers/usb/dwc3/gadget.c @@ -572,7 +572,6 @@ static int dwc3_gadget_set_ep_config(struct dwc3_ep *dep, unsigned int action) if (usb_ss_max_streams(comp_desc) && usb_endpoint_xfer_bulk(desc)) { params.param1 |= DWC3_DEPCFG_STREAM_CAPABLE | DWC3_DEPCFG_STREAM_EVENT_EN; - dep->stream_capable = true; dep->endpoint.stream_capable = true; } @@ -740,7 +739,7 @@ static int __dwc3_gadget_ep_disable(struct dwc3_ep *dep) reg &= ~DWC3_DALEPENA_EP(dep->number); dwc3_writel(dwc->regs, DWC3_DALEPENA, reg); - dep->stream_capable = false; + dep->endpoint.stream_capable = false; dep->type = 0; dep->flags &= DWC3_EP_END_TRANSFER_PENDING; @@ -998,7 +997,8 @@ static void __dwc3_prepare_one_trb(struct dwc3_ep *dep, struct dwc3_trb *trb, if (chain) trb->ctrl |= DWC3_TRB_CTRL_CHN; - if (usb_endpoint_xfer_bulk(dep->endpoint.desc) && dep->stream_capable) + if (usb_endpoint_xfer_bulk(dep->endpoint.desc) && + dep->endpoint.stream_capable) trb->ctrl |= DWC3_TRB_CTRL_SID_SOFN(stream_id); trb->ctrl |= DWC3_TRB_CTRL_HWO; -- 2.1.1