Received: by 2002:ac0:a5b6:0:0:0:0:0 with SMTP id m51-v6csp4183690imm; Wed, 30 May 2018 00:17:38 -0700 (PDT) X-Google-Smtp-Source: ADUXVKIx86VGgw48EMf/rW2afdXQ0sTMWMG8mQUUg+lnnq8QOmBDCY0rtJgJ6zMnPR84vRIA6x8m X-Received: by 2002:a62:c4dd:: with SMTP id h90-v6mr1701526pfk.86.1527664658502; Wed, 30 May 2018 00:17:38 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1527664658; cv=none; d=google.com; s=arc-20160816; b=BrwEG4gcWWTlwPE8omfTJvL3M1vY2WnEqQvtEJBhE/nbPNLs5/MaAj/MjxPiS/Iqsy YtBNENj2dWZXeHl/MqG/DF/2ktlVYXEkqwYSfE+cWpLyO+glBcMigqk5J19Ryo3fc3k3 zN+RBe2RbKZ8MCjVj8jqs5c1oCbjWAsfEhpmlgaD3h2FllF4mXcVXrEQ753tsIP5myYM 72zjHfQFR9boE8t1Y4s/3bLTIZ5cc6z+Zd8axaO68O8YcOqQGoCXdNPtVlp9CXc7aHNM ynfU/VmATFPmuykw3fcDEUbyL7aEzLpPeWkvQxRWMoCU6vbvoKEw7nLpUdBpQZzbrz4e iLGA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :content-language:accept-language:references:message-id:date :thread-index:thread-topic:subject:cc:to:from:dkim-signature :arc-authentication-results; bh=IjCOK7kD6LXvhFoXaujdb3+72Ue1PAkNgw5ZZAUuG1Y=; b=jzBpwzYJt1G1sM+np2bgfBhRkhTo66GrdPraODWVKx2FOVmrmGXbn6nH646isMkvXr nw1+OfOWhDSWl33Pn+U5SWgQ5UA2RIkrtV7zluTCx41kcKaspb5iK130y9rReZHxQgb0 ThU/AHdNra1ho4WEhJ/Ka2XHQgeB0nWVz/DcRkGTt12dopzmFbnMxiehWJcbGtm2fGWi oSlyYJtzDyLbfBBTP/lJZTjJgptAvwzbjbaMJtstI+OdGPPGnPQ69t1HqMEt5ZZ7Awtm nRUNYj7JMdkwYgE0uB90tg1rkkOs25LcCHrHaXNoDRy4xsrUFP0lTkXAs5iCaSVpK3r3 OS6w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@synopsys.com header.s=mail header.b=doJR+qtA; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=synopsys.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a12-v6si27000508pgw.578.2018.05.30.00.17.24; Wed, 30 May 2018 00:17:38 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@synopsys.com header.s=mail header.b=doJR+qtA; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=synopsys.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S937267AbeE3HQq (ORCPT + 99 others); Wed, 30 May 2018 03:16:46 -0400 Received: from smtprelay6.synopsys.com ([198.182.37.59]:59419 "EHLO smtprelay.synopsys.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S937196AbeE3HQm (ORCPT ); Wed, 30 May 2018 03:16:42 -0400 Received: from mailhost.synopsys.com (mailhost3.synopsys.com [10.12.238.238]) by smtprelay.synopsys.com (Postfix) with ESMTP id 77E7F1E05E0; Wed, 30 May 2018 09:16:40 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=synopsys.com; s=mail; t=1527664600; bh=aIzMlRwK9UH5PUI2uC84gHBLYk2xmkS9ncNib/pJH1U=; h=From:To:CC:Subject:Date:References:From; b=doJR+qtA60BYBCiY9p+hFwp2VCy4DUFm4JJvMZKeDsoCYxcI79bdDUvSCQ0EiEoyF b3xcs8oQuE6YX/4eS9pK/Jk26ZoFtw3iJjVMaEekkDkRUKdWWqyIiOtdQeGeCCUQqn 9Lzssd6ytKGNbiqPTXExuO7mH9qwL0rgjnWIGaMDX+BWToHEw3zvN/vBFS2hD0YY0q 0MUpXmjlJH3TxAlErF2UC1bujAS1smrBjZnVWG90r56YShs0Ua1JOkf5/7vctXyo1y BBY7V+etLnqqXeZgXIeSb74SB5RaP2fVrwEthAd7KJPigpGkGrRuRTJJNH9bNSZDT7 53Pfna157+9lg== Received: from US01WXQAHTC1.internal.synopsys.com (us01wxqahtc1.internal.synopsys.com [10.12.238.230]) by mailhost.synopsys.com (Postfix) with ESMTP id C1CBC3C16; Wed, 30 May 2018 00:16:39 -0700 (PDT) Received: from AM04WEHTCB.internal.synopsys.com (10.116.16.192) by US01WXQAHTC1.internal.synopsys.com (10.12.238.230) with Microsoft SMTP Server (TLS) id 14.3.361.1; Wed, 30 May 2018 00:16:39 -0700 Received: from AM04WEMBXA.internal.synopsys.com ([fe80::79c3:55f2:1f20:5bf4]) by am04wehtcb.internal.synopsys.com ([::1]) with mapi id 14.03.0361.001; Wed, 30 May 2018 11:16:36 +0400 From: Minas Harutyunyan To: Zeng Tao , "Minas.Harutyunyan@synopsys.com" CC: Greg Kroah-Hartman , "linux-usb@vger.kernel.org" , "linux-kernel@vger.kernel.org" Subject: Re: [PATCH] usb: dwc2: gadget: fix missing process for isoc descriptor dma mode Thread-Topic: [PATCH] usb: dwc2: gadget: fix missing process for isoc descriptor dma mode Thread-Index: AQHT99RV+ygzxPGq9EKuFvTgIUAiiA== Date: Wed, 30 May 2018 07:16:36 +0000 Message-ID: <410670D7E743164D87FA6160E7907A56013A59784A@am04wembxa.internal.synopsys.com> References: <1527681676-44003-1-git-send-email-prime.zeng@hisilicon.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.116.70.165] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Zeng Tao,=0A= =0A= On 5/30/2018 9:09 AM, Zeng Tao wrote:=0A= > If it's the first request to queue, and we are using descriptor dma mode= =0A= > for isoc transfer, we only need to add the request to the queue, and it= =0A= > will be processed in the future nak interrupt handler.=0A= > =0A= > Signed-off-by: Zeng Tao =0A= > ---=0A= > drivers/usb/dwc2/gadget.c | 3 +++=0A= > 1 file changed, 3 insertions(+)=0A= > =0A= > diff --git a/drivers/usb/dwc2/gadget.c b/drivers/usb/dwc2/gadget.c=0A= > index f0d9ccf..48e3a48c 100644=0A= > --- a/drivers/usb/dwc2/gadget.c=0A= > +++ b/drivers/usb/dwc2/gadget.c=0A= > @@ -1365,6 +1365,9 @@ static int dwc2_hsotg_ep_queue(struct usb_ep *ep, s= truct usb_request *req,=0A= > return 0;=0A= > }=0A= > =0A= > + if (using_desc_dma(hs))=0A= > + return 0;=0A= > +=0A= > /* Update current frame number value. */=0A= > hs->frame_number =3D dwc2_hsotg_read_frameno(hs);=0A= > while (dwc2_gadget_target_frame_elapsed(hs_ep)) {=0A= > =0A= =0A= Actually it considered in "[PATCH] usb: dwc2: Change ISOC DDMA flow" =0A= before checking is this request first or no:=0A= =0A= + if (using_desc_dma(hs) && hs_ep->isochronous) {=0A= + if (hs_ep->target_frame !=3D TARGET_FRAME_INITIAL) {=0A= + dwc2_gadget_fill_isoc_desc(hs_ep, hs_req->req.dma,=0A= + hs_req->req.length);=0A= + }=0A= return 0;=0A= }=0A= =0A= =0A= Thanks,=0A= Minas=0A=