From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from devils.ext.ti.com ([198.47.26.153]:56472 "EHLO devils.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932384AbbJNScQ (ORCPT ); Wed, 14 Oct 2015 14:32:16 -0400 From: Felipe Balbi To: Alan Stern , Jassi Brar CC: Jaswinder Singh , "linux-usb@vger.kernel.org" , Subject: Re: [PATCH] usb: gadget: function: acm: return zlp for OUT setup In-Reply-To: References: Date: Wed, 14 Oct 2015 13:32:09 -0500 Message-ID: <87y4f59u8m.fsf@saruman.tx.rr.com> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha1; protocol="application/pgp-signature" Sender: stable-owner@vger.kernel.org List-ID: --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Hi, Alan Stern writes: > On Wed, 14 Oct 2015, Jassi Brar wrote: > >> BTW, should the gadget stack ever queue a Non-ZLP as reply to some >> setup request that has USB_DIR_IN not set? > > Yes. If USB_DIR_IN is not set then the control transfer is OUT, so the > gadget needs to queue a request to receive some data from the host.=20=20 > That request will obviously need to be a non-ZLP. In fact, it's hard > to think of a situation where a gadget would ever want to submit a > zero-length OUT request. Isn't the UDC driver supposed to handle the > status stage of a control-IN transfer automatically? yes and no. :-) If USB_GADGET_DELAYED_STATUS is returned, we need to wait for the gadget driver to queue a request. =2D-=20 balbi --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAEBAgAGBQJWHp+rAAoJEIaOsuA1yqRERIQP/jillWaHgnrVa2dU0qjMBT8G utLGL5zMtHNEW69Pvp4+fOI5SErLSwcPZUKXinMAZnTcI0EP2gM6MlghsgQPB+fp ZfyQNkyyydvCrtpgNOLaSWXw+jF17Nq/ncJE+7zaiMmJCjn8abOJGSWybkGT8T8W tiMf2+K4opIIjiGvY+131hp+ronSe0Rd0Gyx6hqbuXSrVNZC4CuZ6QPvrPJ5ld/K 3tRNGyuueBoKTCzRLVZOqRmYyrJ/ELWwN2Un2mji7utlY9KvqTHD93rgDaecNd6K ezZKVtwr6YGsSdVBXRosUe0atSHPJdP2Xk7kmI6N02D9BC9p1J4ytNoarzviYnus yZy179uR7dtnBK68kFu3OfKAt2VZtx5Azz7AQI6AUT3UmMCnRJDy4YwcIWvQ0nep Bdqs2OOuIRLMTCg44HJ9lp+DNxCL6Cr/Ff/QOjmYqMEiyQiQRqgInkuJYx8B4A7D 10jl1xcuohZt/UVF6PhjYAeOm79RW8ealVNWyrTReyu6Q0ajllhNzjoe4E3OxHAu tBErqc8xdzCb5vR2jCnGGbTiGQgE2I8Ev01DcpjCOjfTE+lcRuOyH3ZnAuvFypHd F+kNvIPaodt8BrMPrvLJOCc7PZk8K24PFBKU5aM6aNxzS8xbbgrd3/Xv0GdUGegK m4tkLNNHOqxS8QQ1bJG9 =iw0V -----END PGP SIGNATURE----- --=-=-=--