From patchwork Wed Jan 17 15:43:25 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Aur=C3=A9lien_Jacobs?= X-Patchwork-Id: 13521901 Received: from smtpfb2-g21.free.fr (smtpfb2-g21.free.fr [212.27.42.10]) by smtp.subspace.kernel.org (Postfix) with ESMTP id BF1A82231F for ; Wed, 17 Jan 2024 15:50:53 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=212.27.42.10 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705506658; cv=none; b=DgfW//Jm+0kY03Zkj6JoX6BFZ/8VvIRtEmvRmLxh4fP1NRBUtPS/VwNw79OBca2u1y4ZGDV5ia6No+cazFVJox2+qsa9cSsOwq+g8G0FtjDZwngnaYB/0i5qBqBpAJxaJlAYRG0XvvmflrEJRIxkyxG46JeJZKW+8XnUNld2JbE= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705506658; c=relaxed/simple; bh=6rVBPkC7a4myX6xI1N8A+w5+ks+zPFqaZq2WipELt2s=; h=Received:Received:Date:DKIM-Signature:From:Subject:To:Cc: Message-Id:MIME-Version:Content-Type:Content-Transfer-Encoding; b=KQey0yhKtP00BH1RF0UStS0fo5DKPuEPApHrKBuzhh0ZxW19RD8q5IM+M+EaUcV9Diywc0GIK2mNWEAw7HWhzShpIDXt8K5oTX4+cHBRv9/e9J64LGM9tiLscc6IMrzj+xyyM3ehwe0bMJpxIo+qOHynxFmXujpnHXVojhTZ/gg= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=gnuage.org; spf=fail smtp.mailfrom=gnuage.org; dkim=pass (2048-bit key) header.d=gnuage.org header.i=@gnuage.org header.b=giJAti83; arc=none smtp.client-ip=212.27.42.10 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=gnuage.org Authentication-Results: smtp.subspace.kernel.org; spf=fail smtp.mailfrom=gnuage.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gnuage.org header.i=@gnuage.org header.b="giJAti83" Received: from smtp1-g21.free.fr (smtp1-g21.free.fr [212.27.42.1]) by smtpfb2-g21.free.fr (Postfix) with ESMTP id 907F54D80E for ; Wed, 17 Jan 2024 16:43:44 +0100 (CET) Received: from mail.gnuage.org (unknown [82.64.106.216]) by smtp1-g21.free.fr (Postfix) with ESMTPS id F1E56B00596; Wed, 17 Jan 2024 16:43:35 +0100 (CET) Date: Wed, 17 Jan 2024 16:43:25 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gnuage.org; s=2021; t=1705506214; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=j1/SPoY++DW/AOUd9EYM/1r2CpJFcZH42Ao8yHwCMM4=; b=giJAti83p6W4rOzwJ5l0nc3dYPmOgfBNe4sBLOmXymzZcgRBu+Hv454C5PuZrOLsSdQl/q nF9tJq84QQEZFTKRsZtJMxnUp4q4tW4DZiGX0/dUNhkrhahzDGOLqRorN/5apMNP8Jq04r E4mVTyE11bf5l/CNNhcpQ1FVrf6uzKvvGuuVybFlPfRreofY36yGtatP7kr+1kylK58VMG DxaztlkENk7gxja+f+WAYUR614u6BvrQhBQC58XUnVCUTbaEKr1mHVPG/glUVJs8IiufrF fN3hpC+PbcqD0OrG+vLfNYWapYm0Fll6XygyCzLW+QVN4xPtejWstcEF6k5GGw== Authentication-Results: ORIGINATING; auth=pass smtp.auth=aurel@gnuage.org smtp.mailfrom=aurel@gnuage.org From: =?iso-8859-1?q?Aur=E9lien?= Jacobs Subject: [PATCH] USB: serial: option: add MeiG Smart SLM320 product To: Johan Hovold Cc: linux-usb@vger.kernel.org, =?iso-8859-1?q?Aur=E9lien?= Jacobs Message-Id: Precedence: bulk X-Mailing-List: linux-usb@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Update the USB serial option driver to support MeiG Smart SLM320. ID 2dee:4d41 UNISOC UNISOC-8910 T: Bus=01 Lev=01 Prnt=01 Port=00 Cnt=01 Dev#= 9 Spd=480 MxCh= 0 D: Ver= 2.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS=64 #Cfgs= 1 P: Vendor=2dee ProdID=4d41 Rev=00.00 S: Manufacturer=UNISOC S: Product=UNISOC-8910 C: #Ifs= 8 Cfg#= 1 Atr=e0 MxPwr=400mA I: If#= 0 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option E: Ad=01(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms E: Ad=81(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms I: If#= 1 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option E: Ad=02(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms E: Ad=82(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms I: If#= 2 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option E: Ad=03(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms E: Ad=83(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms I: If#= 3 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option E: Ad=04(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms E: Ad=84(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms I: If#= 4 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option E: Ad=05(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms E: Ad=85(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms I: If#= 5 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option E: Ad=06(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms E: Ad=86(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms I: If#= 6 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option E: Ad=07(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms E: Ad=87(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms I: If#= 7 Alt= 0 #EPs= 2 Cls=ff(vend.) Sub=00 Prot=00 Driver=option E: Ad=08(O) Atr=02(Bulk) MxPS= 512 Ivl=0ms E: Ad=88(I) Atr=02(Bulk) MxPS= 512 Ivl=0ms Tested successfully a PPP LTE connection using If#= 0. Not sure of the purpose of every other serial interfaces. Signed-off-by: Aurélien Jacobs --- drivers/usb/serial/option.c | 6 ++++++ 1 file changed, 6 insertions(+) /* Highest interface number which can be used with NCTRL() and RSVD() */ @@ -2281,6 +2286,7 @@ static const struct usb_device_id option_ids[] = { { USB_DEVICE_AND_INTERFACE_INFO(SIERRA_VENDOR_ID, SIERRA_PRODUCT_EM9191, 0xff, 0, 0) }, { USB_DEVICE_AND_INTERFACE_INFO(UNISOC_VENDOR_ID, TOZED_PRODUCT_LT70C, 0xff, 0, 0) }, { USB_DEVICE_AND_INTERFACE_INFO(UNISOC_VENDOR_ID, LUAT_PRODUCT_AIR720U, 0xff, 0, 0) }, + { USB_DEVICE_AND_INTERFACE_INFO(MEIGSMART_VENDOR_ID, MEIGSMART_PRODUCT_SLM320, 0xff, 0, 0) }, { } /* Terminating entry */ }; MODULE_DEVICE_TABLE(usb, option_ids); diff --git a/drivers/usb/serial/option.c b/drivers/usb/serial/option.c index 72390dbf0769..b5468f51e0f8 100644 --- a/drivers/usb/serial/option.c +++ b/drivers/usb/serial/option.c @@ -613,6 +613,11 @@ static void option_instat_callback(struct urb *urb); /* Luat Air72*U series based on UNISOC UIS8910 uses UNISOC's vendor ID */ #define LUAT_PRODUCT_AIR720U 0x4e00 +/* MeiG Smart Technology products */ +#define MEIGSMART_VENDOR_ID 0x2dee +/* MeiG Smart SLM320 based on UNISOC UIS8910 */ +#define MEIGSMART_PRODUCT_SLM320 0x4d41 + /* Device flags */