Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: sosend, soreceive, soconnect



Jim -

I spent several weeks last spring tripping over bugs in the KUNC code so I am very glad to hear that there is an alternate mechanism recommended by Apple. So given the fact that I need to launch an executable every time my driver loads, how do you recommend I do this? Can you give me a url to documentation or the name of a project in Darwin which does it correctly? (The KUNC mechanism is very well documented which is probably why a lot of people are using it.)

The way I ended up dealing with the "wing and a prayer" aspect of KUNCExecute was to keep calling it on my daemon until it sent my driver a tickle. This isn't very elegant but it works.

Thanks in advance for your response.

Tim Standing
SoftRAID, LLC


On Jan 21, 2004, at 10:00 PM, email@hidden wrote:

On Jan 20, 2004, at 5:27 AM, ollie wrote:
You could have your kext either launch the daemon using KUNCExecute or
else have it send a kernel event when ever it requires action from
your daemon. This will remove all polling from your current design.

Please, do NOT use KUNCExecute(). It's a "wing and a prayer" mechanism
(there are many situations where it will fail silently) only added for
people who were too stubborn to switch to the "driver down from the
daemon, not the out from the kernel" model of execution under Mac OS
X/Darwin. Each release, the timing of system boot changes, and
therefore the timing of when KUNCExecute() will succeed also changes.

There are several mechanism available to register the daemon from
user-space for launching only when needed. These are much more
reliable than the KUNCExecute() mechanism, as the user-level
dependencies are always satisfied before the daemon can be registered
in the first place.

--Jim
_______________________________________________
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.



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.