I have a kernel that I attach filtering to en0 and en1 using the function call dlil_attach_interface_filter() and when my kernel closes down I use dlil_detach_filter() to release all my filtering. That part works great.
The problem I am having is when from user land, I try to dlil_attach_interface_filter, en1, I get a kernel panic. Now I can attach and detach, en0, all day long with no problem but, and I can also detach en1 using dlil_detach_filter, but only when I try to attach, only en1 using dlil_attach_interface_filter do I get the panic. I have tried a thousand combinations, with dlil_detach_filter and en1 and I can not get the thing to work. Is there something special with attaching en1, which is the AirPort, in this case dynamically once it has been detached?
Some ideas or suggestions would really be some help at this point I am running out of ideas.
And for your info, I am using setsockopt(fd, SYSPROTO_CONTROL, MySetcall, data, datalen) to call into my kernel from my user land.
Thanks
Carl