Last Sync: 2022-06-04 13:00:04

This commit is contained in:
tactonbishop 2022-06-04 13:00:04 +01:00
parent d880e5fab5
commit 3a495ab8bc
5 changed files with 41 additions and 2 deletions

27
Linux/Devices.md Normal file
View file

@ -0,0 +1,27 @@
---
tags:
- Linux
- Operating_Systems
---
# Devices
Devices pertain to disks and drives that either exist on the motherboard or that are plugged-in.
Devices are files but they are different from ordinary files. There are two types: **block** and **stream**. Device files reside in the `/dev/` directory.
Some of the most important device files are:
* `hda` : a harddisk on a port
* `sda` : a harddisk on another port
> Device files are an interface to a driver which accesses the hardware. A driver is therefore part of the Linux kernel.
So when you see `sda` listed for example, this isn't the harddisk itself, it is a file that communicates with a driver that controls how the kernel can interact with it. This is why when you add a new piece of hardware (such as a mouse for example) you have to install drivers (typically provided by the manufacturer) so that your kernel is able to interact with it and provide it with access to the CPU.
## `/dev/`
```
brw-rw---- 1 root disk 259, 1 Jun 4 11:00 nvme0n1p1
brw-rw---- 1 root disk 259, 2 Jun 4 11:00 nvme0n1p2
brw-rw---- 1 root disk 259, 3 Jun 4 11:00 nvme0n1p3
```

View file

@ -1,3 +1,15 @@
h1, body {
font-family: 'Liberation';
h1, h2, h3, h4, h5, h6, p {
font-family: 'Inter';
}
h1 {
font-size: 18px;
}
p, ul, li {
font-size: 14px;
}
pre, code {
font-family: 'LigaLiberationMono';
}