From owner-cvs-src@FreeBSD.ORG Mon Sep 13 06:26:58 2004 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 26E2316A4CE; Mon, 13 Sep 2004 06:26:58 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 059FA43D3F; Mon, 13 Sep 2004 06:26:58 +0000 (GMT) (envelope-from phk@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.12.11/8.12.11) with ESMTP id i8D6QvVA059759; Mon, 13 Sep 2004 06:26:57 GMT (envelope-from phk@repoman.freebsd.org) Received: (from phk@localhost) by repoman.freebsd.org (8.12.11/8.12.11/Submit) id i8D6QvB5059758; Mon, 13 Sep 2004 06:26:57 GMT (envelope-from phk) Message-Id: <200409130626.i8D6QvB5059758@repoman.freebsd.org> From: Poul-Henning Kamp Date: Mon, 13 Sep 2004 06:26:57 +0000 (UTC) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: RELENG_5 Subject: cvs commit: src/sys/cam/scsi scsi_cd.c src/sys/geom geom_subr.c notes 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: Mon, 13 Sep 2004 06:26:58 -0000 phk 2004-09-13 06:26:57 UTC FreeBSD src repository Modified files: (Branch: RELENG_5) sys/cam/scsi scsi_cd.c sys/geom geom_subr.c notes Log: MFC: For removable devices without media we set a zero mediasize but a non-zero sectorsize in order to avoid a lot of checks around various divisions etc. Enforce the sectorsize being > 0 with a KASSERT on successful open. Fix scsi_cd.c to return 2k sectors when no media inserted. Approved by: re::kensmith Revision Changes Path 1.89.2.1 +1 -1 src/sys/cam/scsi/scsi_cd.c 1.81.2.1 +3 -0 src/sys/geom/geom_subr.c 1.4.6.1 +10 -0 src/sys/geom/notes