| Summary: | Off-by-one error in MAKEDEV wrt. pass(4) device. | ||
|---|---|---|---|
| Product: | Base System | Reporter: | todd.showalter <todd.showalter> |
| Component: | misc | Assignee: | freebsd-bugs (Nobody) <bugs> |
| Status: | Closed FIXED | ||
| Severity: | Affects Only Me | ||
| Priority: | Normal | ||
| Version: | 4.2-STABLE | ||
| Hardware: | Any | ||
| OS: | Any | ||
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 Sorry- not really a bug. On Mon, Mar 12, 2001 at 09:01:52PM -0800, todd.showalter@home.com wrote: > > su > # cd /dev > # MAKEDEV pass4 > > 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 |
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. 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.