From owner-freebsd-arm@freebsd.org Sun Sep 17 08:59:06 2017 Return-Path: Delivered-To: freebsd-arm@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 54E7DE048C1 for ; Sun, 17 Sep 2017 08:59:06 +0000 (UTC) (envelope-from hps@selasky.org) Received: from mail.turbocat.net (turbocat.net [88.99.82.50]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 1A83777BDC for ; Sun, 17 Sep 2017 08:59:05 +0000 (UTC) (envelope-from hps@selasky.org) Received: from hps2016.home.selasky.org (unknown [62.141.129.119]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.turbocat.net (Postfix) with ESMTPSA id 077582606E1; Sun, 17 Sep 2017 10:58:56 +0200 (CEST) Subject: Re: Part of why Pine64+ 2GB gets "uhub_attach: getting USB 2.0 HUB descriptor failed,error=USB_ERR_SHORT_XFER" (and so USB fails) To: Mark Millard , freebsd-arm References: From: Hans Petter Selasky Message-ID: <46d91194-84ff-50e3-97e6-6f9cef3ea2e7@selasky.org> Date: Sun, 17 Sep 2017 10:56:27 +0200 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 17 Sep 2017 08:59:06 -0000 On 09/17/17 10:09, Mark Millard wrote: > . . . > uint16_t length; > uint16_t temp; > . . . > length = UGETW(req->wLength); > . . . > USB_BUS_LOCK(udev->bus); > err = (hr_func) (udev, req, &desc, &temp); > USB_BUS_UNLOCK(udev->bus); > > if (err) > goto done; > > if (length > temp) { > if (!(flags & USB_SHORT_XFER_OK)) { > err = USB_ERR_SHORT_XFER; > goto done; > } > length = temp; > } Can you dump the length arguments. Usually short transfer means that the descriptor was shorter than expected. --HPS