]> git.baikalelectronics.ru Git - kernel.git/commit
net: mhi: Add mbim proto
authorLoic Poulain <loic.poulain@linaro.org>
Tue, 9 Feb 2021 09:05:58 +0000 (10:05 +0100)
committerDavid S. Miller <davem@davemloft.net>
Wed, 10 Feb 2021 23:11:51 +0000 (15:11 -0800)
commitbad3779d09cd9f10e693f58d9f326a60a710142c
tree87271179cf37f26eac907710e07e8b16c05b5900
parent52c350e2d1fabf6fd6420b175f867d0086ce2975
net: mhi: Add mbim proto

MBIM has initially been specified by USB-IF for transporting data (IP)
between a modem and a host over USB. However some modern modems also
support MBIM over PCIe (via MHI). In the same way as QMAP(rmnet), it
allows to aggregate IP packets and to perform context multiplexing.

This change adds minimal MBIM data transport support to MHI, allowing
to support MBIM only modems. MBIM being based on USB NCM, it reuses
and copy some helpers/functions from the USB stack (cdc-ncm, cdc-mbim).

Note that is a subset of the CDC-MBIM specification, supporting only
transport of network data (IP), there is no support for DSS. Moreover
the multi-session (for multi-pdn) is not supported in this initial
version, but will be added latter, and aligned with the cdc-mbim
solution (VLAN tags).

This code has been inspired from the mhi_mbim downstream implementation
(Carl Yin <carl.yin@quectel.com>).

Signed-off-by: Loic Poulain <loic.poulain@linaro.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/mhi/Makefile
drivers/net/mhi/mhi.h
drivers/net/mhi/net.c
drivers/net/mhi/proto_mbim.c [new file with mode: 0644]