Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755410AbbLAH4T (ORCPT ); Tue, 1 Dec 2015 02:56:19 -0500 Received: from mx2.suse.de ([195.135.220.15]:60719 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755329AbbLAHz7 (ORCPT ); Tue, 1 Dec 2015 02:55:59 -0500 Message-ID: <1448956437.27886.2.camel@suse.com> Subject: Re: [PATCH] usb: interface: allow drivers declare number of endpoints they need From: Oliver Neukum To: Greg Kroah-Hartman Cc: Dmitry Torokhov , Alan Stern , Felipe Balbi , Vladis Dronov , USB list , lkml Date: Tue, 01 Dec 2015 08:53:57 +0100 In-Reply-To: <20151201010909.GA13673@kroah.com> References: <20151130211150.GA38770@dtor-ws> <20151130221825.GA6426@kroah.com> <20151130233653.GB8414@kroah.com> <20151201010909.GA13673@kroah.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.12.11 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1106 Lines: 29 On Mon, 2015-11-30 at 17:09 -0800, Greg Kroah-Hartman wrote: > > that would loop through endpoints so that drivers do not have to > > open-code the loop and we indeed need to fix the drivers that > blindly > > grab endpoints at fixed offsets and expect them to be there and have > > correct types. > > Yes, that would work for one single type of endpoint, but lots of > drivers need/have 2 of the same type/direction, so what would this > function do then? Error out? Hm, that might work, and it would > reduce > a bunch of common code, care to make up a patch for that? Hi, in that case let us go the whole way. Give drivers a way to describe what they need that covers all possibilities up to exactly telling the core what it expects and in which order and numbers. Actually that would be better in the interface matching code path. Regards Oliver -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/