diff options
author | phk <phk@FreeBSD.org> | 1999-05-08 06:40:31 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 1999-05-08 06:40:31 +0000 |
commit | 500e41bd7127ee03db75cd2a3704b8025c24e345 (patch) | |
tree | 8dc80d7dc8cd7f629dab45bcd87aa448cb9a4ca0 /sys/dev/snp | |
parent | ed809a974db9e6d86dabb993b9b0c6c49e1bbf32 (diff) | |
download | FreeBSD-src-500e41bd7127ee03db75cd2a3704b8025c24e345.zip FreeBSD-src-500e41bd7127ee03db75cd2a3704b8025c24e345.tar.gz |
I got tired of seeing all the cdevsw[major(foo)] all over the place.
Made a new (inline) function devsw(dev_t dev) and substituted it.
Changed to the BDEV variant to this format as well: bdevsw(dev_t dev)
DEVFS will eventually benefit from this change too.
Diffstat (limited to 'sys/dev/snp')
-rw-r--r-- | sys/dev/snp/snp.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/dev/snp/snp.c b/sys/dev/snp/snp.c index ebffb2a..204088c 100644 --- a/sys/dev/snp/snp.c +++ b/sys/dev/snp/snp.c @@ -71,7 +71,7 @@ snpdevtotty (dev) maj = major(dev); if ((u_int)maj >= nchrdev) return (NULL); - cdp = cdevsw[maj]; + cdp = devsw(dev); if (cdp == NULL) return (NULL); return ((*cdp->d_devtotty)(dev)); |