Search icon
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletters
Free Learning
Arrow right icon
Linux Device Driver Development - Second Edition

You're reading from  Linux Device Driver Development - Second Edition

Product type Book
Published in Apr 2022
Publisher Packt
ISBN-13 9781803240060
Pages 708 pages
Edition 2nd Edition
Languages
Author (1):
John Madieu John Madieu
Profile icon John Madieu

Table of Contents (23) Chapters

Preface Section 1 -Linux Kernel Development Basics
Chapter 1: Introduction to Kernel Development Chapter 2: Understanding Linux Kernel Module Basic Concepts Chapter 3: Dealing with Kernel Core Helpers Chapter 4: Writing Character Device Drivers Section 2 - Linux Kernel Platform Abstraction and Device Drivers
Chapter 5: Understanding and Leveraging the Device Tree Chapter 6: Introduction to Devices, Drivers, and Platform Abstraction Chapter 7: Understanding the Concept of Platform Devices and Drivers Chapter 8: Writing I2C Device Drivers Chapter 9: Writing SPI Device Drivers Section 3 - Making the Most out of Your Hardware
Chapter 10: Understanding the Linux Kernel Memory Allocation Chapter 11: Implementing Direct Memory Access (DMA) Support Chapter 12: Abstracting Memory Access – Introduction to the Regmap API: a Register Map Abstraction Chapter 13: Demystifying the Kernel IRQ Framework Chapter 14: Introduction to the Linux Device Model Section 4 - Misc Kernel Subsystems for the Embedded World
Chapter 15: Digging into the IIO Framework Chapter 16: Getting the Most Out of the Pin Controller and GPIO Subsystems Chapter 17: Leveraging the Linux Kernel Input Subsystem Other Books You May Enjoy

Demystifying address translation and MMU

MMU does not only convert virtual addresses into physical ones but also protects memory from unauthorized access. Given a process, any page that needs to be accessed from this process must exist in one of its VMAs and, thus, must live in the process's page table (every process has its own).

As a recall, memory is organized by chunks of fixed-size named pages for virtual memory and frames for physical memory. The size in our case is 4 KB. However, it is defined and accessible with the PAGE_SIZE macro in the kernel. Remember, however, that page size is imposed by the hardware. Considering a 4 KB page-sized system, bytes 0 to 4095 fall on page 0, bytes 4096 to 8191 fall on page 1, and so on.

The concept of a page table is introduced to manage mapping between pages and frames. Pages are spread over tables so that each PTE corresponds to a mapping between a page and a frame. Each process is then given a set of page tables to describe all...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $15.99/month. Cancel anytime}