Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 16 Mar 2021 19:12:57 +0000
From:      bugzilla-noreply@freebsd.org
To:        usb@FreeBSD.org
Subject:   [Bug 254345] cdce erroneously attaches to a combined RNDIS/CDCE Ethernet gadget
Message-ID:  <bug-254345-19105@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D254345

            Bug ID: 254345
           Summary: cdce erroneously attaches to a combined RNDIS/CDCE
                    Ethernet gadget
           Product: Base System
           Version: CURRENT
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: usb
          Assignee: usb@FreeBSD.org
          Reporter: d8zNeCFG@aon.at

Created attachment 223335
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=3D223335&action=
=3Dedit
files mentioned in the bug report

Scenario:
- Raspberry Pi B+
- FreeBSD main at 51dfae383bf6298af9e6d816a78b92b6f34d68be
- (Physically) attaching a combined RNDIS/CDCE Ethernet gadget: configurati=
on 0
supports RNDIS, configuration 1 supports CDCE (see the attached output of
"usbconfig dump_all_desc"
- The current configuration is 0, see the attached output of "usbconfig
dump_curr_config_desc"
- devd with a default configuration plus a special configuration for a Huaw=
ei
4G modem is running; the special configuration matches this device (althoug=
h it
really should not, but this is not the point of this PR); the special devd
configuration file is attached ("e3372.conf")

Result:
- Two ue interfaces are created, one attached to interface 0 of the RNDIS
device, the other to interface 1; see the attached output of "devinfo -rv"

Expected result:
- Since configuration 0 is active, only one network interface for the RNDIS
device should be created; this network interface must make use of the two U=
SB
interfaces (0, 1, see above) of USB configuration 0 of the device, see
https://docs.microsoft.com/de-at/windows-hardware/drivers/network/overview
- The CDCE driver should not attach at all to this device as long as it is =
in
USB configuration 0.

Notes:
- I am not an expert here so my analysis may be wrong. :-)
- It is important not to mix the notions of "USB interface" and "network
interface" when checking this PR.
- There is a major issue with devd and the ue USB Ethernet interfaces becau=
se
the available information does not allow devd to determine which device it =
is
really dealing with. In this case, with e3372.conf a DHCP client is started=
 on
all ue devices; but this is useless for the Ethernet gadget of this PR beca=
use
that needs to have a fixed IP address assigned which is impossible to achie=
ve
with devd rules as long as the real E3372 offers a DHCP service.
- FreeBSD needs a way to distinguish interfaces by some hardware ID; most
likely the best way would be to create the device as ue-<HW Ethernet addres=
s>.
But this is not the main issue of this bug report; this bug report is about
CDCE erroneously attaching to the data interface of a USB RNDIS device.

-- Martin

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-254345-19105>