Kernel Hacking

A put-together of kernel related topics.

Group Description

cluster_kernel Kernel Hacking kernel_dma DMA kernel_kmalloc Dynamic Memory: kmalloc() kernel_dma->kernel_kmalloc kernel_interrupt_coding Coding: Raspi GPIO Interrupts kernel_interrupt Interrupts kernel_interrupt_coding->kernel_interrupt kernel_raspi_kernel_build Raspberry Pi: Building the Kernel kernel_interrupt_coding->kernel_raspi_kernel_build kernel_mutex_coding Coding: Fix Race Condition (Mutex) kernel_interrupt_coding->kernel_mutex_coding kernel_timer_coding Coding: Timed Event kernel_timer Timer Management kernel_timer_coding->kernel_timer kernel_spinlock_coding Coding: Fix Sleep While Atomic kernel_timer_coding->kernel_spinlock_coding kernel_fedora_kernel_build Fedora: Building the Kernel kernel_cdev_file_operations File Operations on Character Devices kernel_cdev_auto Modern Character Devices kernel_cdev_file_operations->kernel_cdev_auto kernel_stub_sysprog_dup dup(), fork(), and Reference Counting (Stub) kernel_cdev_file_operations->kernel_stub_sysprog_dup kernel_process_vs_atomic Process vs.Atomic Context kernel_timer->kernel_process_vs_atomic kernel_interrupt->kernel_process_vs_atomic kernel_waitqueue Waiting for Something kernel_waitqueue->kernel_cdev_file_operations kernel_usermem Accessing Userspace Memory kernel_waitqueue->kernel_usermem kernel_cdev_manual Character Device Basics kernel_modules_hello_world Module Loading, Hello World kernel_cdev_manual->kernel_modules_hello_world kernel_iomemory IO Memory kernel_iomemory->kernel_modules_hello_world kernel_cdev_auto->kernel_cdev_manual kernel_fedora_module_build Fedora: Building External Kernel Modules kernel_fedora_module_build->kernel_fedora_kernel_build kernel_netdev Network Devices kernel_netdev->kernel_dma kernel_netdev->kernel_interrupt kernel_mutex Mutex (and RT Mutex) kernel_mutex->kernel_process_vs_atomic kernel_workqueue Workqueue kernel_workqueue->kernel_timer_coding kernel_workqueue->kernel_process_vs_atomic kernel_kmalloc->kernel_process_vs_atomic kernel_modules_hello_world->kernel_fedora_module_build kernel_pci PCI kernel_pci->kernel_dma kernel_pci->kernel_interrupt kernel_pci->kernel_iomemory kernel_cdev_first_functionality Coding: First Functionality kernel_cdev_first_functionality->kernel_cdev_file_operations kernel_cdev_first_functionality->kernel_kmalloc kernel_list Doubly Linked Lists kernel_cdev_first_functionality->kernel_list kernel_usermem->kernel_workqueue kernel_spinlock_coding->kernel_interrupt_coding kernel_spinlock Spinlock (vs. Mutex) kernel_spinlock_coding->kernel_spinlock kernel_spinlock->kernel_process_vs_atomic kernel_multiple_devices Coding: Multiple Devices kernel_cdev_refactoring Coding: Refactoring kernel_multiple_devices->kernel_cdev_refactoring kernel_mutex_coding->kernel_mutex kernel_mutex_coding->kernel_multiple_devices kernel_cdev_refactoring->kernel_cdev_first_functionality

Sample Code Maintenance

To Do List

  • Networking

    https://www.cs.dartmouth.edu/~sergey/netreads/path-of-packet/Lab9_modified.pdf

  • Kernel

    • Topic “Kernel Source”

    • “Kernel Modules”? Probably aggregate into Module Loading, Hello World

    • “Kernel Internals”?

    • 0520-kernel-communication

    • 0521-kernel-kmalloc (GFP etc, depend interrupts on it)

    • 0525-kernel-io-memory

    • 0532-kernel-threaded-interrupts

    • 0710-kernel-preempt-rt

  • Aggregate _morph/ branches top-level

  • Bring source code into slides/screenplays

  • Userspace/kernel picture from sysprog.

  • In topics that refer to github code, mention branch where code is maintained. (code-block caption)

  • SEO

    • meta everywhere

    • sidebars with backlinks to this document

    • this document: course description