site_archiver@lists.apple.com Delivered-To: darwin-dev@lists.apple.com Dkim-signature: v=1; a=rsa-sha1; c=relaxed; d=pobox.com; h=content-type :mime-version:subject:from:in-reply-to:date :content-transfer-encoding:message-id:references:to; s=sasl; bh= aGVF0FLoicx35PAP2xQSlFy+Af8=; b=c9Y7pVAarzsavnEgYuspG1g6km3nWsSF g2eG+AFeog0a/pcJw78vDfMcM1yE2PsnilOk1MlNFmPxNxPsiuvWe+sij/8v0pLE HK1J7JHdmEFpXAnJxBl5ytjtEYAc/U54Iu5LDqtwMT4dVlg8NdZ22xsfw+YLtWIm AJX6DjlgknM= Domainkey-signature: a=rsa-sha1; c=nofws; d=pobox.com; h=content-type :mime-version:subject:from:in-reply-to:date :content-transfer-encoding:message-id:references:to; q=dns; s= sasl; b=bMRP68s8di91Zq74GKBXQAI44QCEoDxI90Np8f+J1iylEcea+pSZlUZ7 jOCTP/gCN3JrNZXYZkwq38zIA+/5OYFBVhBGAzmtG1ZWqm2YKvhlhdAkna/iCWqt ao3pcbTBuO11VWw8AeCKGkB+HI0vHEsMyXGlXTkwjshnhqnATSA= On Apr 29, 2010, at 9:05 PM, Terry Lambert wrote:
On Apr 29, 2010, at 7:51 PM, Andrew James wrote:
Hi Guys,
I'm trying to initiate a forced shutdown from inside a KEXT, this is to meet certain requirements of a piece of hardware.
The only solutions I've found was to pass a signal to a application which then uses APIs not available to KEXTs.
Does anyone have a better solutions? I would prefer it to be integrated into a single KEXT
You can not do this. launchd is responsible for the orderly shutdown of they system.
It's even worse than that. launchd is only capable of performing orderly shutdown of the "Unix-y side" of the world. Cocoa/Carbon/Java/... Applications are not expected to or typically coded to handle a SIGTERM. loginwindow takes care of performing application terminations, then tells launchd to proceed. Hence while invoking shutdown / reboot might work, there is a good chance that data loss will occur at the upper levels. Eric
For a disorderly shutdown, there's always:
panic("I can't shut down the system from a KEXT, so I am calling panic instead");
8-)
-- Terry _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-dev mailing list (Darwin-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-dev/eric.gouriou%40pobox.com
This email sent to eric.gouriou@pobox.com
_______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-dev mailing list (Darwin-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-dev/site_archiver%40lists.appl... This email sent to site_archiver@lists.apple.com
participants (1)
-
Eric Gouriou