The Salmon Diet: Up-Streaming Drivers as a Form of Optimization - Gilad Ben-Yossef, Arm
Channel: The Linux Foundation
Date: 15/03/2018

The Salmon Diet: Up-Streaming Drivers as a Form of Optimization - Gilad Ben-Yossef, Arm

 As Linux developers we know that up-streaming device drivers is a good idea for many reasons: maintainability, ease of customer access and even just doing the right thing.

There is however one more benefit less talked about: up-streaming makes your code better.

Since February 2017 my team has worked on up-streaming the than out-of-tree CryptoCell REE device driver, which existed and has been in active use and development for several years.

As part of this effort, we diligently followed the instructions of the community and mentors to bring the code to the desired quality and style and noticed a surprising pattern: almost each set of changes reduced the code line count, and yet the functionality stayed the same while the bug count decreased and we ended up with 30% less lines of code doing the same thing, yet better.

This is the story of this project and what can be learned from it. 

About Gilad Ben-Yossef
Gilad Ben-Yossef is a principal software engineer working at Arm on upstream kernel security at large and Arm CryptCell engine support in particular. Gilad is the co-author of O’Reilly’s “Building Embedded Linux Systems” 2nd edition, co-founder of the Israeli FOSS NGO "HaMakor" and presented at LinuxWorld, Embedded Linux Conference Europe and the Ottawa Linux Symposium.