From patchwork Mon Nov 4 09:44:34 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jinjian Song X-Patchwork-Id: 13861154 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 83B44D132A3 for ; Mon, 4 Nov 2024 09:52:09 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:MIME-Version:Content-Type: Content-Transfer-Encoding:References:In-Reply-To:Message-Id:Date:Subject:Cc: To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=2CVB7DGPsHwnsQCoXB7SBZjklEmEnihl9vo2LqNcsog=; b=CDeIg6LBSixyv4knz9u+iq7Ayy KfKln+M3qCqfC0RgH7hw1/G8MeMRLC2747vSIh02MJojjbYYL2YuofIMYVEfDQEdpWMdEFEv1qVLp fdaaLjrSo6L2k8YOVJCdrFSGDHkp21zjOBZhzw4AVJq/bCBTwuZSVJ3SoaqhF0YEVi101wj5lJIeM bqJjm7wDKIJPrUowN96GdKhCWJvZPQewkOXG43SmTJy5UYmId6Z0DgS3SM30XLUkPL2qhOZjW8knM /6AFW09sXE26kb0DqgIciX81pyJ2F20MexWQO6I45TaCNdt7uS88IaQ5W+NP/hRks9K2wBuJvi0/L HqkPDcWg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1t7tkm-0000000DDnl-2Y8Q; Mon, 04 Nov 2024 09:52:08 +0000 Received: from mail-psaapc01on2070f.outbound.protection.outlook.com ([2a01:111:f403:200e::70f] helo=APC01-PSA-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1t7teF-0000000DCKz-1tuG; Mon, 04 Nov 2024 09:45:25 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=QP6rOYxolem7QrnrNN2W5lvpEA1kKxhdR1csOxH8UpWmTHixFzGXFsy75nyztSSEMMUJleGuzCtvgrPZDsMaH45kBFUOmybdwszVuGucb0Gs45R22tk6Tf6gBo55dG0FCh8aIBfflC/YNUyDJmQLpI+pka1TZ/rzcgJu2hkhNG4I1aF+dDtunSm5A0NEZtPcrP67qziaYsLm4YRFyQSVbLDtcHy+sRAu/OBURLbRE6OWCwhQ2uL3fwl5l3MF3vRoFGqic+0VaBP/sNtaF5R96SCwRT9it+isoE0mJ70+7L2QYjq2TQM1EUZECJj0ZZ09jBmhU6ZqftW6bqBfYifbJw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=2CVB7DGPsHwnsQCoXB7SBZjklEmEnihl9vo2LqNcsog=; b=vn4H09n8pOdvaWmFV3bnyNs+QVLMb4V4ItkhghMxKkpQ8Wm0We640VYW6enQOFy+eT599QWqGQg9UpEtlsqs+j+rGMMrBHAfqRMoiZ4YfJOs9UpY7PqNbEIQTghVeStDcGtt317YNNzZrctTDGC2BkNsHZfg9STvRBhDB7trtJG5e3qHaa5VPpyWYzNgpYnvG2+KWxvearVwtEZKtZeBGbzzRpGgdJAmPmGdZFHIWk5CwEnc0J90/NXXPzYJdNH2t1RcFuAUhflspQeEpztEmBWb9Z/iNJDG20X30BRM5hWJMRsaeS74y8fyakVfuVErPkigK35OxQ/P8x50YfNkVA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=fibocom.com; dmarc=pass action=none header.from=fibocom.com; dkim=pass header.d=fibocom.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fibocomcorp.onmicrosoft.com; s=selector1-fibocomcorp-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=2CVB7DGPsHwnsQCoXB7SBZjklEmEnihl9vo2LqNcsog=; b=JVTkm9mUoN1ZdlET3miYA2r3NSboO8nVbV4+xkcDOe2Rzu+1OzfrnDrqbSaYzHTh7dtPuLHVqtO4aXWq6ihnNB67O9cK/61QZRwSSMo2/hiZpBdTTOIUuG9uJyFP+D+c46BHZkEUe/Drl7nxrPImELZQSSZffJwLuxavMhpLVPQ= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=fibocom.com; Received: from SEZPR02MB5782.apcprd02.prod.outlook.com (2603:1096:101:4f::8) by TYZPR02MB5764.apcprd02.prod.outlook.com (2603:1096:400:1d0::5) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8114.28; Mon, 4 Nov 2024 09:45:13 +0000 Received: from SEZPR02MB5782.apcprd02.prod.outlook.com ([fe80::4843:bf84:bd17:827e]) by SEZPR02MB5782.apcprd02.prod.outlook.com ([fe80::4843:bf84:bd17:827e%5]) with mapi id 15.20.8114.020; Mon, 4 Nov 2024 09:45:12 +0000 From: Jinjian Song To: chandrashekar.devegowda@intel.com, chiranjeevi.rapolu@linux.intel.com, haijun.liu@mediatek.com, m.chetan.kumar@linux.intel.com, ricardo.martinez@linux.intel.com, loic.poulain@linaro.org, ryazanov.s.a@gmail.com, johannes@sipsolutions.net, davem@davemloft.net, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com Cc: linux-kernel@vger.kernel.org, netdev@vger.kernel.org, linux-doc@vger.kernel.org, angelogioacchino.delregno@collabora.com, linux-arm-kernel@lists.infradead.org, matthias.bgg@gmail.com, corbet@lwn.net, linux-mediatek@lists.infradead.org, helgaas@kernel.org, danielwinkler@google.com, korneld@google.com, andrew+netdev@lunn.ch, horms@kernel.org, Jinjian Song Subject: [net-next v8 1/3] wwan: core: Add WWAN ADB and MIPC port type Date: Mon, 4 Nov 2024 17:44:34 +0800 Message-Id: <20241104094436.466861-2-jinjian.song@fibocom.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20241104094436.466861-1-jinjian.song@fibocom.com> References: <20241104094436.466861-1-jinjian.song@fibocom.com> X-ClientProxiedBy: SI2PR01CA0008.apcprd01.prod.exchangelabs.com (2603:1096:4:191::10) To SEZPR02MB5782.apcprd02.prod.outlook.com (2603:1096:101:4f::8) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SEZPR02MB5782:EE_|TYZPR02MB5764:EE_ X-MS-Office365-Filtering-Correlation-Id: 5b8d4c42-9943-4689-13f8-08dcfcb560ee X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|376014|7416014|52116014|1800799024|366016|38350700014|921020; X-Microsoft-Antispam-Message-Info: /zaCN5Vplyu1GS6pbNDgqPbvIkdXkYVSX76iRBnq06HVm5Hm7FFL0wW2y1IHkF6yyZEII69GkQOtYamQI8J7f2LDntU5eMKkI1oI0uMck0/6hhsMaeyOTTcziovdxMeLc+HYWotw89Wqw81mzuliilx2lz3tORafQMC3/Hb6W6vqnYnKfFeECDL7aSftmfKQUyMbUOmizYFXQ/92qf39+LIe2JQ5/4ekxUmDX+nAX4nCM0c9MRP0SfHZ1CM2WoxWm2vn33VAjkwCvaZf3MF+InT+eFTbzbqekZlKAtO/bSHsxi8AXbGO4GLD8MUL28uLksw0sKy7hAU7X+6vOO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UAIeosvQ X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SEZPR02MB5782.apcprd02.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(376014)(7416014)(52116014)(1800799024)(366016)(38350700014)(921020);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: oLMH44oJ3YGzh7xTv3i7p8yPibrULzZWZ7u8w1usebdfkWHJcdmpD/m17BSFv3xA4gA0fnqAB39bCC8fUXXYrtHe20cw5/KgOf10Za9grwYI6OiC5jRll2BGYi2T/06rAsgnx8ZeG1H18jtxivbRSu/PzOVeg91cqxZIsamQgfSrzL9R2HxEG7nHs6whcTWmBTI7SzmnuptHCnPTcQkpNeJXHbueWrlVq77jQyAU/kggCWBMhLrK2gF0EeT86LJkWWevyihJP04ZHvlSERgCeIpxNUeKmxlxDd4bNmxJfNOSSZ3wqPlkSJ582JDAy/wQ0AbexI/EHqH6ca2jOP48szCvwg90QOonbjEXiAYIUcf/om3UNp3PZMho8izDsyCMb7oigKi4IHSvWmEUzU3fMvMSFng/OIoHuGpHE6HtZJ+Hrj4F4gORMpqa5oYU494qTnPgktXzeC0LYe1/D+Huf2lJ/uql7tKGjqds2c7pXbpo7A97YW1EjGSu9nf7tYULI80Cj+I+fWYZXiWOcQWY7JGw0Y7UfIXnmd9sY5DO93WqZtZawGo41u4/oF6Lhgxk4GUOnN2k0uhf9tX4oiIeT7TxvZMQ2qfhjGCdTUsvXI70JFtObXvYYlGSLGsRnfWDdYv892573zsBC9i7bRBdA3miclqPxx8k0CZWtakwoOkmRr+D9F5oS+w7oqPwc7NokB8Ht/OFmANESCXBnrpQ74PCdBIckCVKlBZGX6mRnvLMCf6jnT/v0u52dibkSis1YdzWHDrENvnXw4sO9eyAo2y5KxKpIck9YJGsxvy4p51Y44x1eXo2EEvqEXOHFfq8to7cPoN2kMSG3CI2rLqc7roRu/Kd347usbkQc60up73fFXnkwmtwzmuI4WpX364CKm4+6YJbDCZ84Q9FiEgI/ZJUv62CBF4FlepQkQEtxF0Rbs4B6A8aAoLUgK1dQPO0L/o2GzEl+zlGs+AgHwMWL0a6fqoy95yy9uAt0Nbj0G3sRBzal7hx4w9W72A9ukEon3p1Io+J99LgNc5P/+XS5n9LfV2lRTTPtG/JNUVl6sz4uAMCcQ5D9TqgchbD7A8aBGHeD1G66fsPFDZ+Qx0tc9Nkgy0IaYy63oXyNL8GDvq2CVUjgPMnIHCxQ/+yAp2K/nwM067UXhGi9JyVGQqgZotNKH6toTbbqrBdL4tuod0rxtCYm/ddFpi17vGv9/veDBPiUfbsfC9V34fxreID3DMWqRe89YK3tZ79h2oS6VX0Q7rhJ8u6gOp81r7Qnu4jlWKt1TlDt3tMv2c4yAuL4Ibcuv+P73Op0td6jY8QzeX9qSMVFC3KWA+1SdSfilCQiVOtKGgrxTbROLxadUsNJBEEWvvcgQE85MHpuOM+xNzQCVwv69qb1aHIg2fhQf5sHU5uATCQpFrkWJiPzDMC5Sd+v1PvdIaK13s60YdzXlDfoepsU72tEj8bKPbfjIbsBw1Tns3zs0eKPs675/Z7NaAxgtckBA41XozbQYymXC1neEjqYDW4GSOdl7WbTLOg9M5vVgL89yIvbfHeXJI5npuC+ZWl3jMub5mOmVPP/B5Et3t1FbFSdF49vRwFzNY/j6YFaoRs3TYKRZkLFm8jQQ== X-OriginatorOrg: fibocom.com X-MS-Exchange-CrossTenant-Network-Message-Id: 5b8d4c42-9943-4689-13f8-08dcfcb560ee X-MS-Exchange-CrossTenant-AuthSource: SEZPR02MB5782.apcprd02.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 04 Nov 2024 09:45:12.7409 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 889bfe61-8c21-436b-bc07-3908050c8236 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: w0k3TlZpNU6g1AtAu5F53RRqTOy9bqGNX/6NHTRs0VTM+pM5ng0zoZJ8m39svQWhy/KRQKh41/u0R+v/rlOFtd8Zl0RmB6B2rfDc1vpsYw4= X-MS-Exchange-Transport-CrossTenantHeadersStamped: TYZPR02MB5764 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20241104_014523_542291_2EF3C1EE X-CRM114-Status: GOOD ( 10.31 ) X-BeenThere: linux-mediatek@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Linux-mediatek" Errors-To: linux-mediatek-bounces+linux-mediatek=archiver.kernel.org@lists.infradead.org Add new WWAN ports that connect to the device's ADB protocol interface and MTK MIPC diagnostic interface. Signed-off-by: Jinjian Song Reviewed-by: Sergey Ryazanov --- drivers/net/wwan/wwan_core.c | 8 ++++++++ include/linux/wwan.h | 4 ++++ 2 files changed, 12 insertions(+) diff --git a/drivers/net/wwan/wwan_core.c b/drivers/net/wwan/wwan_core.c index 17431f1b1a0c..5ffa70d5de85 100644 --- a/drivers/net/wwan/wwan_core.c +++ b/drivers/net/wwan/wwan_core.c @@ -334,6 +334,14 @@ static const struct { .name = "FASTBOOT", .devsuf = "fastboot", }, + [WWAN_PORT_ADB] = { + .name = "ADB", + .devsuf = "adb", + }, + [WWAN_PORT_MIPC] = { + .name = "MIPC", + .devsuf = "mipc", + }, }; static ssize_t type_show(struct device *dev, struct device_attribute *attr, diff --git a/include/linux/wwan.h b/include/linux/wwan.h index 170fdee6339c..79c781875c09 100644 --- a/include/linux/wwan.h +++ b/include/linux/wwan.h @@ -17,6 +17,8 @@ * @WWAN_PORT_FIREHOSE: XML based command protocol * @WWAN_PORT_XMMRPC: Control protocol for Intel XMM modems * @WWAN_PORT_FASTBOOT: Fastboot protocol control + * @WWAN_PORT_ADB: ADB protocol control + * @WWAN_PORT_MIPC: MTK MIPC diagnostic interface * * @WWAN_PORT_MAX: Highest supported port types * @WWAN_PORT_UNKNOWN: Special value to indicate an unknown port type @@ -30,6 +32,8 @@ enum wwan_port_type { WWAN_PORT_FIREHOSE, WWAN_PORT_XMMRPC, WWAN_PORT_FASTBOOT, + WWAN_PORT_ADB, + WWAN_PORT_MIPC, /* Add new port types above this line */ From patchwork Mon Nov 4 09:44:35 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jinjian Song X-Patchwork-Id: 13861169 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id B34B3D132A2 for ; Mon, 4 Nov 2024 09:53:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:MIME-Version:Content-Type: Content-Transfer-Encoding:References:In-Reply-To:Message-Id:Date:Subject:Cc: To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=ZT4d0RlYtep/xw9LoODzoqU4/NPwsYW+uVi/V+DCSXk=; b=FAV2DniWFZvqfXm2Xs3g+kXzgv kB2gpnAZfFBF6ZHIlBY//XLflE1sz+16wY/+fsIY845E9Z2ux/46ykVXU9MoRDlAQY617wML5wsGm DH7qTVxQQ670j3U1nvFtEMMpoBEbAiWSNatMYvR8YpTbhws/dKSWpi7+xLTvt4Z8dulIKEQdx6nMo JR24rkbufl3iur2WG7nl1512QH6fmv1WI7YIiZtbPW0jqI1SF3P18ix5x78DhvKGy/vhvf1pSLAIY fTcur+eskrJVugpyBRWbJTB737/HRnWrKxH7bd3J/RwaeZpxaNJp7J5q2osfMab0YxXxPpPhDfPQF jvPTJdNg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1t7tmR-0000000DE1Y-2odD; Mon, 04 Nov 2024 09:53:51 +0000 Received: from mail-sg2apc01on20711.outbound.protection.outlook.com ([2a01:111:f403:200f::711] helo=APC01-SG2-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1t7tei-0000000DCVO-0crZ; Mon, 04 Nov 2024 09:45:53 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=Qs+jAypRb23QRWiWcbrWB+g+hEnh4zoL+dTL9ZuFrS3nRAFrT7RiXs6KGC4dzco/KD3QKrDz2Tx/IfVt5CpjQ83CsPMLycxq/RIKg1lufSTHN/ufxkvAESPGRCHvS6ZspUhbObqkzWPrIHXb9o5KjMUgUrbbuCWMH6g1nDNpHimy/mTnOeGFX7JEI2fimMABzY+/b+LVSMa2JwIfeKsZbweOK1vnst9hNXybTuH/uN85oLuUoAcggy+xTFwTwMDRzXmLvAETwPNIwZxmsfydKdLXfJQ0UT0qrW/DMxECzHQwW8FhlOeq8No0+RS3brPYr4YOsIO1ypfwqYLo4JKtcA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=ZT4d0RlYtep/xw9LoODzoqU4/NPwsYW+uVi/V+DCSXk=; b=GwY5hxZpc4+q6Y8mES8ISaD/xPNZfe58yzh7WBpnXlzyxxy8vqGXOz2RGW+IMW1vj5WbZ4Q9MtTFddFOjpxwpnBHj0NSck7GtmGec0+1+m0PtaYR4FXZB1bvVN7be0AprUcrxv1CK0+Pt6qI2AxgN+ra8pekcwQT44vEWS4VxES9MD6oapL1CB7g6Gj9P8D8/WBNICOa3aEH0JH46ESJax8R5xVNcFzAMzBsHJl0SUAd4xK6lIJzEliIpBhMG3ICqNQylzUGDGSFs7rQaOduTVgLEPeep3wETzhL4QKeaOdv/B/6ESUoH/JGfz5H8MfF52IwUhAuNPbf9R0L0/QAkQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=fibocom.com; dmarc=pass action=none header.from=fibocom.com; dkim=pass header.d=fibocom.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fibocomcorp.onmicrosoft.com; s=selector1-fibocomcorp-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=ZT4d0RlYtep/xw9LoODzoqU4/NPwsYW+uVi/V+DCSXk=; b=M4K5bo/tNDfosrqgsLTK4WkJBxPI9zNbcCY47JFbTUDpn3aWeySxzIDtm54PTHUa0Sm0WuqiZNa2PYsMfDuzow0YQzavji9EW9TSq5QNlG+Rbi+E8kTCyqrkN3Vb+HCL90nY2cNlFtjd4JBSHLG5P1ytScpdv8QJoLoNhmlERxg= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=fibocom.com; Received: from SEZPR02MB5782.apcprd02.prod.outlook.com (2603:1096:101:4f::8) by TYZPR02MB5764.apcprd02.prod.outlook.com (2603:1096:400:1d0::5) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8114.28; Mon, 4 Nov 2024 09:45:45 +0000 Received: from SEZPR02MB5782.apcprd02.prod.outlook.com ([fe80::4843:bf84:bd17:827e]) by SEZPR02MB5782.apcprd02.prod.outlook.com ([fe80::4843:bf84:bd17:827e%5]) with mapi id 15.20.8114.020; Mon, 4 Nov 2024 09:45:45 +0000 From: Jinjian Song To: chandrashekar.devegowda@intel.com, chiranjeevi.rapolu@linux.intel.com, haijun.liu@mediatek.com, m.chetan.kumar@linux.intel.com, ricardo.martinez@linux.intel.com, loic.poulain@linaro.org, ryazanov.s.a@gmail.com, johannes@sipsolutions.net, davem@davemloft.net, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com Cc: linux-kernel@vger.kernel.org, netdev@vger.kernel.org, linux-doc@vger.kernel.org, angelogioacchino.delregno@collabora.com, linux-arm-kernel@lists.infradead.org, matthias.bgg@gmail.com, corbet@lwn.net, linux-mediatek@lists.infradead.org, helgaas@kernel.org, danielwinkler@google.com, korneld@google.com, andrew+netdev@lunn.ch, horms@kernel.org, Jinjian Song Subject: [net-next v8 2/3] net: wwan: t7xx: Add debug ports Date: Mon, 4 Nov 2024 17:44:35 +0800 Message-Id: <20241104094436.466861-3-jinjian.song@fibocom.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20241104094436.466861-1-jinjian.song@fibocom.com> References: <20241104094436.466861-1-jinjian.song@fibocom.com> X-ClientProxiedBy: SI2PR01CA0008.apcprd01.prod.exchangelabs.com (2603:1096:4:191::10) To SEZPR02MB5782.apcprd02.prod.outlook.com (2603:1096:101:4f::8) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SEZPR02MB5782:EE_|TYZPR02MB5764:EE_ X-MS-Office365-Filtering-Correlation-Id: c1ec3c78-0fab-4995-6b6d-08dcfcb57407 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|376014|7416014|52116014|1800799024|366016|38350700014|921020; X-Microsoft-Antispam-Message-Info: nTIqlIR896vRbiPWZ0sLRm7xF+u+94XzKL9vHEMFaFXDQCLtOYREBfp+gQHWLEQ6LjbqgOOIeTUbC2T/2rV+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ykb+M5zoFKCpBBV0aqtzFzHJ3ao8xBUBhsvKAaJvGHouZu65Mv+IvkVHDnUOez0HlntksGK9vAy7VjaFV4V5xrwHm/ZZ0ekNbntIDLkH71BRhEr35dCsTcx1WXxFfwVMhDTEcLO4TwzlLedW4idj6aeGq3rRPteG3nFyK8fA3JAzp+b25iNaBJgUb3IzAw== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SEZPR02MB5782.apcprd02.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(376014)(7416014)(52116014)(1800799024)(366016)(38350700014)(921020);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: oRM4u8Us3cH4fkgFuQTQ0G/69CZa1Ivw1+/dlIc/algIFA0Xa/4pQ78j+Gm5rR8dKfiixVe6NS02e5i2LHuCFghVb9oNo8pvlRNZI2b3c/85AMvowJKYrTIpS9MptHcJXRwYsWWh2Qepz7PJSfzakHby1zz3LYtgdhh2iFQ5OoCWYZK8QVX9ZWIPR2lhgUaZ4hWHrqGr1/yUuBYF/tFfVUhG9XbExM1rv/5kY1zHxo0iGDikt0loPOdQNn1Z6yhqaN9GVaMR2LSP1c+RKT31NuLDojFJX2GhibfjajK1LtDLxnTjKNBwAolWA6T+63caZ/meaDlqUVdNdUSL6pmKBbx/JbZAdtV/egFsQODkffd/HmgLI3V1dOo37SaPeVZygR1Xb+plQc5J4eARcPl6Y4l4GwPskylyopwtg2cEu5ODbgmf3rM6b78FxpHQ8IC7aoSkaTtnuvJ6Ggo7F1HBzdw+x1DXPyiWA0fd7vqIEKrgJ6BtWK80V3e6s9Gb/xLmg5O3URKqbNCQZKrsXAne0IACrHymmvIYsGZ1FldzhaqFaNIC/0NJ4sNIC5K3izH/3R4c0I3QOG7VwCz3/vQkxhPGRH/aHnl6i5963ouOUQYqwYfXPqVZEHGqX4CxS2z5n2lP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Tenant-AuthSource: SEZPR02MB5782.apcprd02.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 04 Nov 2024 09:45:45.1321 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 889bfe61-8c21-436b-bc07-3908050c8236 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: Z9m+Ordvpo0AsiKnvXsWUQmS92tAoXUsDvj+jGqi+y4WeKk6j5mO33Jf1y/UhtcPP+EPv71A24AUNB9QuKj6iS1v2o0ffankfXV8qUxBPd4= X-MS-Exchange-Transport-CrossTenantHeadersStamped: TYZPR02MB5764 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20241104_014552_397047_FFBAE0DC X-CRM114-Status: GOOD ( 17.35 ) X-BeenThere: linux-mediatek@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Linux-mediatek" Errors-To: linux-mediatek-bounces+linux-mediatek=archiver.kernel.org@lists.infradead.org Add support for userspace to enable/disable the debug ports(ADB,MIPC). - ADB port: /dev/wwan0adb0 - MIPC port: /dev/wwan0mipc0 Application can use ADB (Android Debug Bridge) port to implement functions (shell, pull, push ...) by ADB protocol commands. E.g., ADB commands: - A_OPEN: OPEN(local-id, 0, "destination") - A_WRTE: WRITE(local-id, remote-id, "data") - A_OKEY: READY(local-id, remote-id, "") - A_CLSE: CLOSE(local-id, remote-id, "") Link: https://android.googlesource.com/platform/packages/modules/adb/+/refs/heads/main/README.md Application can use MIPC (Modem Information Process Center) port to debug antenna tuner or noise profiling through this MTK modem diagnostic interface. By default, debug ports are not exposed, so using the command to enable or disable debug ports. Enable debug ports: - enable: 'echo 1 > /sys/bus/pci/devices/${bdf}/t7xx_debug_ports Disable debug ports: - disable: 'echo 0 > /sys/bus/pci/devices/${bdf}/t7xx_debug_ports Signed-off-by: Jinjian Song --- v8: * Rename knod t7xx_port_mode to t7xx_debug_ports and update commit messages * Modify the alignment in knod t7xx_debug_ports_store() and t7xx_debug_ports_show() * Separate the column width modification of t7xx.rst into another patch * Rename t7xx_proxy_port_debug() to t7xx_proxy_debug_ports_show() * Modify the port_mode to debug_ports_show in struct t7xx_pci_dev * Modify the Q_IDX_MBIM to Q_IDX_MBIM_MIPC and delete the Q_IDX_MIPC to avoid id name duplications * Modify the conditional check in t7xx_proxy_debug_ports_show() to make port init() and uninit() call safer v7: * Adjust t7xx.rst columns and word spelling in commit message v5: * Modify line length warning in t7xx_proxy_port_debug() v4: * Modify commit message t7xx_mode to t7xx_port_mode v3: * Add sysfs interface t7xx_port_mode * Delete spin_lock_init in t7xx_proxy_port_debug() * Modify document t7xx.rst v2: * Add WWAN ADB and MIPC port --- .../networking/device_drivers/wwan/t7xx.rst | 47 +++++++++++++++ drivers/net/wwan/t7xx/t7xx_modem_ops.c | 1 + drivers/net/wwan/t7xx/t7xx_pci.c | 58 +++++++++++++++++-- drivers/net/wwan/t7xx/t7xx_pci.h | 1 + drivers/net/wwan/t7xx/t7xx_port.h | 3 + drivers/net/wwan/t7xx/t7xx_port_proxy.c | 51 ++++++++++++++-- drivers/net/wwan/t7xx/t7xx_port_proxy.h | 1 + drivers/net/wwan/t7xx/t7xx_port_wwan.c | 8 ++- 8 files changed, 157 insertions(+), 13 deletions(-) diff --git a/Documentation/networking/device_drivers/wwan/t7xx.rst b/Documentation/networking/device_drivers/wwan/t7xx.rst index f346f5f85f15..4cf777c341cd 100644 --- a/Documentation/networking/device_drivers/wwan/t7xx.rst +++ b/Documentation/networking/device_drivers/wwan/t7xx.rst @@ -67,6 +67,28 @@ Write from userspace to set the device mode. :: $ echo fastboot_switching > /sys/bus/pci/devices/${bdf}/t7xx_mode +t7xx_debug_ports +---------------- +The sysfs interface provides userspace with access to enable/disable the debug +ports, this interface supports read and write operations. + +Debug port status: + +- ``1`` represents enable debug ports +- ``0`` represents disable debug ports + +Currently supported debug ports (ADB/MIPC). + +Read from userspace to get the current debug ports status. + +:: + $ cat /sys/bus/pci/devices/${bdf}/t7xx_debug_ports + +Write from userspace to set the debug ports status. + +:: + $ echo 1 > /sys/bus/pci/devices/${bdf}/t7xx_debug_ports + Management application development ================================== The driver and userspace interfaces are described below. The MBIM protocol is @@ -139,6 +161,25 @@ Please note that driver needs to be reloaded to export /dev/wwan0fastboot0 port, because device needs a cold reset after enter ``fastboot_switching`` mode. +ADB port userspace ABI +---------------------- + +/dev/wwan0adb0 character device +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +The driver exposes a ADB protocol interface by implementing ADB WWAN Port. +The userspace end of the ADB channel pipe is a /dev/wwan0adb0 character device. +Application shall use this interface for ADB protocol communication. + +MIPC port userspace ABI +----------------------- + +/dev/wwan0mipc0 character device +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +The driver exposes a diagnostic interface by implementing MIPC (Modem +Information Process Center) WWAN Port. The userspace end of the MIPC channel +pipe is a /dev/wwan0mipc0 character device. +Application shall use this interface for MTK modem diagnostic communication. + The MediaTek's T700 modem supports the 3GPP TS 27.007 [4] specification. References @@ -164,3 +205,9 @@ speak the Mobile Interface Broadband Model (MBIM) protocol"* [5] *fastboot "a mechanism for communicating with bootloaders"* - https://android.googlesource.com/platform/system/core/+/refs/heads/main/fastboot/README.md + +[6] *ADB (Android Debug Bridge) "a mechanism to keep track of Android devices +and emulators instances connected to or running on a given host developer +machine with ADB protocol"* + +- https://android.googlesource.com/platform/packages/modules/adb/+/refs/heads/main/README.md diff --git a/drivers/net/wwan/t7xx/t7xx_modem_ops.c b/drivers/net/wwan/t7xx/t7xx_modem_ops.c index 79f17100f70b..7968e208dd37 100644 --- a/drivers/net/wwan/t7xx/t7xx_modem_ops.c +++ b/drivers/net/wwan/t7xx/t7xx_modem_ops.c @@ -198,6 +198,7 @@ int t7xx_reset_device(struct t7xx_pci_dev *t7xx_dev, enum reset_type type) pci_save_state(t7xx_dev->pdev); t7xx_pci_reprobe_early(t7xx_dev); t7xx_mode_update(t7xx_dev, T7XX_RESET); + WRITE_ONCE(t7xx_dev->debug_ports_show, false); if (type == FLDR) { ret = t7xx_acpi_reset(t7xx_dev, "_RST"); diff --git a/drivers/net/wwan/t7xx/t7xx_pci.c b/drivers/net/wwan/t7xx/t7xx_pci.c index e556e5bd49ab..7b8c17b029c7 100644 --- a/drivers/net/wwan/t7xx/t7xx_pci.c +++ b/drivers/net/wwan/t7xx/t7xx_pci.c @@ -41,6 +41,7 @@ #include "t7xx_pcie_mac.h" #include "t7xx_reg.h" #include "t7xx_state_monitor.h" +#include "t7xx_port_proxy.h" #define T7XX_PCI_IREG_BASE 0 #define T7XX_PCI_EREG_BASE 2 @@ -120,13 +121,58 @@ static ssize_t t7xx_mode_show(struct device *dev, static DEVICE_ATTR_RW(t7xx_mode); -static struct attribute *t7xx_mode_attr[] = { +static ssize_t t7xx_debug_ports_store(struct device *dev, + struct device_attribute *attr, + const char *buf, size_t count) +{ + struct t7xx_pci_dev *t7xx_dev; + struct pci_dev *pdev; + bool show; + int ret; + + pdev = to_pci_dev(dev); + t7xx_dev = pci_get_drvdata(pdev); + if (!t7xx_dev) + return -ENODEV; + + ret = kstrtobool(buf, &show); + if (ret < 0) + return ret; + + t7xx_proxy_debug_ports_show(t7xx_dev, show); + WRITE_ONCE(t7xx_dev->debug_ports_show, show); + + return count; +}; + +static ssize_t t7xx_debug_ports_show(struct device *dev, + struct device_attribute *attr, + char *buf) +{ + struct t7xx_pci_dev *t7xx_dev; + struct pci_dev *pdev; + bool show; + + pdev = to_pci_dev(dev); + t7xx_dev = pci_get_drvdata(pdev); + if (!t7xx_dev) + return -ENODEV; + + show = READ_ONCE(t7xx_dev->debug_ports_show); + + return sysfs_emit(buf, "%d\n", show); +} + +static DEVICE_ATTR_RW(t7xx_debug_ports); + +static struct attribute *t7xx_attr[] = { &dev_attr_t7xx_mode.attr, + &dev_attr_t7xx_debug_ports.attr, NULL }; -static const struct attribute_group t7xx_mode_attribute_group = { - .attrs = t7xx_mode_attr, +static const struct attribute_group t7xx_attribute_group = { + .attrs = t7xx_attr, }; void t7xx_mode_update(struct t7xx_pci_dev *t7xx_dev, enum t7xx_mode mode) @@ -839,7 +885,7 @@ static int t7xx_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id) t7xx_pcie_mac_interrupts_dis(t7xx_dev); ret = sysfs_create_group(&t7xx_dev->pdev->dev.kobj, - &t7xx_mode_attribute_group); + &t7xx_attribute_group); if (ret) goto err_md_exit; @@ -855,7 +901,7 @@ static int t7xx_pci_probe(struct pci_dev *pdev, const struct pci_device_id *id) err_remove_group: sysfs_remove_group(&t7xx_dev->pdev->dev.kobj, - &t7xx_mode_attribute_group); + &t7xx_attribute_group); err_md_exit: t7xx_md_exit(t7xx_dev); @@ -870,7 +916,7 @@ static void t7xx_pci_remove(struct pci_dev *pdev) t7xx_dev = pci_get_drvdata(pdev); sysfs_remove_group(&t7xx_dev->pdev->dev.kobj, - &t7xx_mode_attribute_group); + &t7xx_attribute_group); t7xx_md_exit(t7xx_dev); for (i = 0; i < EXT_INT_NUM; i++) { diff --git a/drivers/net/wwan/t7xx/t7xx_pci.h b/drivers/net/wwan/t7xx/t7xx_pci.h index cd8ea17c2644..b25d867e72d2 100644 --- a/drivers/net/wwan/t7xx/t7xx_pci.h +++ b/drivers/net/wwan/t7xx/t7xx_pci.h @@ -94,6 +94,7 @@ struct t7xx_pci_dev { struct dentry *debugfs_dir; #endif u32 mode; + bool debug_ports_show; }; enum t7xx_pm_id { diff --git a/drivers/net/wwan/t7xx/t7xx_port.h b/drivers/net/wwan/t7xx/t7xx_port.h index f74d3bab810d..9f5d6d288c97 100644 --- a/drivers/net/wwan/t7xx/t7xx_port.h +++ b/drivers/net/wwan/t7xx/t7xx_port.h @@ -42,6 +42,8 @@ enum port_ch { /* to AP */ PORT_CH_AP_CONTROL_RX = 0x1000, PORT_CH_AP_CONTROL_TX = 0x1001, + PORT_CH_AP_ADB_RX = 0x100a, + PORT_CH_AP_ADB_TX = 0x100b, /* to MD */ PORT_CH_CONTROL_RX = 0x2000, @@ -100,6 +102,7 @@ struct t7xx_port_conf { struct port_ops *ops; char *name; enum wwan_port_type port_type; + bool debug; }; struct t7xx_port { diff --git a/drivers/net/wwan/t7xx/t7xx_port_proxy.c b/drivers/net/wwan/t7xx/t7xx_port_proxy.c index 35743e7de0c3..4fc131f9632f 100644 --- a/drivers/net/wwan/t7xx/t7xx_port_proxy.c +++ b/drivers/net/wwan/t7xx/t7xx_port_proxy.c @@ -38,7 +38,8 @@ #include "t7xx_state_monitor.h" #define Q_IDX_CTRL 0 -#define Q_IDX_MBIM 2 +#define Q_IDX_MBIM_MIPC 2 +#define Q_IDX_ADB 3 #define Q_IDX_AT_CMD 5 #define INVALID_SEQ_NUM GENMASK(15, 0) @@ -66,8 +67,8 @@ static const struct t7xx_port_conf t7xx_port_conf[] = { }, { .tx_ch = PORT_CH_MBIM_TX, .rx_ch = PORT_CH_MBIM_RX, - .txq_index = Q_IDX_MBIM, - .rxq_index = Q_IDX_MBIM, + .txq_index = Q_IDX_MBIM_MIPC, + .rxq_index = Q_IDX_MBIM_MIPC, .path_id = CLDMA_ID_MD, .ops = &wwan_sub_port_ops, .name = "MBIM", @@ -100,7 +101,27 @@ static const struct t7xx_port_conf t7xx_port_conf[] = { .path_id = CLDMA_ID_AP, .ops = &ctl_port_ops, .name = "t7xx_ap_ctrl", - }, + }, { + .tx_ch = PORT_CH_AP_ADB_TX, + .rx_ch = PORT_CH_AP_ADB_RX, + .txq_index = Q_IDX_ADB, + .rxq_index = Q_IDX_ADB, + .path_id = CLDMA_ID_AP, + .ops = &wwan_sub_port_ops, + .name = "adb", + .port_type = WWAN_PORT_ADB, + .debug = true, + }, { + .tx_ch = PORT_CH_MIPC_TX, + .rx_ch = PORT_CH_MIPC_RX, + .txq_index = Q_IDX_MBIM_MIPC, + .rxq_index = Q_IDX_MBIM_MIPC, + .path_id = CLDMA_ID_MD, + .ops = &wwan_sub_port_ops, + .name = "mipc", + .port_type = WWAN_PORT_MIPC, + .debug = true, + } }; static const struct t7xx_port_conf t7xx_early_port_conf[] = { @@ -505,13 +526,33 @@ static void t7xx_proxy_init_all_ports(struct t7xx_modem *md) spin_lock_init(&port->port_update_lock); port->chan_enable = false; - if (port_conf->ops && port_conf->ops->init) + if (!port_conf->debug && + port_conf->ops && + port_conf->ops->init) port_conf->ops->init(port); } t7xx_proxy_setup_ch_mapping(port_prox); } +void t7xx_proxy_debug_ports_show(struct t7xx_pci_dev *t7xx_dev, bool show) +{ + struct port_proxy *port_prox = t7xx_dev->md->port_prox; + struct t7xx_port *port; + int i; + + for_each_proxy_port(i, port, port_prox) { + const struct t7xx_port_conf *port_conf = port->port_conf; + + if (port_conf->debug && port_conf->ops) { + if (show && port_conf->ops->init) + port_conf->ops->init(port); + else if (!show && port_conf->ops->uninit) + port_conf->ops->uninit(port); + } + } +} + void t7xx_port_proxy_set_cfg(struct t7xx_modem *md, enum port_cfg_id cfg_id) { struct port_proxy *port_prox = md->port_prox; diff --git a/drivers/net/wwan/t7xx/t7xx_port_proxy.h b/drivers/net/wwan/t7xx/t7xx_port_proxy.h index 7f5706811445..f0918b36e899 100644 --- a/drivers/net/wwan/t7xx/t7xx_port_proxy.h +++ b/drivers/net/wwan/t7xx/t7xx_port_proxy.h @@ -98,6 +98,7 @@ extern struct port_ops ctl_port_ops; extern struct port_ops t7xx_trace_port_ops; #endif +void t7xx_proxy_debug_ports_show(struct t7xx_pci_dev *t7xx_dev, bool show); void t7xx_port_proxy_reset(struct port_proxy *port_prox); void t7xx_port_proxy_uninit(struct port_proxy *port_prox); int t7xx_port_proxy_init(struct t7xx_modem *md); diff --git a/drivers/net/wwan/t7xx/t7xx_port_wwan.c b/drivers/net/wwan/t7xx/t7xx_port_wwan.c index 4b23ba693f3f..7fc569565ff9 100644 --- a/drivers/net/wwan/t7xx/t7xx_port_wwan.c +++ b/drivers/net/wwan/t7xx/t7xx_port_wwan.c @@ -169,7 +169,9 @@ static int t7xx_port_wwan_init(struct t7xx_port *port) { const struct t7xx_port_conf *port_conf = port->port_conf; - if (port_conf->port_type == WWAN_PORT_FASTBOOT) + if (port_conf->port_type == WWAN_PORT_FASTBOOT || + port_conf->port_type == WWAN_PORT_ADB || + port_conf->port_type == WWAN_PORT_MIPC) t7xx_port_wwan_create(port); port->rx_length_th = RX_QUEUE_MAXLEN; @@ -224,7 +226,9 @@ static void t7xx_port_wwan_md_state_notify(struct t7xx_port *port, unsigned int { const struct t7xx_port_conf *port_conf = port->port_conf; - if (port_conf->port_type == WWAN_PORT_FASTBOOT) + if (port_conf->port_type == WWAN_PORT_FASTBOOT || + port_conf->port_type == WWAN_PORT_ADB || + port_conf->port_type == WWAN_PORT_MIPC) return; if (state != MD_STATE_READY) From patchwork Mon Nov 4 09:44:36 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jinjian Song X-Patchwork-Id: 13861170 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 40E74D132A2 for ; Mon, 4 Nov 2024 09:55:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:MIME-Version:Content-Type: Content-Transfer-Encoding:References:In-Reply-To:Message-Id:Date:Subject:Cc: To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=qR/IPmJERzKwq7pyhhzpV+mbaE98mDNPcQJZDDRh8mw=; b=gJRh+HfSYcW/eWi51XHkxenOWP Cj1GRm8JDtVtqdiCmuuz4D5Vc5R+xZze+Qobnz/dGjxxNEko5eeRuTV42jxX4aRvnGDPDSUn9xtP/ B+KJAULAm2orAkxtJ57SBqw6M2zDKycWJdSkRabIeYTAOaW+aDABt2eY10htuBOI1pozVkNdWP5ge 5dDEm1byrk3/lK7albbSM+GcCjKm0GDFDbfkqOthlEydvw4kGCwhY6uUX0v+uMZ3wo/1Rx2AhpBu5 LkEbhdxHXWINyQyd7Y6mrAIf75nQgNOH9QBg8WZ3dCO6RZstwjuSUrh0JxXPjLupNYfoHd32Wj0Xf 9mP8Fvlg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1t7toB-0000000DEIm-0OWe; Mon, 04 Nov 2024 09:55:39 +0000 Received: from mail-psaapc01on2072a.outbound.protection.outlook.com ([2a01:111:f403:200e::72a] helo=APC01-PSA-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1t7tep-0000000DCY6-1564; Mon, 04 Nov 2024 09:46:00 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=jxQ77KoqmTPn7+yxQkCeAFWSg/l0Nhrn7ykX5JOPCP3CiJGfavQmUl0/Br8oz1k1lKJeZYu1ZpOC8JcpJ7qRgQJGHyPzIy1/xtHbDKOwqAlg+b+UVTHUVTAW7JpS6YWJwYq+zImMs2vLeUDusBULia3oPLdajtP/RGkKengPrL+pYpTzDqaWMmAwbGROqsnhruC4n3/ZI5nDxFY0Y4hIVpFdjVqsSlwshNc0j5eqw4sSKHFDY0fgJcQGmui68pKcCPWea5FfMAejjax5zBPFvbaEzp11pXYhd7zYut8j5ITB5mcW0X2wKMtbI3IaIMipM+iCjAC9vXs4RgVLRI3nbw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=qR/IPmJERzKwq7pyhhzpV+mbaE98mDNPcQJZDDRh8mw=; b=aHtdC/qlKt/4wRem/pluPQsk8m4A5dlpEnlUIHtrAi78606RZxpXiuxWi8JQrgJ/6/q7U7MTaV3sN+ltFGzQwcMM01hFLar1FSOMeMYrhBPzz1BWnEG/+GSCHwdBBTtcJUcs+qiFY7GJz444Q2OJcU5Zl1AO2rzTe2OIyW+NEAN3vtGtlnMNRO2I7AEKVBXuMI1sjfMotZtz6bHgks+NHtQD6bEd0ZAN4X4NbYM0v95an5Kdc0HSjEBAeLb5JlEGGw8hzuqIxRArLKHKHOapYB7Ei/1h8Eiu/FLF1O3z7vMn9Gnx5xkDcqbCOz5Y+B0i4H8r4WO5w0eKKu99KiMu3g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=fibocom.com; dmarc=pass action=none header.from=fibocom.com; dkim=pass header.d=fibocom.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fibocomcorp.onmicrosoft.com; s=selector1-fibocomcorp-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=qR/IPmJERzKwq7pyhhzpV+mbaE98mDNPcQJZDDRh8mw=; b=leJpFKb+dVp0issH3qocnT9aLaxSqR6gcb/qq6tDn+UtcEr4mItIJAoodQu770jVH5H5xU3689k012ajctaP5MQs5tvUq52FKsZEGVHNG3bMdVkjs49/z0Rb6AZleNZ/G/D0A2nmuK2VJmJpQdHDJq05/AMA1XnGQsIagUdSnK4= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=fibocom.com; Received: from SEZPR02MB5782.apcprd02.prod.outlook.com (2603:1096:101:4f::8) by TYZPR02MB5764.apcprd02.prod.outlook.com (2603:1096:400:1d0::5) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8114.28; Mon, 4 Nov 2024 09:45:56 +0000 Received: from SEZPR02MB5782.apcprd02.prod.outlook.com ([fe80::4843:bf84:bd17:827e]) by SEZPR02MB5782.apcprd02.prod.outlook.com ([fe80::4843:bf84:bd17:827e%5]) with mapi id 15.20.8114.020; Mon, 4 Nov 2024 09:45:56 +0000 From: Jinjian Song To: chandrashekar.devegowda@intel.com, chiranjeevi.rapolu@linux.intel.com, haijun.liu@mediatek.com, m.chetan.kumar@linux.intel.com, ricardo.martinez@linux.intel.com, loic.poulain@linaro.org, ryazanov.s.a@gmail.com, johannes@sipsolutions.net, davem@davemloft.net, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com Cc: linux-kernel@vger.kernel.org, netdev@vger.kernel.org, linux-doc@vger.kernel.org, angelogioacchino.delregno@collabora.com, linux-arm-kernel@lists.infradead.org, matthias.bgg@gmail.com, corbet@lwn.net, linux-mediatek@lists.infradead.org, helgaas@kernel.org, danielwinkler@google.com, korneld@google.com, andrew+netdev@lunn.ch, horms@kernel.org, Jinjian Song Subject: [net-next v8 3/3] net: wwan: t7xx: Unify documentation column width Date: Mon, 4 Nov 2024 17:44:36 +0800 Message-Id: <20241104094436.466861-4-jinjian.song@fibocom.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20241104094436.466861-1-jinjian.song@fibocom.com> References: <20241104094436.466861-1-jinjian.song@fibocom.com> X-ClientProxiedBy: SI2PR01CA0008.apcprd01.prod.exchangelabs.com (2603:1096:4:191::10) To SEZPR02MB5782.apcprd02.prod.outlook.com (2603:1096:101:4f::8) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SEZPR02MB5782:EE_|TYZPR02MB5764:EE_ X-MS-Office365-Filtering-Correlation-Id: 49b70a3b-b0c8-4b30-e5b6-08dcfcb57ae2 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230040|376014|7416014|52116014|1800799024|366016|38350700014|921020; X-Microsoft-Antispam-Message-Info: M/USkgIm0r4QnbZvSE7yLkhTuy6NTqudQ+KXAVMTjgFxBypoaHLG7nP5s7rnfr+N9WA5zdpOVRn3L04f8wjSq+CU0WUDjOeNgNwIN2P7HQ2r59ohUCcMEEPTU6eDe08+uVoAzbMOuhNHHtTR1eXw51l5GkJomwt/u9gEnpDQoPGAgFfDhNQvDVrv9fKLfw1QrHBlM4qgBYJPGhyNox43aCntIcTvkvT8t/5TrRV+UJ0U9OxP8qbxzndIWz1xAwedWMMNb2nG+b2ttCQjnb/0p12aqFPND6+tF64DdRCDte6vk/5S6u7FnqyORDZ12tBkdgH40mc+TIZuOiFSOWV8JkBHqyFJkr3LKq+KEDl4Bpp2W/H6UyOASTIUJDdtzIl7+DiKxUnvOq8EW7vq0rsRZNZ3uwi34W6RHwiSE1xrPegVHbxbkWwPqqBGeapGpZAlJfouOm9RjqAs1tr1GjRXkyPosThkadERRYqW4E3FkFaR1kiCSbpBaz0h3esburF9oXz3lCdyh06B6bovvDFdenwVEST6xIfZWIIEgH09NaUVxxPQdwXx1jDeSluBVwLaHpQyOv/pH2qLI/suLzBaIWSqhZLmjJkxkOj612/ML/MDahbc+VoAMp1EgoN26qMA4/RXr7z6X5O6z46wu1eR6zG+xoFfXyCyQ58E31T2TB/x5OE49VmPZp5oxpsIXwoMM1WeH9G07IYU859ncpIE7UTiVHbi3jcjmTOoxo5r13bxi12RWwmZ2PK9FHzJo8CIM89dYDEt8U5K/oqnIu3bbayz1RprnPI2aGHxXuNsmCGuGL4Mqa2H1O2mNT0pn64lW7JCc1MH1kFQxJ9liAzNwTreXAannNb42vMagIDOTPpVuoLfD60gK40EERxrLp6dYDFijbqjmPzsyYnJbRKxHo42P9F++4IpcL17iKTn9PfuF3J5jQ8+2964H6wjC6IenBLHFP0bfy2brrSkVOoDwgsjlqPjJ33IL38t9HPB09osu4ck+18fTYSDqZkQSb4eHIFI6o/GBeyv42bL3wBWR5QxYALdhKMir2fd+nHTV2J4w144IVmAWUPvEiRCDNo5hduLcQuZrq+5fKcytpt7SqpZUaamdNCt4UED5/uWh5QBo91gemKMc6HhCi4X8CJKGFKupwAet1mvUV+E6Fabx8xPVXIBXqiMtVkPWcsCSpD/ABsRZPawzAFVd8yW0raht72Tj3FT3dZjEUg6Nk8usHipmpjVryYkTseqCpuDZp6nlziBehluwGxQZbYheWu+JyUc/VFvCme43qzdE0WdUoycrrNhapzROlrN6xsosPxdj94CNTjbO2OIVQbrmx5IjMtUs/md5dxAZ2yDVX/huZr/+1D7FsL5xo5stG0Zc9wFFQhNYcI6tbEjI+ioiLxB X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:SEZPR02MB5782.apcprd02.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230040)(376014)(7416014)(52116014)(1800799024)(366016)(38350700014)(921020);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 9RxOlGxKiPeL8sar8/iyty6ib5oF3disbbCVJHdp99DhsFYRhzl7Xk0JS9HJCPOBj6K0hu639ayP1oHIYYoXxBR8k5KvayPyscmFpT7GXWWGGB87qM95XCOaAe9XtN9TYkkD4inGqowPcILA8G6c+klA6u8IbF6hc4ClCBeGC76M0T3pYPVwfqNG3ruHh2QjebkhaLkk7/3yKr7K6K2UlXG4oYVvIbF3lRDbJn+55RXIAUNGraAPQqI+hzpy1PlayHXLqi8lXE8evlLE+SyG3gVzoRX1q0KDTZEitbuoWQpbFpu/Q1+nOniTbIxEcu/9hJd/zytaqqSI+SRe+FlPsToAHJApRf61mmYMe5c4CeXVQShM7h4jJz686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41EAWOvl9P0mXkyW+xM3B/N9DDs5r+Cy+6W5b4y3MW+WHABnDNfBGTfhmDvPN9i/vpEC8iev1NBiswH+RUALMHF4+VVt21gPVsHVgLgMlEJmdk0Ob0PdE7ajM97z5xxhUN8M2HeeXm/gm/tGV2Q== X-OriginatorOrg: fibocom.com X-MS-Exchange-CrossTenant-Network-Message-Id: 49b70a3b-b0c8-4b30-e5b6-08dcfcb57ae2 X-MS-Exchange-CrossTenant-AuthSource: SEZPR02MB5782.apcprd02.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 04 Nov 2024 09:45:56.3845 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 889bfe61-8c21-436b-bc07-3908050c8236 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: 4beKTGOy3+x8nwS8ZhFKIU6q0TRqFwKyBXSVUPi4bTSP85vNhQon6sxNIMHgbT3g6XRmGk7FD/sKlbvi9gFQ4YVX6s6N88p7jWYRisRvOc8= X-MS-Exchange-Transport-CrossTenantHeadersStamped: TYZPR02MB5764 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20241104_014559_355669_040A77D9 X-CRM114-Status: UNSURE ( 7.85 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-mediatek@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "Linux-mediatek" Errors-To: linux-mediatek-bounces+linux-mediatek=archiver.kernel.org@lists.infradead.org Unify the column width of the document to comply with specifications. Signed-off-by: Jinjian Song --- .../networking/device_drivers/wwan/t7xx.rst | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/Documentation/networking/device_drivers/wwan/t7xx.rst b/Documentation/networking/device_drivers/wwan/t7xx.rst index 4cf777c341cd..e07de7700dfc 100644 --- a/Documentation/networking/device_drivers/wwan/t7xx.rst +++ b/Documentation/networking/device_drivers/wwan/t7xx.rst @@ -7,12 +7,13 @@ ============================================ t7xx driver for MTK PCIe based T700 5G modem ============================================ -The t7xx driver is a WWAN PCIe host driver developed for linux or Chrome OS platforms -for data exchange over PCIe interface between Host platform & MediaTek's T700 5G modem. -The driver exposes an interface conforming to the MBIM protocol [1]. Any front end -application (e.g. Modem Manager) could easily manage the MBIM interface to enable -data communication towards WWAN. The driver also provides an interface to interact -with the MediaTek's modem via AT commands. +The t7xx driver is a WWAN PCIe host driver developed for linux or Chrome OS +platforms for data exchange over PCIe interface between Host platform & +MediaTek's T700 5G modem. +The driver exposes an interface conforming to the MBIM protocol [1]. Any front +end application (e.g. Modem Manager) could easily manage the MBIM interface to +enable data communication towards WWAN. The driver also provides an interface +to interact with the MediaTek's modem via AT commands. Basic usage =========== @@ -45,8 +46,8 @@ The driver provides sysfs interfaces to userspace. t7xx_mode --------- -The sysfs interface provides userspace with access to the device mode, this interface -supports read and write operations. +The sysfs interface provides userspace with access to the device mode, this +interface supports read and write operations. Device mode: