Re: [PATCH net-next 10/10] wwan: core: add WWAN common private data for netdev

From
Loic Poulain <hidden>
Date
2021-06-15 07:24:43
Reply to
Sergey Ryazanov, 2021-06-15
Hi Sergey,

On Tue, 15 Jun 2021 at 02:30, Sergey Ryazanov [off-list ref] wrote:
The WWAN core not only multiplex the netdev configuration data, but
process it too, and needs some space to store its private data
associated with the netdev. Add a structure to keep common WWAN core
data. The structure will be stored inside the netdev private data before
WWAN driver private data and have a field to make it easier to access
the driver data. Also add a helper function that simplifies drivers
access to their data.
Would it be possible to store wwan_netdev_priv at the end of priv data instead?
That would allow drivers to use the standard netdev_priv without any change.
And would also simplify forwarding to rmnet (in mhi_net) since rmnet
uses netdev_priv.

Regards,
Loic
At the moment we use the common WWAN private data to store the WWAN data
link (channel) id at the time the link is created, and report it back to
user using the .fill_info() RTNL callback. This should help the user to
be aware which network interface is binded to which WWAN device data
channel.

Signed-off-by: Sergey Ryazanov <ryazanov.s.a@gmail.com>
CC: M Chetan Kumar <redacted>
CC: Intel Corporation <redacted>
---
 drivers/net/mhi/net.c                 | 12 +++++------
 drivers/net/mhi/proto_mbim.c          |  5 +++--
 drivers/net/wwan/iosm/iosm_ipc_wwan.c | 12 +++++------
 drivers/net/wwan/wwan_core.c          | 29 ++++++++++++++++++++++++++-
 include/linux/wwan.h                  | 18 +++++++++++++++++
 5 files changed, 61 insertions(+), 15 deletions(-)
Thread (29 messages) 29 messages, 4 authors, last reply 2021-06-30
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help