From owner-cvs-src@FreeBSD.ORG Thu Aug 28 09:05:10 2003 Return-Path: Delivered-To: cvs-src@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6FB6D16A58C; Thu, 28 Aug 2003 09:05:10 -0700 (PDT) Received: from ns1.xcllnt.net (209-128-86-226.BAYAREA.NET [209.128.86.226]) by mx1.FreeBSD.org (Postfix) with ESMTP id 30BDE43FE3; Thu, 28 Aug 2003 09:05:07 -0700 (PDT) (envelope-from marcel@xcllnt.net) Received: from dhcp01.pn.xcllnt.net (dhcp01.pn.xcllnt.net [192.168.4.201]) by ns1.xcllnt.net (8.12.9/8.12.9) with ESMTP id h7SG4wwO041070; Thu, 28 Aug 2003 09:04:58 -0700 (PDT) (envelope-from marcel@piii.pn.xcllnt.net) Received: from dhcp01.pn.xcllnt.net (localhost [127.0.0.1]) by dhcp01.pn.xcllnt.net (8.12.9/8.12.9) with ESMTP id h7SG4v9S000596; Thu, 28 Aug 2003 16:04:57 GMT (envelope-from marcel@dhcp01.pn.xcllnt.net) Received: (from marcel@localhost) by dhcp01.pn.xcllnt.net (8.12.9/8.12.9/Submit) id h7SG4uuw000595; Thu, 28 Aug 2003 16:04:56 GMT (envelope-from marcel) Date: Thu, 28 Aug 2003 16:04:56 +0000 From: Marcel Moolenaar To: Poul-Henning Kamp Message-ID: <20030828160456.GA497@dhcp01.pn.xcllnt.net> References: <5535.1062077047@critter.freebsd.dk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <5535.1062077047@critter.freebsd.dk> User-Agent: Mutt/1.5.4i cc: Hidetoshi Shimokawa cc: src-committers@FreeBSD.org cc: Hidetoshi Shimokawa cc: cvs-src@FreeBSD.org cc: John-Mark Gurney cc: cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/conf majors X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Aug 2003 16:05:10 -0000 On Thu, Aug 28, 2003 at 03:24:07PM +0200, Poul-Henning Kamp wrote: > >> > > >> >Do you have any sample of console drivers converted to use MAJOR_AUTO? > >> > >> I don't really think that it matters that it is a console driver, > >> why should it ? > > > >We call makedev() in cnprobe and we cannot call make_dev() before > >SI_SUB_DRIVERS. This is my understanding why we have not converted > >any console driver to use MAJOR_AUTO. > > Ohh, right, _that_ hack. > > Yes, in that case you need a static Major. uart(4) in Perforce uses auto-assigned major numbers and is a console device. The trick is to not call makedev() in cnprobe(), but after make_dev() has been called. We don't actually use the device number until we start init(8). -- Marcel Moolenaar USPA: A-39004 marcel@xcllnt.net