qmi_wwan add_mux/del_mux

Aleksander Morgado aleksander at aleksander.es
Thu Jan 21 16:44:58 UTC 2021


Hey Daniele,

Say I create a new muxed interface for mux id 5:
  echo 5 > /sys/class/net/wwan0/qmi/add_mux
A new qmimux0 interface is created.

Is there any way to know which mux id was used to create the qmimux0
looking just at sysfs or some other way? In other words, how would I
know what the mux id is for a given qmimuxN interface that may not
have been created by me?

Also, say that I have 2 different programs creating this kind of
interfaces, and both use the qmi/add_mux attribute. If they both run
at the same time (asking for different mux ids), and two interfaces
qmimux0 and qmimux1 are created, how can each program know which was
the interface corresponding to the mux id they requested?

Not sure I'm missing something, but I didn't find a way to do this
kind of matchings. If the virtual qmimux interface exposed a sysfs
attribute specifying which is the mux id they correspond to, the
matching would be much easier. Would that be possible?

For context, I'm trying to work on adding support for this interface
in libqmi, with the new qmi_device_add_link() interface that is right
now only available when using rmnet with netlink.

-- 
Aleksander
https://aleksander.es


More information about the libqmi-devel mailing list