From owner-freebsd-hackers@FreeBSD.ORG Mon Aug 3 19:52:06 2009 Return-Path: Delivered-To: hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4F8471065672 for ; Mon, 3 Aug 2009 19:52:06 +0000 (UTC) (envelope-from des@des.no) Received: from tim.des.no (tim.des.no [194.63.250.121]) by mx1.freebsd.org (Postfix) with ESMTP id 1375F8FC14 for ; Mon, 3 Aug 2009 19:52:05 +0000 (UTC) (envelope-from des@des.no) Received: from ds4.des.no (des.no [84.49.246.2]) by smtp.des.no (Postfix) with ESMTP id DC66B6D41C; Mon, 3 Aug 2009 19:52:04 +0000 (UTC) Received: by ds4.des.no (Postfix, from userid 1001) id BAA15844DC; Mon, 3 Aug 2009 21:52:04 +0200 (CEST) From: =?utf-8?Q?Dag-Erling_Sm=C3=B8rgrav?= To: Maslan References: <319cceca0908030119i3432a495ya60aa431dab0e1b1@mail.gmail.com> <864ospvvkv.fsf@ds4.des.no> <319cceca0908031043x6bfe5771wa73553dce922756a@mail.gmail.com> Date: Mon, 03 Aug 2009 21:52:04 +0200 In-Reply-To: <319cceca0908031043x6bfe5771wa73553dce922756a@mail.gmail.com> (Maslan's message of "Mon, 3 Aug 2009 17:43:14 +0000") Message-ID: <86eirs65gb.fsf@ds4.des.no> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.92 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Cc: hackers@freebsd.org Subject: Re: sosend() and mbuf X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Aug 2009 19:52:06 -0000 [please cc: the list] Maslan writes: > man 9 sosend: > Data may be sent directly from kernel or user memory via the uio > argument, or as an mbuf chain via top, avoid- ing a data copy. > Only one of the uio or top pointers may be non-NULL Hmm, I missed that part. It never occurred to me to *not* use mbufs. I guess the question is: what is your question? Does your code work? If it doesn't, where and how does it fail? If it does, why are you asking? In any case, 'man 9 sosend' answers the "I can't find useful information on sosend()" part of your email. If you still have questions after reading that, try looking at existing kernel code that uses sosend(9) with iovecs (or with mbufs, if you decide to go that route). DES --=20 Dag-Erling Sm=C3=B8rgrav - des@des.no