From owner-freebsd-hackers Tue Feb 5 8:30:42 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from rover.village.org (rover.bsdimp.com [204.144.255.66]) by hub.freebsd.org (Postfix) with ESMTP id 0C2D837B404; Tue, 5 Feb 2002 08:30:35 -0800 (PST) Received: from harmony.village.org (harmony.village.org [10.0.0.6]) by rover.village.org (8.11.3/8.11.3) with ESMTP id g15GUXi09713; Tue, 5 Feb 2002 09:30:34 -0700 (MST) (envelope-from imp@village.org) Received: from localhost (warner@rover2.village.org [10.0.0.1]) by harmony.village.org (8.11.6/8.11.6) with ESMTP id g15GUTL30336; Tue, 5 Feb 2002 09:30:33 -0700 (MST) (envelope-from imp@village.org) Date: Tue, 05 Feb 2002 09:30:06 -0700 (MST) Message-Id: <20020205.093006.104650505.imp@village.org> To: yar@FreeBSD.ORG Cc: hackers@FreeBSD.ORG Subject: Re: Get disk device size? From: "M. Warner Losh" In-Reply-To: <20020205125557.A10266@comp.chem.msu.su> References: <20020205125557.A10266@comp.chem.msu.su> X-Mailer: Mew version 2.1 on Emacs 21.1 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG In message: <20020205125557.A10266@comp.chem.msu.su> Yar Tikhiy writes: : Could anyone point out at an ioctl or any other way to get a disk : device size granted the device has no BSD label or PC slice table : on it? Ways for both the userland and kernel are welcome. For userland, look at how fdisk and/or disklabel get it. For kernel, look at kern/subr_disk*.c Warner To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message