lkml.org 
[lkml]   [2018]   [Aug]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH 3/6] usb: xhci-mtk: fix ISOC error when interval is zero
    Date
    If the interval equal zero, needn't round up to power of two
    for the number of packets in each ESIT, so fix it.

    Signed-off-by: Chunfeng Yun <chunfeng.yun@mediatek.com>
    ---
    drivers/usb/host/xhci-mtk-sch.c | 4 +++-
    1 file changed, 3 insertions(+), 1 deletion(-)

    diff --git a/drivers/usb/host/xhci-mtk-sch.c b/drivers/usb/host/xhci-mtk-sch.c
    index 46fe0a2..057f453 100644
    --- a/drivers/usb/host/xhci-mtk-sch.c
    +++ b/drivers/usb/host/xhci-mtk-sch.c
    @@ -126,7 +126,9 @@ static void setup_sch_info(struct usb_device *udev,
    }

    if (ep_type == ISOC_IN_EP || ep_type == ISOC_OUT_EP) {
    - if (esit_pkts <= sch_ep->esit)
    + if (sch_ep->esit == 1)
    + sch_ep->pkts = esit_pkts;
    + else if (esit_pkts <= sch_ep->esit)
    sch_ep->pkts = 1;
    else
    sch_ep->pkts = roundup_pow_of_two(esit_pkts)
    --
    1.9.1
    \
     
     \ /
      Last update: 2018-08-29 04:57    [W:3.067 / U:0.236 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site