umbim: detect actual connection IP type
authorLech Perczak <lech.perczak@gmail.com>
Mon, 21 Feb 2022 21:48:10 +0000 (22:48 +0100)
committerHauke Mehrtens <hauke@hauke-m.de>
Sat, 29 Apr 2023 19:33:04 +0000 (21:33 +0200)
commit356a6f0eee93ffd03e8f398446ceded144c6237f
tree86e3608ff21f8fcaa7a8ea554aa4974bc3e0cb2b
parentda84eddedbf0abc8e17b0bfbeac53de1bca1a918
umbim: detect actual connection IP type

Current implementation needlessly creates both IPv4 and IPv6
sub-interfaces for single-stack IP types. Limit this only to selected IP
type. While at that, ensure that IP type is also passed to umbim during
"connect" phase. In addition, detect the actual established connection
type returned by umbim and set up subinterfaces according to that,
not to requested configuration. While at that, allow empty IP type explicitly,
interpreted as "any" according to MBIM specification.

Signed-off-by: Lech Perczak <lech.perczak@gmail.com>
package/network/utils/umbim/files/lib/netifd/proto/mbim.sh