Pengutronix Kernel Contributions in 2021

Robert Schwebel | | kernel, linux

2022 has started, and although Corona had a huge impact on our workflow, the Pengutronix team again made quite some contributions to the Linux kernel. The last kernel release in 2020 was 5.10, the last one in 2021 was 5.15, so let's have a look at what happened inbetween.

Like always, Pengutronix' kernel contributions are driven by industrial embedded linux projects: Our customers build devices, we look at what's already supported by the kernel and help with what's missing. Sometimes that means picking up patches from the mailing lists and improving them until they are ready for prime time, sometimes drivers have to be written from scratch, and sometimes even frameworks have to be modified to make a certain feature possible.

Patch series are usually first written to fulfill the project's requirements, then posted to the mailinglists and reviewed by the community and maintainers. So when a patch enters mainline, it often has a months-long, sometimes years-long history.

All in all, 675 patches written by Pengutronix found their way into the kernel in the 5.10 to 5.15 period - more than 1.8 patches per day, and authored by 14 colleagues:

No of Patches Author No of Patches Author
202 Uwe Kleine-König 9 Marco Felsch
149 Marc Kleine-Budde 8 Sascha Hauer
118 Oleksij Rempel 2 Juergen Borleis
48 Lucas Stach 2 Rouven Czerwinski
47 Michael Tretter 1 Jan Luebbe
45 Philipp Zabel 1 Leonard Göhrs
26 Michael Grzeschik 1 Steffen Trumtrar
16 Ahmad Fatoum    

However, the pure number of patches rarely reflects the amount of work that was spent into bringing things mainline. Compared to earlier years, we have much more complex series related to graphics or network topics, which often need quite some rounds of review & rework until they hit mainline. In the end, kernel development continues being about high quality code, and it remains a lot of hard work to get even smaller patches into the kernel.

To get an impression about our work, let me look at the larger topics that have been worked on:

  • Uwe Kleine-König's patches are dominated by his interest in the PWM subsystem: 116 of the 202 patches are in that area. While PWM looks like an easy thing on the first glance, it turned out that there is a lot of undefined semantics and differing behaviour between drivers. So many of these patches are made to improve the kernel towards better subsystem quality.

    Other patches are in the NFC, Input, SPI, hwmon, firmware, backlight, leds, tty, device tree, clock, i2c, rtc and driver core area - functionality that turn up when you bring up random customer hardware and clean up things you find along the way.

  • Marc Kleine-Budde maintains the Linux CAN subsystem, so it's no surprise that 143 of his 149 patches are in the CAN subsystem. In many cases they have been made to improve performance of a certain CAN driver in a given customer scenario: The driver for the Microchip MCP251x (a widely used SPI-to-CAN controler) got 37 patches alone. Other work has been done for many other drivers (rcar, c_can, tcan4x5x, flexcan, at91, hi311x, peak_usb, m_can) and for the CAN subsystem itself.

  • Oleksij Rempel wrote many patches in the area of CAN / J1939 and related to ethernet switches and "modern" ethernet physics, such as 10-Base T1s.

  • Lucas Stach's patches are of course related to Etnaviv, the open source drivers for Vivante GPUs, but also related to clk, power and gpcv2. This reflects his work on bringing i.MX8M support in mainline forward.

  • Michael Tretter worked mainly on the Xilinx UltraScale family and on the "allegro" video encoder and decoder drivers on those chips - a big and complex series that needed many iterations and quite some time to come mainline. UltraScale is a great platform for customer specific video processing - a topic that is becoming more and more interesting for our customers!

  • Philipp Zabel maintains the reset subsystem in the kernel. In addition, he continued his work on the CODA and other i.MX graphics and video components.

  • Michael Grzeschik worked mainly in two areas: The KSZ8795 ethernet switch and USB UVC.

  • Ahmad Fatoum took care of many i.MX8M related bug fixes, including clock issues, TF-A interfacing and deferred probe handling. He also worked on STM32MP1, nvmem, dm crypt and sensors.

  • Marco Felsch, Sascha Hauer, Jürgen Borleis, Rouven Czerwinski, Jan Lübbe and Steffen Trumtrar worked on spi, ASoC, the CODA, ethernet chips and switches, pwms, i2c, etnaviv, ecryptfs, quota, NAND flash, ubifs, DMA on i.MX, regulators, OP-TEE and network timestamping.

  • Last but not least, our hardware developer Leonard Göhrs got his first patch into the kernel, fixing an ALSA sound problem on PowerPC :-)

Looking through the impressive list of 675 patches and knowing all the engineering stories behind small one-liners as well as super-huge patch series, I think we can be satisfied with what we improved in the kernel in 2021. A lot of interaction with the other kernel developers and maintainers happened along the way, and we learned a lot.

And, last but not least, quite many customer problems got solved in a sustainable way. Issues that are fixed in mainline will not hurt other people out there in the future. So please, if you would have been hit by a problem that we (or others in the community) already solved, please express your thankfullness by bringing your patches mainline as well :-)

The kernel history goes back to Linux 2.5.0, and with the recent contributions, we now have 6278 patches in mainline.

Happy new year!

Further Readings

Wie man (k)ein Betriebssystem für Produkte baut

Distributionen wie Raspbian lassen die passgenaue Zusammenstellung eines Betriebssystems kinderleicht aussehen. Image herunterladen, Pakete installieren, noch ein paar Änderungen - fertig. Alles wie auf dem Laptop oder Server. Warum ein Betriebssystem aus einer klassischen Distribution im Produkt-Kontext zur Katastrophe führen kann, beleuchtet der Vortrag "Raspbian vs. Build-Systeme: Das richtige Werkzeug für solide Produkte".

CLT-2021: Mach es einfach anders!

Marie Mann | | clt, linux, opensource

"Mach es einfach anders!" - unter diesem Motto finden die CLT dieses Jahr im virtuellen Raum statt. Wie auch in den letzten Jahren ist Pengutronix als Sponsor dabei. Anders ist, dass wir dieses Jahr unser eigenes kleines Programm mit spannenden Kurzvorträgen und täglich zwei Quiz-Runden mit tollen Hauptgewinnen mitbringen.

Showcase: Preempt RT and Time Sensitive Networking

Nowadays, even small and cheap microcontrollers offer enough calculation power to perform time critical tasks within an industrial environment. However, as soon as actors and sensors are spread over an entire facility and are to be connected over Ethernet, the actual moment when a data packet will get processed becomes very hard to predict. At this point, Linux running a Preempt RT Kernel altogether with a network featuring Time Sensitive Networking (TSN) capabilities can help.

Pengutronix at FOSDEM 2021

"FOSDEM is a free event for software developers to meet, share ideas and collaborate. Every year, thousands of developers of free and open source software from all over the world gather at the event in Brussels. In 2021, they will gather online." -- FOSDEM

15 Years of i.MX in Mainline Linux

Today it has been 15 years since we mainlined support for Freescale/NXP's i.MX architecture in the Linux kernel! That was one small step for [a] man, one giant leap for (industrial Linux users') mankind :-) Here is some background about why it happened and what you might want to learn from history for your next embedded Linux project.

What Kernel Should I Use (Embedded Edition)

Some days ago, Greg Kroah-Hartmann wrote a great blogpost about Which Stable Kernel One Should Use?. I fully agree with his position; however, I'd like to make some additions for the industry device manufacturer use case and some common pitfalls and misunderstandings we see in that area.