Re: cross Arch communication to NKE?
Re: cross Arch communication to NKE?
- Subject: Re: cross Arch communication to NKE?
- From: Josh Graessley <email@hidden>
- Date: Thu, 26 Jan 2006 15:52:49 -0800
No.
One of the challenges here is that on Intel, your kext is running
little endian. Your user space process is running in big endian in
Rosetta. For many common ioctls, there is code, I believe in Rosetta,
to translate the ioctl code itself as well as parameters from big
endian to little endian. The CTLIOGINFO ioctl for the
SYSPROTO_CONTROL protocol is not supported. Were it supported, the
kext would have to determine the byte order of the client since the
kernel can not know the format of data passed between the user space
process and the kext.
In addition to making your kext a universal binary, you also need to
make the client that talks to your kext a universal binary.
-josh
On Jan 26, 2006, at 3:26 PM, Vinnie Moscaritolo wrote:
Is communication from allowed from an app running in Rosetta to an
intel NKE?
I have a fat NKE installed. I seem to be able to communicate to it
to some
extent when my app is running under intel, but when my app runs
under PPC
I get an exeception.
Specifically I do the following:
#define MY_NKE_KEXT_NAME "com.me.kext.mynke"
struct ctl_info ctl_info;
int sock;
/* open socket to NKE*/
if( (sock = socket(PF_SYSTEM, SOCK_STREAM, SYSPROTO_CONTROL)) == -1)
RETERR(kPGPError_ResourceUnavailable);
/* get NKE ID */
bzero(&ctl_info, sizeof(struct ctl_info));
strcpy(ctl_info.ctl_name, MY_NKE_KEXT_NAME);
if (ioctl(sock, CTLIOCGINFO, &ctl_info) == -1)
RETERR(kPGPError_FeatureNotAvailable);
and when making the ioctl, my app dies with SIGILL
"Unhandled transform (1) for ioctl group = 78 (N), number = 3,
length = 100"
what does this mean?
--
Vinnie Moscaritolo ITCB-IMSH
PGP: 3F903472C3AF622D5D918D9BD8B100090B3EF042
-------------------------------------------------------
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-kernel mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
40apple.com
This email sent to email@hidden
Attachment:
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-kernel mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden