From owner-freebsd-hackers@FreeBSD.ORG Thu Apr 26 19:08:44 2007 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 7DB4316A401 for ; Thu, 26 Apr 2007 19:08:44 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from server.baldwin.cx (66-23-211-162.clients.speedfactory.net [66.23.211.162]) by mx1.freebsd.org (Postfix) with ESMTP id D685B13C45E for ; Thu, 26 Apr 2007 19:08:43 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from localhost.corp.yahoo.com (john@localhost [127.0.0.1]) (authenticated bits=0) by server.baldwin.cx (8.13.8/8.13.8) with ESMTP id l3QJ8dGr077259; Thu, 26 Apr 2007 15:08:40 -0400 (EDT) (envelope-from jhb@freebsd.org) From: John Baldwin To: freebsd-hackers@freebsd.org Date: Thu, 26 Apr 2007 13:49:35 -0400 User-Agent: KMail/1.9.6 References: <200704261408.19885.marc.loerner@hob.de> In-Reply-To: <200704261408.19885.marc.loerner@hob.de> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Message-Id: <200704261349.35661.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH authentication, not delayed by milter-greylist-2.0.2 (server.baldwin.cx [127.0.0.1]); Thu, 26 Apr 2007 15:08:40 -0400 (EDT) X-Virus-Scanned: ClamAV 0.88.3/3165/Thu Apr 26 09:03:24 2007 on server.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-4.4 required=4.2 tests=ALL_TRUSTED,BAYES_00 autolearn=ham version=3.1.3 X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on server.baldwin.cx Cc: Marc =?iso-8859-1?q?L=F6rner?= Subject: Re: Usage of kern_* functions in kernel 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: Thu, 26 Apr 2007 19:08:44 -0000 On Thursday 26 April 2007 08:08:19 am Marc L=F6rner wrote: > Hello, > I googled but found nothing about the usage of the kern_* functions=20 > (kern_open, kern_close, kern_pwritev, kern_preadv) that are located in=20 > vfs_syscalls.c >=20 > When I use kern_open to open a file within the kernel, I get an error.=20 > When I use the normal vn_open function instead, all works well. >=20 > So my question is which functions are recommended by you kernel-hackers=20 > for use within kernelspace? >=20 > And here a second question: Is it possible to open/use the console driver= in=20 > kernelspace within the functions mentioned above?=20 > If not, can you give me some pointers on where I can find this informatio= n! kern_XXX are generally used by system calls such as alternative ABIs, etc. =2D-=20 John Baldwin