From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.3 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_2 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 94389C3A59D for ; Thu, 22 Aug 2019 05:48:51 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 73314233A1 for ; Thu, 22 Aug 2019 05:48:51 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731395AbfHVFsv (ORCPT ); Thu, 22 Aug 2019 01:48:51 -0400 Received: from gate.crashing.org ([63.228.1.57]:34919 "EHLO gate.crashing.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731379AbfHVFsu (ORCPT ); Thu, 22 Aug 2019 01:48:50 -0400 Received: from localhost (localhost.localdomain [127.0.0.1]) by gate.crashing.org (8.14.1/8.14.1) with ESMTP id x7M5mgda024745; Thu, 22 Aug 2019 00:48:44 -0500 Message-ID: <1b385c4a779b0d6722e74894aec0ba0a3855c72f.camel@kernel.crashing.org> Subject: Re: f_mass_storage vs drivers/target From: Benjamin Herrenschmidt To: Alan Stern Cc: USB list , Sebastian Andrzej Siewior Date: Thu, 22 Aug 2019 15:48:42 +1000 In-Reply-To: <4c8a9941fb54dffd823335c9f4bc01f3158fb1d5.camel@kernel.crashing.org> References: <9c7090713374e80b6c26a9dabb753c5b35b9c93d.camel@kernel.crashing.org> <4c8a9941fb54dffd823335c9f4bc01f3158fb1d5.camel@kernel.crashing.org> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.28.5-0ubuntu0.18.04.1 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-usb-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-usb@vger.kernel.org On Thu, 2019-08-22 at 15:14 +1000, Benjamin Herrenschmidt wrote: > - No UDC driver other than dummy sets max_streams, and f_tcm requires 4, > so f_tcm will fail with *any* superspeed UDC driver as far as I can tell. > > Was it ever tested with USB 3 ? Ok so I spoke too soon... dwc3 does, I didn't notice bcs it doesn't live in drivers/usb/gadget... So Sebastian, what would be the best way to "fallback" to non-stream use rather than just fail probing ? Do we really want the autoconf EP matching to enforce the stream numbers ? If we allow it to not match, then f_tcm could check after matching if enough streams were found and disable stream support if not. Another option would be to make this 2-pass, though that complicates even more: a first pass where we enforce the stream count, and if we fail, a second pass where we ignore them. Suggestions ? Cheers, Ben.