Kirk McKusick
Dr. Marshall Kirk McKusick writes books and articles, teaches classes on UNIX- and BSD-related subjects, and provides expert-witness testimony on software patent, trade secret, and copyright issues particularly those related to operating systems and filesystems. He has been a developer and committer to the FreeBSD Project since shortly after its founding in 1993. While at the University of California at Berkeley, he implemented the 4.2BSD fast filesystem and was the Research Computer Scientist at the Berkeley Computer Systems Research Group (CSRG) overseeing the development and release of 4.3BSD and 4.4BSD. He earned his undergraduate degree in electrical engineering from Cornell University and did his graduate work at the University of California at Berkeley, where he received master's degrees in computer science and business administration and a doctoral degree in computer science. He has twice been president of the board of the Usenix Association, served nine years as a board member and treasurer of the FreeBSD Foundation, is a senior member of the IEEE, and a member of ACM, and AAAS.
In his spare time, he enjoys swimming, scuba diving, and wine collecting. The wine is stored in a specially constructed wine cellar (accessible from the Web at http://www.mckusick.com/~mckusick/) in the basement of the house that he shares with Eric Allman, his partner of 47-and-some-odd years and husband since 2013.
Sessions
An Introduction to the Filesystems and Networking
in the FreeBSD Open-Source Operating System
Dr. Marshall Kirk McKusick
Author and Consultant
Who Should Take this Course
This course provides a broad overview of how the FreeBSD kernel implements its basic services. It will be most useful to those who need to learn how these services are provided. Individuals involved in technical and sales support can learn the capabilities and limitations of the system; applications developers can learn how to effectively and efficiently interface to the system; systems programmers without direct experience with the FreeBSD kernel can learn how to maintain, tune, and interface to such systems. This course is directed to users who have had at least a year of experience using a UNIX-like system. They should have an understanding of fundamental algorithms (searching, sorting, and hashing) and data structures (lists, queues, and arrays).
Description
This course will provide a firm background in the filesystems and networking capabilities supported by the FreeBSD kernel. The course describes the VFS filesystem interface that supports multiple filesystem types. The course covers the implementation and capabilities of the UFS filesystem and the techniques for maintaining filesystem consistency. The filesystem section ends with a description of the ZFS filesystem capabilities, implementation, and integration into FreeBSD. The course also covers the socket-based network architecture, layering, and implementation. The socket communications primitives and internal layering will be discussed, with emphasis on the interfaces between the layers; the TCP/IP implementation will be used as an example. A discussion of routing issues and the netmap interface will be included. The presentations will emphasize code organization, data structure navigation, and algorithms. It will not cover the machine specific parts of the system such as the implementation of device drivers.
Morning - Filesystems Overview
- Filesystem organization
- Block I/O system (buffer cache)
- Support for multiple filesystems
- UFS Filesystem implementation
- ZFS Filesystem implementation
Afternoon - Networking Implementation
- System layers and interfaces
- Internet Protocols
- Mbufs and control blocks
- Routing issues
- TCP algorithms
Course Text
Prior to taking the course, students are recommended to obtain a copy of the course text: Marshall Kirk McKusick, George Neville-Neil, and Robert N. M. Watson, ``The Design and Implementation of the FreeBSD Operating System'', Second Edition, Pearson Education, Boston, MA September 2014, ISBN-13: 978-0-321-96897-5, ISBN-10: 0-321-96897-2.
An Introduction to the Kernel Services and I/O System
of the FreeBSD Open-Source Operating System
Dr. Marshall Kirk McKusick
Author and Consultant
Who Should Take this Course
This course provides a broad overview of how the FreeBSD kernel implements its basic services. It will be most useful to those who need to learn how these services are provided. Individuals involved in technical and sales support can learn the capabilities and limitations of the system; applications developers can learn how to effectively and efficiently interface to the system; systems programmers without direct experience with the FreeBSD kernel can learn how to maintain, tune, and interface to such systems. This course is directed to users who have had at least a year of experience using a UNIX-like system. They should have an understanding of fundamental algorithms (searching, sorting, and hashing) and data structures (lists, queues, and arrays).
Description
This course will provide a firm background in the kernel services and I/O structure of the FreeBSD kernel. The course will cover basic kernel services, locking, process structure, scheduling, signal handling, jails, capsicum sandboxing, and virtual and physical memory management. The kernel I/O structure will be described showing how I/O is multiplexed, disks are managed, special devices are configured, and system virtualization is done. The presentations will emphasize code organization, data structure navigation, and algorithms. It will not cover the machine specific parts of the system such as the implementation of device drivers.
Morning - Kernel Overview
- Process structure
- Locking
- Communications
- Process Groups and Sessions
- Jails
- Scheduling
- Signals and timers
- Virtual memory management
Afternoon - Kernel I/O structure
- I/O data structures
- Disk Management
- Multiplexing I/O
- Autoconfiguration strategy
- Configuration of a device driver
Course Text
Prior to taking the course, students are recommended to obtain a copy of the course text: Marshall Kirk McKusick, George Neville-Neil, and Robert N. M. Watson, ``The Design and Implementation of the FreeBSD Operating System'', Second Edition, Pearson Education, Boston, MA September 2014, ISBN-13: 978-0-321-96897-5, ISBN-10: 0-321-96897-2.
This talk describes the extended error messages that can now be returned by the FreeBSD kernel. This facility was added in May 2025 shortly before the release of 15.0. The goal was to reduce the terseness of commonly overloaded error codes like EINVAL which occurs at many places in a given system call. For example, the mmap(2) system call can return EINVAL for thirteen different reasons. The single terse error "Invalid argument" is now expanded with thirteen detailed error messages.
This talk will explain how the extended error facility has been added to the kernel, with a brief tutorial on how to incorporate its use into additional kernel subsystems. The talk will conclude by describing how the return and display of extended kernel error messages has been integrated into the err(3) error message system which is already used by many programs and utilities.