Commit graph

39 commits

Author SHA1 Message Date
Le Baron de Charlus
83b01baa07
Change command prompt style in chapter-04.md
Updated command syntax from '#' to '%' for clarity.
2026-07-13 10:15:53 +02:00
LeBaronDeCharlus
af44b276c2 Fixing git command leading to an error and adjust commands where sudo
was not present.

git clone --branch releng/15.0 --depth 1 https://git.FreeBSD.org/src.git src /usr/src
fatal: Too many arguments.

to

sudo git clone --branch releng/15.0 --depth 1 https://git.FreeBSD.org/src.git /usr/src
2026-07-09 14:11:53 +02:00
Jesús Daniel Colmenares Oviedo
e9277b40c3 part1/chapter-04: Add missing quotes 2026-06-10 01:53:52 -04:00
Kidd Lee
4e0b53ccb0
chapter-04: add the missing S of SYSCTL_INT
Signed-off-by: Kidd Lee <LeeXiaolan@gmail.com>
2026-06-05 22:25:03 +08:00
Edson Brandi
f92af5b969 docs: complete initial draft of all content for my FreeBSD Device Drivers: From First Steps to Kernel Mastery book.
After 10 months of daily work, the first full draft of the book is now complete.
2026-04-22 18:57:42 +00:00
Edson Brandi
be78fa799d Fix null terminator demonstration to show undefined behavior
The previous example wasn't reliably demonstrating the danger of missing
null terminators because the stack happened to contain a '\0' byte
immediately after the array, making the broken code appear to work.

Added memset() to fill the stack with non-zero values before declaring
the unterminated array. This ensures the broken example actually exhibits
undefined behavior by reading past the array boundary, making the lesson
about null terminators clear and visible.

Changes:
- Added garbage array filled with 'Z' characters using memset()
- This forces printf() to read past the broken array until finding '\0'
- Readers now see actual garbage output demonstrating why null
  terminators are required in C strings
2025-11-07 22:57:09 +00:00
Edson Brandi
87e7742451 Specify FreeBSD 14.3 release branch in git clone commands
Updated all git clone commands for the FreeBSD source repository to
explicitly checkout the releng/14.3 branch. This ensures readers are
working with FreeBSD 14.3 Release source code, which matches the
version used throughout the book examples.

Changed from:
  git clone https://git.freebsd.org/src.git /usr/src

To:
  git clone -b releng/14.3 https://git.freebsd.org/src.git /usr/src

