From nobody@FreeBSD.org  Mon Mar 12 21:01:52 2001
Return-Path: <nobody@FreeBSD.org>
Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21])
	by hub.freebsd.org (Postfix) with ESMTP id C5C6B37B719
	for <freebsd-gnats-submit@FreeBSD.org>; Mon, 12 Mar 2001 21:01:52 -0800 (PST)
	(envelope-from nobody@FreeBSD.org)
Received: (from nobody@localhost)
	by freefall.freebsd.org (8.11.1/8.11.1) id f2D51qG87757;
	Mon, 12 Mar 2001 21:01:52 -0800 (PST)
	(envelope-from nobody)
Message-Id: <200103130501.f2D51qG87757@freefall.freebsd.org>
Date: Mon, 12 Mar 2001 21:01:52 -0800 (PST)
From: todd.showalter@home.com
To: freebsd-gnats-submit@FreeBSD.org
Subject: Off-by-one error in MAKEDEV wrt. pass(4) device.
X-Send-Pr-Version: www-1.0

>Number:         25761
>Category:       misc
>Synopsis:       Off-by-one error in MAKEDEV wrt. pass(4) device.
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Mon Mar 12 21:10:01 PST 2001
>Closed-Date:    Tue Mar 13 20:44:11 PST 2001
>Last-Modified:  Sat Apr 21 21:50:01 PDT 2001
>Originator:     Todd Showalter
>Release:        4.2-STABLE
>Organization:
>Environment:
FreeBSD ryoko.darkstar.org 4.2-STABLE FreeBSD 4.2-STABLE #0: Sun Feb 11 23:32:27 GMT 2001     todd@ryoko:/usr/src/sys/compile/Ryoko  i386

>Description:
If you:

> su
# cd /dev
# MAKEDEV pass4

    You only get /dev/pass0 - /dev/pass3; I noticed this because tosha
wouldn't access my cdrom drive.
>How-To-Repeat:

>Fix:
UNTESTED!

Change the CAM passthrough code in MAKEDEV from:

        while [ $i -lt $units ]; do
to
        while [ $i -le $units ]; do

    As I understand what's going on, this is the Right Thing.

>Release-Note:
>Audit-Trail:

From: Matthew Jacob <mjacob@feral.com>
To: todd.showalter@home.com
Cc: freebsd-gnats-submit@FreeBSD.ORG
Subject: Re: misc/25761: Off-by-one error in MAKEDEV wrt. pass(4) device.
Date: Tue, 13 Mar 2001 20:36:25 -0800 (PST)

 I don't think this is quite right. The MAKEDEV script's man page doesn't say
 this, but for the few devices where the numeric argument is not the actual
 unit number you want created it seems that this is more an 'amount', so doing
 
 MAKEDEV pass4
 
 creates 4 pass devices (0..3). This code seems to probably have started with
 the vty devices. The comment in MAKEDEV appears to be:
 
 # Use this to create virtual consoles for syscons, pcvt or codrv
 # ttyv0-b
 # use as MAKEDEV vtyNN to create NN entries
 
 So, I think we can basically say, "Not a bug".
 
 -matt
 
 
State-Changed-From-To: open->closed 
State-Changed-By: mjacob 
State-Changed-When: Tue Mar 13 20:44:11 PST 2001 
State-Changed-Why:  
Sorry- not really a bug. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=25761 

From: Kris Kennaway <kris@obsecurity.org>
To: todd.showalter@home.com
Cc: freebsd-gnats-submit@FreeBSD.org
Subject: Re: misc/25761: Off-by-one error in MAKEDEV wrt. pass(4) device.
Date: Sat, 21 Apr 2001 21:41:52 -0700

 --i9LlY+UWpKt15+FH
 Content-Type: text/plain; charset=us-ascii
 Content-Disposition: inline
 Content-Transfer-Encoding: quoted-printable
 
 On Mon, Mar 12, 2001 at 09:01:52PM -0800, todd.showalter@home.com wrote:
 
 > > su
 > # cd /dev
 > # MAKEDEV pass4
 >=20
 >     You only get /dev/pass0 - /dev/pass3; I noticed this because tosha
 > wouldn't access my cdrom drive.
 
 I think this is the desired behaviour.
 
 Kris
 
 --i9LlY+UWpKt15+FH
 Content-Type: application/pgp-signature
 Content-Disposition: inline
 
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1.0.4 (FreeBSD)
 Comment: For info see http://www.gnupg.org
 
 iD8DBQE64mEQWry0BWjoQKURArrxAJ49B+YEtf95qMMOrwxGB9Le95+IswCggUOy
 KliAqc7cmq6kaJaMAx+c2zQ=
 =zSin
 -----END PGP SIGNATURE-----
 
 --i9LlY+UWpKt15+FH--
>Unformatted:
