Re: Deadlock in My KEXT with NKE
Re: Deadlock in My KEXT with NKE
- Subject: Re: Deadlock in My KEXT with NKE
- From: Vincent Lubet <email@hidden>
- Date: Thu, 12 Feb 2004 13:16:59 -0800
On Feb 12, 2004, at 12:51 PM, matt jaffa wrote:
I understand that this way of doing things, the NKE API, is going to
change eventually, is there a way that i can be kept up to date on
when it changes and etc.?
The best way is be an ADR member, and to be a this mailing list as well
as the Macintosh Network Programming list:
http://www.lists.apple.com/mailman/listinfo/macnetworkprog
I know this is a big no no, I have seen someone doing what I am doing
patching syscalls, this is strongly not recommended right?
You are right.
A correction: the ppp project does not use SYSPROTO_CONTROL sockets.
Sorry, I cannot find an example in Darwin.
Vincent
On Thursday, February 12, 2004, at 12:45 PM, Vincent Lubet wrote:
I do not think that using sysctl as a private communication mechanism
between a KEXT and a daemon is a good idea.
There are many alternative to choose from,:
- local sockets
- device
- SYSPROTO_CONTROL sockets
Because you seem to be using a NKE, I would recommend using a local
socket or a SYSPROTO_CONTROL socket.
SYSPROTO_CONTROL sockets they have be designed to provide a control
mechanism between user space and NKE and you won't have to switch
funnels (looking back into the archive that was first suggesed by
Ollie 2 weeks ago).
There is no man page and no documentation about using
SYSPROTO_CONTROL sockets but you can learn how to use them by looking
at the ppp project. The header file is <sys/sys_domain.h>
Vincent
PS: Always keep in mind the current NKE API is unstable and subject
to change in the future.
On Feb 12, 2004, at 11:04 AM, matt jaffa wrote:
Right now I am having my Daemon do a sysctlbyname and setting a
value in the KEXT to make it aware that it is running, does this
sound like an ok way to do it.
On Thursday, February 12, 2004, at 11:20 AM, Vincent Lubet wrote:
On Feb 11, 2004, at 6:25 PM, Matt Jaffa wrote:
Also is there a way for the KEXT to detect if a daemon is running?
This is done by having the daemon to initiate some kind of
communication channel to the KEXT. This way the daemon becomes a
kind of client of the KEXT. If there are no communication channel,
there is no daemon running.
_______________________________________________
darwin-kernel mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/darwin-kernel
Do not post admin requests to the list. They will be ignored.
_______________________________________________
darwin-kernel mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/darwin-kernel
Do not post admin requests to the list. They will be ignored.