blob: 95f1a75cab64c99fe16bc5c04966a3dba2081d71 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
#linux #devices
---
major, minor numbers
major = driver (used by kernel when opening device to dispatch to correct driver)
minor = used by driver to differentiate device(s)
after disk the major, minor numbers are shown:
```
[jasras@n04.compute.vps2-lej1 ~]$ ls -l /dev/dm-*
brw-rw---- 1 root disk 253, 0 Oct 25 10:10 /dev/dm-0
brw-rw---- 1 root disk 253, 1 Oct 25 10:11 /dev/dm-1
brw-rw---- 1 root root 253, 11 Oct 28 19:58 /dev/dm-11
brw-rw---- 1 root root 253, 12 Oct 28 19:58 /dev/dm-12
```
available devices: `cat /proc/devices`
character devices vs block devices; what is the difference?
---
[oreilly-device-drivers](https://www.oreilly.com/library/view/linux-device-drivers/0596000081/ch03s02.html)
|