RE: IOEthernetController and USB problem
RE: IOEthernetController and USB problem
- Subject: RE: IOEthernetController and USB problem
- From: "Beard Rex (Aepix)" <email@hidden>
- Date: Fri, 8 Mar 2002 08:56:40 -0500
I started this thread.
I guess I could answer some of it. The crash when you
set the interface to down with "ifconfig en1 down" after
a USB unplug was my fault. I was using one of the USB
pointers after I'd free'd it and set it to NULL.
I was also figured out how to eliminate the error message:
"mach_kernel: WARNING - dll_if_detach called for UP interface"
I created my own interface class inherited from IOEthernetInterface
and overrode setInterfaceState(). That let me mark the interface
flags as not UP (i.e. down) before the IONetworkStack called
dlil_if_detach().
BUT, I still have problems (on OS 10.1):
1> The network interface never goes away completely. I can not
kextunload my driver. And I can't just replug USB and have
it all work again. HOW DO I WORK AROUND THIS.
2> How do I interpret the Mac crash text? When OS X crashes
it prints a little useful information like a stack back
trace. But it is only the addresses. Where can I find
the symbol table map to look those addresses up????
-rex-
>
-----Original Message-----
>
From: Beard Rex (Aepix)
>
There are a lot of questions here...
>
>
I'm making a driver that inherits from IOEthernetController
>
with an IOUSBDevice as it's provider class on OS 10.1
>
>
I'm able to install and load and bring it up and pass network traffic.
>
>
But when I unplug the USB cable I start to have problems.
>
>
1> The network interface never disappears. I still see it with
>
ifconfig -a. I can't unload my driver with kextunload.
>
(If my driver didn't come all the way up and running I can
>
kextunload it just fine, but not if the interface is brought
>
all the way up.)
>
If I plug my USB device in again it won't work the second time.
>
I do see a syslog message when I unplug the cable:
>
"mach_kernel: WARNING - dll_if_detach called for UP interface"
>
>
2> When I try to mark the interface as "down" --ifconfig en1 down --
>
the Mac crashes. I'd like to be able to interpret that
>
crash dump.
>
(I don't have a separate machine for debug) I want to look at
>
the addresses in the stack back trace and match those with
>
my function addresses, but I can't find any sort of symbol table
>
map created by Project Builder. Is there any?
>
>
Do I need to some how register with some USB thing to be
>
called on unplugs?
>
If I do, just what code should I run to bring down the
>
interface gracefully?
>
>
thanks
>
>
Rex Beard <email@hidden>
>
_______________________________________________
>
macnetworkprog mailing list | email@hidden
>
Help/Unsubscribe/Archives:
>
http://www.lists.apple.com/mailman/listinfo/macnetworkprog
>
Do not post admin requests to the list. They will be ignored.
_______________________________________________
macnetworkprog mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/macnetworkprog
Do not post admin requests to the list. They will be ignored.