From owner-freebsd-questions Fri Oct 6 5:24:16 2000 Delivered-To: freebsd-questions@freebsd.org Received: from hotmail.com (f152.pav1.hotmail.com [64.4.31.152]) by hub.freebsd.org (Postfix) with ESMTP id 1844637B66D for ; Fri, 6 Oct 2000 05:24:14 -0700 (PDT) Received: from mail pickup service by hotmail.com with Microsoft SMTPSVC; Fri, 6 Oct 2000 03:33:17 -0700 Received: from 61.151.176.195 by pv1fd.pav1.hotmail.msn.com with HTTP; Fri, 06 Oct 2000 10:33:17 GMT X-Originating-IP: [61.151.176.195] From: "bsdnewbie bsdnewbie" To: freebsd-questions@FreeBSD.org Subject: _How to get a free major number for a new device Date: Fri, 06 Oct 2000 18:33:17 CST Mime-Version: 1.0 Content-Type: text/plain; format=flowed Message-ID: X-OriginalArrivalTime: 06 Oct 2000 10:33:17.0453 (UTC) FILETIME=[D6ECB3D0:01C02F80] Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG I began to write device drivers. My problem is: 1) How to determine the major number for my drv so it will not conflict with any other devs. In Linux, when a dev drv register with the major 0, the system will alloc a free major number. Is there any mecahnism like this in FreeBSD? 2) I want to write a shell program to automatically "mknod", how to know the major number of a dev when driver loaded? In Linux, by referring the file /proc/devices I can know the major number of a device, but the /proc in FreeBSD does not has such a file. Thanks best regards, bsdnewbie Oct 6, 2k _________________________________________________________________________ Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com. Share information about yourself, create your own public profile at http://profiles.msn.com. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message