From owner-freebsd-current Sun Feb 23 18:42:17 2003 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 546C137B401 for ; Sun, 23 Feb 2003 18:42:15 -0800 (PST) Received: from angelica.unixdaemons.com (angelica.unixdaemons.com [209.148.64.135]) by mx1.FreeBSD.org (Postfix) with ESMTP id D7D6C43FAF for ; Sun, 23 Feb 2003 18:42:13 -0800 (PST) (envelope-from hiten@angelica.unixdaemons.com) Received: from angelica.unixdaemons.com (hiten@localhost.unixdaemons.com [127.0.0.1]) by angelica.unixdaemons.com (8.12.7/8.12.1) with ESMTP id h1O2gAeG052163 for ; Sun, 23 Feb 2003 21:42:10 -0500 (EST) Received: (from hiten@localhost) by angelica.unixdaemons.com (8.12.7/8.12.1/Submit) id h1O2gAs0052162 for current@FreeBSD.ORG; Sun, 23 Feb 2003 21:42:10 -0500 (EST) (envelope-from hiten) Date: Sun, 23 Feb 2003 21:42:10 -0500 From: Hiten Pandya To: current@FreeBSD.ORG Subject: machdep.guessed_bootdev sysctl on i386 Message-ID: <20030224024210.GA50286@unixdaemons.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="2oS5YaxWCcQjTEyO" Content-Disposition: inline User-Agent: Mutt/1.4i X-Operating-System: FreeBSD i386 X-Public-Key: http://www.pittgoth.com/~hiten/pubkey.asc X-URL: http://www.unixdaemons.com/~hiten X-PGP: http://pgp.mit.edu:11371/pks/lookup?search=Hiten+Pandya&op=index Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG --2oS5YaxWCcQjTEyO Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Hello gang. Nothing big, but important... Can someone tell me if the machdep.guessed_bootdev sysctl is helpful at all? I think it's a waste, and it's pretty limited and only available on the i386. It currently guesses 'wd' instead of 'ad' for the dev. nodes, .e.g: hiten:~/> sysctl machdep.gussed_bootdev machdep.guessed_bootdev: /dev/wd0s1a SCSI drives are shown right (da) but ATA drives mess up, i.e. it is still thinking we have the 'wd' system. It's either that we nuke this sysctl or apply the attached patch to sysctl, which has been reviewed and tested by people on IRC with positive results. Comments / objections appreciated. Cheers. -- Hiten Pandya (hiten@unixdaemons.com, hiten@uk.FreeBSD.org) http://www.unixdaemons.com/~hiten/ --2oS5YaxWCcQjTEyO Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="sysctl-bootdev.patch" Index: src/sbin/sysctl/sysctl.c =================================================================== RCS file: /home/ncvs/src/sbin/sysctl/sysctl.c,v retrieving revision 1.51 diff -u -r1.51 sysctl.c --- src/sbin/sysctl/sysctl.c 22 Jan 2003 00:34:22 -0000 1.51 +++ src/sbin/sysctl/sysctl.c 22 Feb 2003 14:21:13 -0000 @@ -460,9 +460,7 @@ int majdev; char *name; } maj2name[] = { - 30, "ad", - 0, "wd", - 1, "wfd", + 0, "ad", 2, "fd", 4, "da", -1, NULL /* terminator */ --2oS5YaxWCcQjTEyO-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message