Re: link state missing error on 10.6
site_archiver@lists.apple.com Delivered-To: darwin-kernel@lists.apple.com Please file a bug report with a sample kext project that demonstrates the problem. https://bugreport.apple.com/ -Andrew On Jan 27, 2010, at 10:23 AM, Michael Eddington wrote:
Lets forget for a second that I mentioned nsysent. We have what looks like broken functionality between 10.5 and 10.6. A kext that uses com.apple.kernel as it's dependencies will pass the initial checks for kext loading, try to be loaded and then the loader will bail out when it finds a null pointer.
Here is the code I found for OSKext.cpp that issues the error message.
From OSKext::loadExecutable():
if (isKernelComponent()) { OSData * kernelLinkState = OSKext::getKernelLinkState(); kxlddeps[0] = (u_char *)kernelLinkState->getBytesNoCopy(); } else for (i = 0; i < num_kxlddeps; i++) { OSKext * dependency = OSDynamicCast(OSKext, dependencies->getObject(i)); if (!dependency->linkState) { // xxx - maybe we should panic here OSKextLog(this, kOSKextLogErrorLevel | kOSKextLogLoadFlag | kOSKextLogLinkFlag, "Can't load kext %s - link state missing.", getIdentifierCString()); goto finish; } kxlddeps[i] = (u_char *)dependency->linkState->getBytesNoCopy(); assert(kxlddeps[i]); }
-mike
On Tue, Jan 26, 2010 at 9:35 PM, Michael Smith <drivers@mu.org> wrote:
On Jan 26, 2010, at 2:55 PM, Michael Eddington wrote:
This only appears to happen when my OSBundleLibraries has "com.apple.kernel" "10.2.0" as the dependencies. If I just use, com.apple.kernel.bsd or something it will load fine. Sadly I need to depend on the full com.apple.kernel to resolve nsysent it looks like.
nsysent is only interesting if you are trying to patch the syscall table, which is not supported (or generally a good idea). = Mike -- Ars longa, vita brevis, occasio praeceps, experimentum periculosum, iudicium difficile -- Hippocrates
_______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-kernel mailing list (Darwin-kernel@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-kernel/amyrick%40apple.com
This email sent to amyrick@apple.com
_______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-kernel mailing list (Darwin-kernel@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-kernel/site_archiver%40lists.a... This email sent to site_archiver@lists.apple.com
participants (1)
-
Andrew Myrick