sys_dev(5)

sys_dev5

System devices

Usage

/sys/dev/

Overview

This directory contains two subdirectories block/ and char/, corresponding, respectively, to the block and character devices on the system. Inside each of these subdirectories are symbolic links with names of the form major-ID:minor-ID, where the ID values correspond to the major and minor ID of a specific device. Each symbolic link points to the sysfs directory for a device. The symbolic links inside /sys/dev/ thus provide an easy way to look up the sysfs interface using the device IDs returned by a call to stat(2) (or similar).

The following shell session shows an example from /sys/dev/:

$ stat -c "%t %T" /dev/null;
1 3
$ readlink /sys/dev/char/1\:3;
../../devices/virtual/mem/null
$ ls -Fd /sys/devices/virtual/mem/null;
/sys/devices/virtual/mem/null/
$ ls -d1 /sys/devices/virtual/mem/null/*;
/sys/devices/virtual/mem/null/dev
/sys/devices/virtual/mem/null/power/
/sys/devices/virtual/mem/null/subsystem@
/sys/devices/virtual/mem/null/uevent

Standards

Linux.

History

Linux 2.6.0.

From man-pages 6.20-1 in Arch Linux 2026-11-07. Parsed by carta from the page's man source.