From: Yanchao Yang <yanchao.yang@mediatek.com>
To: Loic Poulain <loic.poulain@linaro.org>,
Sergey Ryazanov <ryazanov.s.a@gmail.com>,
Johannes Berg <johannes@sipsolutions.net>,
"David S . Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
netdev ML <netdev@vger.kernel.org>,
kernel ML <linux-kernel@vger.kernel.org>
Cc: Intel experts <linuxwwan@intel.com>,
Chetan <m.chetan.kumar@intel.com>,
MTK ML <linux-mediatek@lists.infradead.org>,
Liang Lu <liang.lu@mediatek.com>,
Haijun Liu <haijun.liu@mediatek.com>,
Hua Yang <hua.yang@mediatek.com>,
Ting Wang <ting.wang@mediatek.com>,
Felix Chen <felix.chen@mediatek.com>,
Mingliang Xu <mingliang.xu@mediatek.com>,
Min Dong <min.dong@mediatek.com>,
Aiden Wang <aiden.wang@mediatek.com>,
Guohao Zhang <guohao.zhang@mediatek.com>,
Chris Feng <chris.feng@mediatek.com>,
Yanchao Yang <yanchao.yang@mediatek.com>,
Lambert Wang <lambert.wang@mediatek.com>,
Mingchuang Qiao <mingchuang.qiao@mediatek.com>,
Xiayu Zhang <xiayu.zhang@mediatek.com>,
Haozhe Chang <haozhe.chang@mediatek.com>
Subject: [PATCH net-next v3 00/10] net: wwan: tmi: PCIe driver for MediaTek M.2 modem
Date: Sat, 11 Feb 2023 16:37:22 +0800 [thread overview]
Message-ID: <20230211083732.193650-1-yanchao.yang@mediatek.com> (raw)
TMI(T-series Modem Interface) is the PCIe host device driver for MediaTek's
modem. The driver uses the WWAN framework infrastructure to create the
following control ports and network interfaces for data transactions.
* /dev/wwan0at0 - Interface that supports AT commands.
* /dev/wwan0mbim0 - Interface conforming to the MBIM protocol.
* wwan0-X - Primary network interface for IP traffic.
The main blocks in the TMI driver are:
* HW layer - Abstracts the hardware bus operations for the device, and
provides generic interfaces for the transaction layer to get the device's
information and control the device's behavior. It includes:
* PCIe - Implements probe, removal and interrupt handling.
* MHCCIF (Modem Host Cross-Core Interface) - Provides interrupt channels
for bidirectional event notification such as handshake and port enumeration.
* Transaction layer - Implements data transactions for the control plane
and the data plane. It includes:
* DPMAIF (Data Plane Modem AP Interface) - Controls the hardware that
provides uplink and downlink queues for the data path. The data exchange
takes place using circular buffers to share data buffer addresses and
metadata to describe the packets.
* CLDMA (Cross Layer DMA) - Manages the hardware used by the port layer
to send control messages to the device using MediaTek's CCCI (Cross-Core
Communication Interface) protocol.
* TX Services - Dispatch packets from the port layer to the device.
* RX Services - Dispatch packets to the port layer when receiving packets
from the device.
* Port layer - Provides control plane and data plane interfaces to userspace.
It includes:
* Control Plane - Provides device node interfaces for controlling data
transactions.
* Data Plane - Provides network link interfaces wwanX (0, 1, 2...) for IP
data transactions.
* Core logic - Contains the core logic to keep the device working.
It includes:
* FSM (Finite State Machine) - Monitors the state of the device, and
notifies each module when the state changes.
The compilation of the TMI driver is enabled by the CONFIG_MTK_TMI config
option which depends on CONFIG_WWAN.
List of contributors:
Min Dong <min.dong@mediatek.com>
Ting Wang <ting.wang@mediatek.com>
Hua Yang <hua.yang@mediatek.com>
Mingliang Xu <mingliang.xu@mediatek.com>
Felix Chen <felix.chen@mediatek.com>
Aiden Wang <aiden.wang@mediatek.com>
Guohao Zhang <guohao.zhang@mediatek.com>
Chris Feng <chris.feng@mediatek.com>
Yanchao Yang <yanchao.yang@mediatek.com>
Michael Cai <michael.cai@mediatek.com>
Lambert Wang <lambert.wang@mediatek.com>
Mingchuang Qiao <mingchuang.qiao@mediatek.com>
Xiayu Zhang <xiayu.zhang@mediatek.com>
Haozhe Chang <haozhe.chang@mediatek.com>
V3:
- Remove exception handling and power management modules, and reduce data plane's features, etc.
V2:
- Remove wrapper function, use kernel interfaces instead, ex, dma_map_single, dma_pool_zalloc, ...
- Refine comments to meet kerneldoc format specification.
- Use interfaces in bitfield.h to perform bitmask related operations.
- Remove unused functions from patch-1.
- Remove patch2 (net: wwan: tmi: Add buffer management).
Yanchao Yang (10):
net: wwan: tmi: Add PCIe core
net: wwan: tmi: Add control plane transaction layer
net: wwan: tmi: Add control DMA interface
net: wwan: tmi: Add control port
net: wwan: tmi: Add FSM thread
net: wwan: tmi: Add AT & MBIM WWAN ports
net: wwan: tmi: Introduce data plane hardware interface
net: wwan: tmi: Add data plane transaction layer
net: wwan: tmi: Introduce WWAN interface
net: wwan: tmi: Add maintainers and documentation
.../networking/device_drivers/wwan/index.rst | 1 +
.../networking/device_drivers/wwan/tmi.rst | 48 +
MAINTAINERS | 11 +
drivers/net/wwan/Kconfig | 14 +
drivers/net/wwan/Makefile | 1 +
drivers/net/wwan/mediatek/Makefile | 21 +
drivers/net/wwan/mediatek/mtk_cldma.c | 280 ++
drivers/net/wwan/mediatek/mtk_cldma.h | 160 +
drivers/net/wwan/mediatek/mtk_common.h | 30 +
drivers/net/wwan/mediatek/mtk_ctrl_plane.c | 441 +++
drivers/net/wwan/mediatek/mtk_ctrl_plane.h | 111 +
drivers/net/wwan/mediatek/mtk_data_plane.h | 103 +
drivers/net/wwan/mediatek/mtk_dev.c | 50 +
drivers/net/wwan/mediatek/mtk_dev.h | 382 ++
drivers/net/wwan/mediatek/mtk_dpmaif.c | 3093 +++++++++++++++++
drivers/net/wwan/mediatek/mtk_dpmaif_drv.h | 201 ++
drivers/net/wwan/mediatek/mtk_fsm.c | 998 ++++++
drivers/net/wwan/mediatek/mtk_fsm.h | 153 +
drivers/net/wwan/mediatek/mtk_port.c | 1256 +++++++
drivers/net/wwan/mediatek/mtk_port.h | 299 ++
drivers/net/wwan/mediatek/mtk_port_io.c | 625 ++++
drivers/net/wwan/mediatek/mtk_port_io.h | 45 +
drivers/net/wwan/mediatek/mtk_wwan.c | 589 ++++
.../wwan/mediatek/pcie/mtk_cldma_drv_t800.c | 939 +++++
.../wwan/mediatek/pcie/mtk_cldma_drv_t800.h | 22 +
.../wwan/mediatek/pcie/mtk_dpmaif_drv_t800.c | 1622 +++++++++
.../wwan/mediatek/pcie/mtk_dpmaif_reg_t800.h | 357 ++
drivers/net/wwan/mediatek/pcie/mtk_pci.c | 1020 ++++++
drivers/net/wwan/mediatek/pcie/mtk_pci.h | 148 +
drivers/net/wwan/mediatek/pcie/mtk_reg.h | 80 +
30 files changed, 13100 insertions(+)
create mode 100644 Documentation/networking/device_drivers/wwan/tmi.rst
create mode 100644 drivers/net/wwan/mediatek/Makefile
create mode 100644 drivers/net/wwan/mediatek/mtk_cldma.c
create mode 100644 drivers/net/wwan/mediatek/mtk_cldma.h
create mode 100644 drivers/net/wwan/mediatek/mtk_common.h
create mode 100644 drivers/net/wwan/mediatek/mtk_ctrl_plane.c
create mode 100644 drivers/net/wwan/mediatek/mtk_ctrl_plane.h
create mode 100644 drivers/net/wwan/mediatek/mtk_data_plane.h
create mode 100644 drivers/net/wwan/mediatek/mtk_dev.c
create mode 100644 drivers/net/wwan/mediatek/mtk_dev.h
create mode 100644 drivers/net/wwan/mediatek/mtk_dpmaif.c
create mode 100644 drivers/net/wwan/mediatek/mtk_dpmaif_drv.h
create mode 100644 drivers/net/wwan/mediatek/mtk_fsm.c
create mode 100644 drivers/net/wwan/mediatek/mtk_fsm.h
create mode 100644 drivers/net/wwan/mediatek/mtk_port.c
create mode 100644 drivers/net/wwan/mediatek/mtk_port.h
create mode 100644 drivers/net/wwan/mediatek/mtk_port_io.c
create mode 100644 drivers/net/wwan/mediatek/mtk_port_io.h
create mode 100644 drivers/net/wwan/mediatek/mtk_wwan.c
create mode 100644 drivers/net/wwan/mediatek/pcie/mtk_cldma_drv_t800.c
create mode 100644 drivers/net/wwan/mediatek/pcie/mtk_cldma_drv_t800.h
create mode 100644 drivers/net/wwan/mediatek/pcie/mtk_dpmaif_drv_t800.c
create mode 100644 drivers/net/wwan/mediatek/pcie/mtk_dpmaif_reg_t800.h
create mode 100644 drivers/net/wwan/mediatek/pcie/mtk_pci.c
create mode 100644 drivers/net/wwan/mediatek/pcie/mtk_pci.h
create mode 100644 drivers/net/wwan/mediatek/pcie/mtk_reg.h
--
2.32.0
next reply other threads:[~2023-02-11 8:38 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-02-11 8:37 Yanchao Yang [this message]
2023-02-11 8:37 ` [PATCH net-next v3 01/10] net: wwan: tmi: Add PCIe core Yanchao Yang
2023-02-15 4:22 ` Jakub Kicinski
2023-02-16 12:50 ` Yanchao Yang (杨彦超)
2023-02-16 18:10 ` Jakub Kicinski
2023-02-24 7:39 ` Yanchao Yang (杨彦超)
2023-02-24 19:50 ` Jakub Kicinski
2023-02-27 12:11 ` Yanchao Yang (杨彦超)
2023-02-27 19:00 ` Jakub Kicinski
2023-02-28 7:47 ` Yanchao Yang (杨彦超)
[not found] ` <20230228103132.325def4c@kernel.org>
2023-03-01 3:35 ` Yanchao Yang (杨彦超)
2023-03-01 4:05 ` Jakub Kicinski
2023-03-02 9:08 ` Yanchao Yang (杨彦超)
2023-03-17 8:50 ` Yanchao Yang (杨彦超)
2023-02-11 8:37 ` [PATCH net-next v3 02/10] net: wwan: tmi: Add control plane transaction layer Yanchao Yang
2023-02-11 8:37 ` [PATCH net-next v3 03/10] net: wwan: tmi: Add control DMA interface Yanchao Yang
2023-02-11 8:37 ` [PATCH net-next v3 04/10] net: wwan: tmi: Add control port Yanchao Yang
2023-02-11 8:37 ` [PATCH net-next v3 05/10] net: wwan: tmi: Add FSM thread Yanchao Yang
2023-02-11 8:37 ` [PATCH net-next v3 06/10] net: wwan: tmi: Add AT & MBIM WWAN ports Yanchao Yang
2023-02-11 8:37 ` [PATCH net-next v3 07/10] net: wwan: tmi: Introduce data plane hardware interface Yanchao Yang
2023-02-11 8:37 ` [PATCH net-next v3 08/10] net: wwan: tmi: Add data plane transaction layer Yanchao Yang
2023-02-11 8:37 ` [PATCH net-next v3 09/10] net: wwan: tmi: Introduce WWAN interface Yanchao Yang
2023-02-11 8:37 ` [PATCH net-next v3 10/10] net: wwan: tmi: Add maintainers and documentation Yanchao Yang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230211083732.193650-1-yanchao.yang@mediatek.com \
--to=yanchao.yang@mediatek.com \
--cc=aiden.wang@mediatek.com \
--cc=chris.feng@mediatek.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=felix.chen@mediatek.com \
--cc=guohao.zhang@mediatek.com \
--cc=haijun.liu@mediatek.com \
--cc=haozhe.chang@mediatek.com \
--cc=hua.yang@mediatek.com \
--cc=johannes@sipsolutions.net \
--cc=kuba@kernel.org \
--cc=lambert.wang@mediatek.com \
--cc=liang.lu@mediatek.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mediatek@lists.infradead.org \
--cc=linuxwwan@intel.com \
--cc=loic.poulain@linaro.org \
--cc=m.chetan.kumar@intel.com \
--cc=min.dong@mediatek.com \
--cc=mingchuang.qiao@mediatek.com \
--cc=mingliang.xu@mediatek.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=ryazanov.s.a@gmail.com \
--cc=ting.wang@mediatek.com \
--cc=xiayu.zhang@mediatek.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).