Discover And Control Hardware
- Software Layers to and from Hardware.
- Applications call functions in libraries.
- Some functions invoke Kernel System Calls.

- Some system calls interact with hardware.
- Can find out information about HW on the system with
lshwandlspci. lsubandlsbklscpuandlsdev- Can do disk benchmarking with
hdparm. - Can configure the hardware in software with Write (
echo) toproc,devorsysfiles. - Legacy devices such as keyboards are on a different bus. I/O bus.
- Can read and write bytes to the buses. Those are
inbandoutb - Disable the keyboard by writing a value with the
outbcommand for example. - Can read in items with the
inbcommand (serial devices)
- Can read and write bytes to the buses. Those are
- Can configure and change information with the
setpcicommand. - Interestingly if you run
lsusb, all Intel device start with8087in their ID.Bus 002 Device 002: ID 8087:8000 Intel Corp. Integrated Rate Matching Hub - PCI devices, they have
8086for Intel devices. - A lot of companies will use the same underlying chip in their mouse and keyboards for example.
lscpu, you a field calledBogoMIPS. This isn’t real MIPS and is for Bogus MIPS.- When the Kernel boot, it has a loop and measures performance. Use the
BogoMIPSto calculate how long it takes to run certain tasks.
- When the Kernel boot, it has a loop and measures performance. Use the