From owner-freebsd-arch@FreeBSD.ORG Wed Oct 1 18:34:49 2003 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 71BF416A4BF for ; Wed, 1 Oct 2003 18:34:49 -0700 (PDT) Received: from smtp.noos.fr (nan-smtp-12.noos.net [212.198.2.83]) by mx1.FreeBSD.org (Postfix) with ESMTP id D280D43FDD for ; Wed, 1 Oct 2003 18:34:46 -0700 (PDT) (envelope-from root@noos.fr) Received: (qmail 5739607 invoked by uid 0); 2 Oct 2003 01:34:42 -0000 Received: (qmail 71839524 invoked by uid 0); 28 Sep 2003 21:23:04 -0000 Received: from unknown (HELO mx2.freebsd.org) ([216.136.204.119]) (envelope-sender ) by 212.198.2.76 (qmail-ldap-1.03) with SMTP for ; 28 Sep 2003 21:23:04 -0000 Received: from hub.freebsd.org (hub.freebsd.org [216.136.204.18]) by mx2.freebsd.org (Postfix) with ESMTP id 85B405890A; Sun, 28 Sep 2003 14:22:26 -0700 (PDT) (envelope-from owner-freebsd-current@freebsd.org) Received: from hub.freebsd.org (localhost [127.0.0.1]) by hub.freebsd.org (Postfix) with ESMTP id E587716A4FC; Sun, 28 Sep 2003 14:22:20 -0700 (PDT) Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E812216A4B3; Sun, 28 Sep 2003 14:22:11 -0700 (PDT) Received: from critter.freebsd.dk (critter.freebsd.dk [212.242.86.163]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8AB9744011; Sun, 28 Sep 2003 14:22:10 -0700 (PDT) (envelope-from phk@phk.freebsd.dk) Received: from critter.freebsd.dk (localhost [127.0.0.1]) by critter.freebsd.dk (8.12.9/8.12.9) with ESMTP id h8SLM7LG000654; Sun, 28 Sep 2003 23:22:08 +0200 (CEST) (envelope-from phk@phk.freebsd.dk) To: arch@freebsd.org, current@freebsd.org From: Poul-Henning Kamp Message-ID: <653.1064784127@critter.freebsd.dk> X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Sender: owner-freebsd-current@freebsd.org Errors-To: owner-freebsd-current@freebsd.org Subject: HEADSUP: Change of makedev() semantics. X-BeenThere: freebsd-arch@freebsd.org List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Date: Thu, 02 Oct 2003 01:34:49 -0000 X-Original-Date: Sun, 28 Sep 2003 23:22:07 +0200 X-List-Received-Date: Thu, 02 Oct 2003 01:34:49 -0000 I am in the process of adding ref-counting and locking to dev_t, and would very much prefer if we could get this step completed soon before 5-STABLE gets branched. All this will be transparent to the majority of device drivers, as the refcounting will happen in the make_dev() and destroy_dev() family of calls and normal drivers need not know more about it. But there are a few remaining users of makedev() which get in the way of this effort, and we must get these fixed. Basically: 1. Do not call makedev(). 2. If you do cloning, please look at the patches I posted for if_tun/if_tap for how to do it. 3. If you do a "normal" device driver, cache the result from when you call make_dev(). 4. If you translate "foreign dev_t's", ie emulators or compat code, contact me. I'm not sure I understand how this works and should work and we need to talk. 5. If anything else or in doubt, ask me. Can I see some volounteers and/or maintainers please ? ./alpha/osf1/osf1_misc.c badly named local macro ? ./compat/linux/linux_stats.c ./compat/svr4/svr4_types.h compat code, not sure that this is correct now. Must be supported by new "finddev" semantics. ./dev/ata/atapi-cd.c cloning related to root mount. gets fixed when phk GEOMify the driver. ./dev/sound/midi/midi.h Not sure. ./dev/nmdm/nmdm.c pseudo-cloning. Should do real cloning. ./dev/syscons/syscons.c Related to console initialization. Maybe tricky. ./dev/sound/pcm/dsp.c ./dev/sound/pcm/mixer.c ./dev/usb/ugen.c ./dev/usb/uscanner.c Failure to cache result of make_dev() ./dev/vinum Failure to cache result of make_dev() ? Thanks in advance! -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence. _______________________________________________ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to "freebsd-current-unsubscribe@freebsd.org"