Re: Passing a char** to a Kext from user mode
Thanks Changing the char** to a string buffer (char*[]) solved and then using copyinstr solved the problem. I am curious Aren't GetProperty()/SetProperty() for only for for modifying registry entries? --- Marek Kozubal <marek@portents.com> wrote:
On Fri, 2 Jul 2004, Marek Kozubal wrote:
Generally, you send a pointer (ie char *) to your
kext via some
communications method. Then inside the kernel you
use copyinstr()/copyin()
to get the string into the kernel, or
copyoutstr()/copyout() to put it back
to user space. You don't use a char **. You have
to create a buffer in user
space, then create a buffer in kernel space and
copy the data back and forth.
I just realized, that I should have mentioned this
is for kext's that are
not IOKit kext's. If you're in IOKit you use
GetProperty()/SetProperty()
type methods.
---
Marek Kozubal
marek@portents.com
__________________________________ Do you Yahoo!? Yahoo! Mail - 50x more storage than other providers! http://promotions.yahoo.com/new_mail _______________________________________________ darwin-kernel mailing list | darwin-kernel@lists.apple.com Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/darwin-kernel Do not post admin requests to the list. They will be ignored.
participants (1)
-
Krishna Monian