This prevents confusion from version mismatches and ensures all kernel
module examples compile and function as documented.
2025-11-07 22:17:40 +00:00
Edson Brandi
66c0446388 Fixed minor errors found during an adhoc review 2025-11-07 18:42:06 +00:00
Edson Brandi
b497957d9a Add scripts to generate the PDF and epub book files 2025-08-31 03:36:05 +01:00
Edson Brandi
5e9d9147d1 Fixing markdown to convert to pdf 2025-08-30 22:30:50 +01:00
Edson Brandi
a76643c253 Chapter 4 Finished, starting chapter 5 2025-08-30 13:12:51 +01:00
Edson Brandi
2e9165ae47 Progressing with chapter 4... 2025-08-29 00:07:11 +01:00
Edson Brandi
fd69335cc9 Added Struct and Typedef Section to Chapter 4 2025-08-28 00:01:07 +01:00
Edson Brandi
be051d9f51 Added the section about Arrays and Strings to chapter 4 2025-08-26 21:32:22 +01:00
Edson Brandi
bca5a7bb43 Progressing with chapter 4 content, finished section about pointers. 2025-08-25 23:26:01 +01:00
Edson Brandi
3320ee1a92 progressing chapter 4 content about pointers 2025-08-25 17:25:28 +01:00
Edson Brandi
a4af37ac03 Adding content for chapter 3, and small typo fix in chapter 4 2025-08-23 16:34:36 +01:00
Edson Brandi
10db731875
Progressing chapter 4, added Pointers and Functions and Pointers and Arrays 2025-08-21 20:47:07 +01:00
Edson Brandi
24e6a0970c
Progressing chapter 4, added the topic about Declaring and Using Pointers... 2025-08-21 00:15:47 +01:00
Edson Brandi
4534b904e0
Progressing chapter 4 to add first topic about pointers, and also fixing double quotes and single quotes to have a standard across the chapter 2025-08-19 01:22:24 +01:00
Edson Brandi
9187c98bf1 Progressing chapter 4, finished section about functions - Parameters Are Copies 2025-08-15 16:53:41 -03:00
Edson Brandi
7dde5c3a9c typo fix 2025-08-14 19:15:31 -03:00
Edson Brandi
c1c53570e2 progressing with chapter 4... 2025-08-14 19:13:23 -03:00
Edson Brandi
0b9063510a progressing chapter 4... 2025-08-13 15:34:39 -03:00
Edson Brandi
b1e26a7eb4 progressing chapter 4, added a read example for fucntion prototype... 2025-08-12 16:35:20 -03:00
Edson Brandi
4bd3354701 progressing woth chapter 4, added Functions (prototype)... 2025-08-11 22:32:05 -03:00
Edson Brandi
294ac7feed small update to last date updated 2025-08-10 18:08:04 -03:00
Edson Brandi
5d92c208b8 progressing with C Functions section... 2025-08-10 17:41:57 -03:00
Edson Brandi
26342f022f Adjusting markdown tags to specify C language for code blocks 2025-08-10 16:50:31 -03:00
Edson Brandi
c7be15f162 fixing markdown tags 2025-08-10 16:33:42 -03:00
Edson Brandi
9e51e69092 starting section about functions 2025-08-10 10:39:33 -03:00
Edson Brandi
bbd493e9f5 fixing some typos in the markdowntags 2025-08-10 09:37:02 -03:00
Edson Brandi
1b705cf2a2 added flow control topic to chapter 4 draft 2025-08-10 03:09:29 -03:00
Edson Brandi
277be57822 fixing a rendering problem of | inside tables in markdown 2025-08-06 17:25:31 -03:00
Edson Brandi
fa8b5ded26 Progressing with chapter 4 content... 2025-08-06 17:12:56 -03:00
Edson Brandi
28b44b56ec progressing with chapter 4... 2025-08-06 11:06:31 -03:00
Edson Brandi
c6b732fd9f header fix for chapter 4 2025-08-05 15:34:51 -03:00
Edson Brandi
7dfcf40eeb Starting the chapter 4 2025-08-05 14:54:16 -03:00
Edson Brandi
539ef021f8 feat: Initial upload of FreeBSD Device Drivers Book structure
This commit establishes the complete foundation for the FreeBSD Device Drivers Book project.

## 📚 Book Structure
- **7 Parts** covering the complete driver development journey
- **38 Chapters** with detailed metadata and placeholders
- **5 Appendices** for reference materials
- **Portuguese (Brazil) translation** structure ready

## 🗂️ Directory Organization
-  - Main book content with chapters and appendices
-  - Source code examples with comprehensive README
-  - Utility scripts for content management
-  - Multi-language support structure

## 🛠️ Key Features Added
- **Content Management Scripts**:
  -  - Sync content to website directory
  -  - Set up new language translations
- **Examples Documentation** - Complete README with build instructions
- **Translation Infrastructure** - Ready for multiple languages

## 📖 Content Overview
- **Part 1**: Foundations (FreeBSD, C, Kernel basics)
- **Part 2**: Basic Driver Development
- **Part 3**: Concurrency and Synchronization
- **Part 4**: Hardware and Platform Integration
- **Part 5**: Debugging, Tools, and Real-World Practices
- **Part 6**: Transport-Specific Drivers
- **Part 7**: Mastery Topics and Edge Cases
2025-08-04 09:14:49 -03:00