DRV-101 · Device Drivers · Foundation

Character Devices & sysfs — full syllabus

Your first working driver: character device registration, file operations, and exposing state through sysfs.

Duration3 full days in person · 6 half-days online
Cohortmax 14 in person · 20 online
Pricefrom SAR 6,750 in person · local pricing per city
Delivery35% principles · 20% guided investigation · 45% engineering studio

Who this course is for

Engineers writing their first Linux driver — firmware or userspace developers who need a working mental model of how a device file actually reaches their code.

Prerequisites

Course outline

Day 1 — Registering a character device

  • Major/minor numbers and what they actually identify
  • alloc_chrdev_region vs static majors
  • cdev_init, cdev_add and the registration order
  • device_create, udev and how /dev nodes appear
  • module_init/module_exit vs the probe model you will meet later

Day 2 — file_operations and the user boundary

  • The file_operations table: open, read, write, release, llseek
  • copy_to_user/copy_from_user and the page-fault path underneath
  • access_ok and why the check is not the copy
  • ioctl: command number encoding with _IO/_IOR/_IOW/_IOWR
  • Per-device state vs per-open state and the locking each needs

Day 3 — Exposing driver state

  • kobjects as the base object and their lifetime rules
  • sysfs attributes with DEVICE_ATTR: one value per file, no exceptions
  • Attribute groups and binary attributes
  • procfs: what it is for and what it is not for
  • debugfs for driver introspection without ABI promises

Hands-on labs

  1. Lab: Register a char device with alloc_chrdev_region and cdev_add; watch udev create the node and verify reads reach your handler
  2. Lab: Implement read/write across the user boundary, then pass a bad pointer deliberately and decode the resulting fault
  3. Lab: Add an ioctl interface with correctly encoded command numbers and drive it from a small C test program
  4. Lab: Expose counters and state through sysfs attributes and a debugfs dump file; script a reader for both
  5. Lab: Race two processes against your device, reproduce the corruption, and fix it with the right lock — verified with lockdep

Capstone project

Build a small but complete character driver: a kernel ring-buffer device with read/write, an ioctl control surface, a sysfs status attribute and a debugfs dump — delivered with a userspace test program and a fault-injection checklist demonstrating that every error path (bad pointers, failed allocations, double unload) unwinds cleanly.

What you leave with

Upcoming dates

DatesWhereSeatsEarly birdRegular
15 Nov – 17 Nov 20263 full days RiyadhIn person · KAFD Conference Centre 6 of 14 SAR 6,080until 16 OctSAR 6,750
15 Nov – 17 Nov 20263 full days Kuwait CityIn person · Al Hamra Tower 11 of 14 KWD 500until 16 OctKWD 560
22 Nov – 24 Nov 20263 full days MuscatIn person · Knowledge Oasis Muscat 6 of 14 OMR 620until 23 OctOMR 690
29 Nov – 6 Dec 20266 half-days Gulf bandLive online · 09:00–13:00 GMT+3 16 of 20 US$1,170until 30 OctUS$1,300
30 Nov – 2 Dec 20263 full days OttawaIn person · Kanata North Tech Park 11 of 14 CAD 2,200until 31 OctCAD 2,450
30 Nov – 2 Dec 20263 full days TorontoIn person · MaRS Discovery District 6 of 14 CAD 2,200until 31 OctCAD 2,450
30 Nov – 7 Dec 20266 half-days Europe bandLive online · 09:00–13:00 CET 5 of 20 US$1,170until 31 OctUS$1,300
7 Dec – 9 Dec 20263 full days LondonIn person · Shoreditch Works 11 of 14 GBP 1,260until 7 NovGBP 1,400
7 Dec – 14 Dec 20266 half-days Americas bandLive online · 13:00–17:00 ET 10 of 20 US$1,170until 7 NovUS$1,300
14 Dec – 16 Dec 20263 full days BerlinIn person · Factory Görlitzer Park 6 of 14 EUR 1,490until 14 NovEUR 1,660

Book a seat, or bring this course to your team

Seats can be reserved online; private delivery runs on-site or live online, adapted to your stack.

Course page & booking

Questions about fit or prerequisites? Email hello@kernelsystems.academy. To save this syllabus, print this page to PDF from your browser.