From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 467AA272E44; Thu, 10 Jul 2025 14:27:02 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1752157623; cv=none; b=lmyTzZTgADXlNHEH3e56C57EOn4I0qMBVL5kqQI/Xad0ABjb2brWiEM3d2QxQSKC1TgbyUaZy0IF3oeVzqpI2Qs3jy7HOHiW6d2eGclOJemm2zWhR1pFP9v3gMfi3JCZJ7jnl+8joZuWZG5RwBlCRzdwWqXmiFVVkIjAL+nM6WU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1752157623; c=relaxed/simple; bh=Lp0YKCDEbOTykxsN9b7ISwn3sIb0ktutrPOjgADtWTo=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=mY4QL8YoWrSxKxe4jIAuzRpmokqrOZ4GflKeFffEvJ8uIHyjbeG9tvwzclrC/Yd8GbYR24GwgsIJ8VGE3rIcfjhFpqkcGc6PVVAJiY1602isAvAz8FehkFG9S3fQ2COMfEx3q891tgfj5WPj8f9R+4DuIhCYO/FNgkIakemFGBM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=sUFAYUfs; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="sUFAYUfs" Received: by smtp.kernel.org (Postfix) with ESMTPSA id CE687C4CEE3; Thu, 10 Jul 2025 14:27:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1752157622; bh=Lp0YKCDEbOTykxsN9b7ISwn3sIb0ktutrPOjgADtWTo=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=sUFAYUfs+dQsYzEFb4sR6gIxcqKZVzRQ/A0iSgpF4lSWWIhnM9cREvEsr4Mt8C8Jd YFhgYhAGdxo5WyS/33r3fYg1ZXqSnrEw+ZKGTw5DA93cGRmTuifePdfIWiShqsT51E WTvbkOiGJWR53vS9fcFX+Dx60WACbt2noQxtmEZ/l2TJCQoSCLEMc4p+48kCdtGguj BWYyvhMiBimhWkBWB5dvY5WglYBDCudet8N2FIO/MTOwAx3eoKhp52kw7XVwKk06K1 ZHTYbhjow1GgDk2Sz+TIur3ilq7tGw626x6MKDLmyMv2pRIqz14Uxj/fLG85N5FkkN T7hchzHvKTMdg== Received: from johan by xi.lan with local (Exim 4.97.1) (envelope-from ) id 1uZsEi-000000005Bb-2yia; Thu, 10 Jul 2025 16:26:56 +0200 Date: Thu, 10 Jul 2025 16:26:56 +0200 From: Johan Hovold To: Fabio Porcedda Cc: Greg Kroah-Hartman , linux-usb@vger.kernel.org, Daniele Palmas , stable@vger.kernel.org Subject: Re: [PATCH] USB: serial: option: add Telit Cinterion FE910C04 (ECM) composition Message-ID: References: <20250708120004.100254-1-fabio.porcedda@gmail.com> Precedence: bulk X-Mailing-List: linux-usb@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: On Wed, Jul 09, 2025 at 12:50:27PM +0200, Fabio Porcedda wrote: > Il giorno mer 9 lug 2025 alle ore 12:08 Johan Hovold > ha scritto: > > > > On Tue, Jul 08, 2025 at 02:00:04PM +0200, Fabio Porcedda wrote: > > > Add Telit Cinterion FE910C04 (ECM) composition: > > > 0x10c7: ECM + tty (AT) + tty (AT) + tty (diag) > > > /* Interface does not support modem-control requests */ > > > #define NCTRL(ifnum) ((BIT(ifnum) & 0xff) << 8) > > > +#define NCTRL_ALL (0xff << 8) > > > + { USB_DEVICE_AND_INTERFACE_INFO(TELIT_VENDOR_ID, 0x10c7, 0xff, 0xff, 0x30), /* Telit FE910C04 (ECM) */ > > > + .driver_info = NCTRL_ALL }, > > > > Please just use NCTRL(4) here. (And remember to mention additions like > > this in the commit message in the future.) > > Ok, I will send a v2. > > > Or do you have reasons to believe the interface numbering may change? Or > > is it just to avoid matching on both number and protocol? > > The interface number should not change, it's just to have a more > generic definition that matches also other pids for the same soc. I > think it's easier to write and less error prone because the interface > number changes based on the PID. Yeah, I can see it having some merit. Maybe I reacted to the naming as I at first incorrectly read it as no interface supporting the control request (perhaps naming it "NCTRL_ANY" would have avoided this). But for consistency I think we can continue using the interface numbers until we have some better abstraction for these that can be used to avoid also the explicit per protocol entries. Johan