From owner-freebsd-questions@FreeBSD.ORG Thu Dec 2 02:42:13 2004 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7F73316A4CF for ; Thu, 2 Dec 2004 02:42:13 +0000 (GMT) Received: from web15311.mail.bjs.yahoo.com (web15311.mail.cnb.yahoo.com [202.43.216.186]) by mx1.FreeBSD.org (Postfix) with SMTP id 37EDD43D49 for ; Thu, 2 Dec 2004 02:42:11 +0000 (GMT) (envelope-from beatlelittle@yahoo.com.cn) Message-ID: <20041202024210.50483.qmail@web15311.mail.bjs.yahoo.com> Received: from [220.194.103.228] by web15311.mail.cnb.yahoo.com via HTTP; Thu, 02 Dec 2004 10:42:10 CST Date: Thu, 2 Dec 2004 10:42:10 +0800 (CST) From: cm c To: Brian Bobowski In-Reply-To: <41AE7C93.2010707@cogeco.ca> MIME-Version: 1.0 Content-Type: text/plain; charset=gb2312 Content-Transfer-Encoding: 8bit X-Content-Filtered-By: Mailman/MimeDel 2.1.1 cc: freebsd-questions@freebsd.org Subject: Re: Why can't I do "mknod /dev/cdev c 32 0" X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 02 Dec 2004 02:42:13 -0000 The output of 'uname -a' is: FreeBSD .itc.inventec 5.1-RELEASE FreeBSD 5.1-RELEASE #0: Thu Jun 5 02:55:42 GMT 2003 root@wv1u.btc.adaptec.com:/usr/obj/usr/src/sys/GENERIC i386 It's 5.x, but if the node is created automatically, how do I use open? I mean, under linux, user space processes need do 'open("/dev/cdev") before do other things, can /dev/cdev be created automatically? I don't think so. Brian Bobowski wrote: cm c wrote: >I'm a newbie to freebsd. I'm trying to port a simple driver to freebsd, but something stopped me. I tried to use the /usr/share/examples to have a test, but mknod failed : > mknod /dev/cdev c 32 0 >even the make_dev call will cause system rebooting! > >I don't know why. >Who can help me? >thanks. > > If you are using FreeBSD 5.x, the devfs makes mknod irrelevant; device nodes are created automatically. That's all I know on the subject. The gurus(which I am not) will probably need more information to help you at all; the output of "uname -a" is standard. Information about what you're trying to port will likely be key as well. -BB _______________________________________________ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "freebsd-questions-unsubscribe@freebsd.org" --------------------------------- Do You Yahoo!? 注册世界一流品质的雅虎免费电邮