site_archiver@lists.apple.com Delivered-To: darwin-kernel@lists.apple.com Thread-index: AcVE+ZiCeJb5zamsRlK/Y1su+nF9sgAEfFFQ Thread-topic: Using ctl_enqueuembuf Ok thinking.... I am coping the sizeof the structure. Now only because I was looking at the TCPlogger example, which passed a rather large structure 'struct TCPLogEntry', in which it had sub structures and in turn had buffers with log data, that I thought the mbuf code took care of the structure and everything in it. But the total data, would be the sizeof the struct plus the sizeof buf1. I guess I am not clear on how to get buf1 up to userland using ctl_enqueuembuf. Do I need to make two calls to ctl_enqueuembuf, with the struct then the buf1? Of is there a way to get both buffers into my mbuf? Then if I have to make two calls to ctl_enqueuembuf, in the kernel side, I am not certain how 'catch' it in user land? Thanks Carl -----Original Message----- From: darwin-kernel-bounces+csmith=fortresstech.com@lists.apple.com [mailto:darwin-kernel-bounces+csmith=fortresstech.com@lists.apple.com] On Behalf Of Justin Walker Sent: Tuesday, April 19, 2005 12:01 PM To: darwin-kernel Dev Subject: Re: Using ctl_enqueuembuf On Apr 19, 2005, at 8:17, Carl Smith wrote:
I am using the function ctl_enqueuembuf to pass data up to my userland
process from my NKE. My problem lies in that I am passing a structure that has some pointers to buffers within this structure and these buffers are always showing empty/zeros when I receive them on the userland side. I am using the example from TCPlogger, in how TCPlogger
is passing a structure up to it's user land, but for some reason for me it is not working.
Here's a hint: how much data are you copying up to user space, and what is in that data? Regards, Justin -- Justin C. Walker, Curmudgeon-At-Large Institute for General Semantics -------- If you're not confused, You're not paying attention -------- _______________________________________________ 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/csmith%40fortresste ch.com This email sent to csmith@fortresstech.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)
-
Carl Smith