*** UNIX MANUAL PAGE BROWSER ***

A Nergahak database for man pages research.

Navigation

Directory Browser

1Browse 4.4BSD4.4BSD
1Browse Digital UNIXDigital UNIX 4.0e
1Browse FreeBSDFreeBSD 14.3
1Browse MINIXMINIX 3.4.0rc6-d5e4fc0
1Browse NetBSDNetBSD 10.1
1Browse OpenBSDOpenBSD 7.7
1Browse UNIX v7Version 7 UNIX
1Browse UNIX v10Version 10 UNIX

Manual Page Search

Manual Page Result

0 Command: minor | Section: 3 | Source: FreeBSD | File: minor.3.gz
MAKEDEV(3) FreeBSD Library Functions Manual MAKEDEV(3) NAME makedev, major, minor - device number conversion SYNOPSIS #include <sys/types.h> dev_t makedev(int major, int minor); int major(dev_t dev); int minor(dev_t dev); DESCRIPTION The makedev() macro returns a device number created from the provided major and minor number. The major() and minor() macros return the original numbers from the device number dev. In other words, for a value dev of the type dev_t, and values ma, mi of the type int, the assertions dev == makedev(major(dev), minor(dev)) ma == major(makedev(ma, mi)) mi == minor(makedev(ma, mi)) are valid. In previous implementations of FreeBSD all block and character devices were uniquely identified by a pair of stable major and minor numbers. The major number referred to a certain device class (e.g. disks, TTYs) while the minor number identified an instance within the device class. Later versions of FreeBSD automatically generate a unique device number for each character device visible in /dev/. These numbers are not divided in device classes and are not guaranteed to be stable upon reboot or driver reload. On FreeBSD these macros are only used by utilities that need to exchange numbers with other operating systems that may use different encodings for dev_t, but also applications that present these numbers to the user in a more conventional way. RETURN VALUES The major() and minor() macros return numbers whose value can span the complete range of an int. SEE ALSO mknod(2), devname(3), devfs(5) FreeBSD 14.1-RELEASE-p8 August 3, 2017 FreeBSD 14.1-RELEASE-p8

Navigation Options