You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For reasons I don't entirely understand (and a brief rummage through I/O Kit (shudder) didn't enlighten me) it appears that the enXX enumeration issue is related to MAC addresses changing. I'll guess it's something related to SystemConfiguration management that forces enumeration of a new device because it's not been seen before.
Allow me to demonstrate.
Tether a phone.
Do ioreg -l | grep IOMACAddress > snap.a
Untether the phone. I opt to simply unplug it (yes, yes, it could panic, I know, but 99 times out of 100 it doesn't) to make sure it's nicely forgotten about.
Tether the phone.
Do ioreg -l | grep IOMACAddress > snap.b
diff -u snap.a snap.b
I've deliberately left the MAC addresses that the interface uses unmangled to demonstrate that they are so different, and also because they're basically transient LAAs.
Yeah, this is kind of what I figured was going on. The thing that still boggles me is that I don't understand why it works after people rm the NetworkInterfaces plist! Why would that help? What does recreating it do?
One thing that might be interesting, although a violation of the RNDIS spec, would be to hash the device serial number to get a MAC address instead.
Really, I'd like to modify the IOKit side to get it to do what I want, but I don't see an easy path to do that. When I tried modifying IOKit parameters before -- for instance, changing the 'ethernet' icon to a 'phone' icon by changing the device class, or changing the 'en' prefix to 'rndis' to make it easier to identify these devices, I would somehow manage to permanently wedge the driver stack until I rebooted. (I gave up doing that after getting frustrated after having to reboot the machine for the fourth or fifth time to continue development.)
By the way, untethering vs. unplugging shouldn't change whether the system crashes. Both appear the same to the Mac side.
For reasons I don't entirely understand (and a brief rummage through I/O Kit (shudder) didn't enlighten me) it appears that the enXX enumeration issue is related to MAC addresses changing. I'll guess it's something related to SystemConfiguration management that forces enumeration of a new device because it's not been seen before.
Allow me to demonstrate.
ioreg -l | grep IOMACAddress > snap.a
ioreg -l | grep IOMACAddress > snap.b
diff -u snap.a snap.b
I've deliberately left the MAC addresses that the interface uses unmangled to demonstrate that they are so different, and also because they're basically transient LAAs.
That's not the only place; in the hundred-odd examples I have in NetworkInterfaces.plist, the IOMacAddress data changes.
I haven't checked this on any other platforms or with other phones, but I suspect this is where the issue is coming from.
The text was updated successfully, but these errors were encountered: