This document discusses not breaking userspace through maintaining the Linux application binary interface (ABI). It begins by defining what an ABI is and how it guarantees compatibility between userspace applications and the Linux kernel. It then discusses several examples where ABI breaks have occurred or may need to occur, such as for the 2038 time issue, priority inheritance in threading, and changes to tools like BPF programs. The document provides methods for avoiding ABI breaks, such as unused function parameters and exporting information to sysfs. It concludes that maintaining the ABI is important but also sometimes unavoidable when new features are needed.
Debugging is an essential part of Linux kernel development. In
user-space we have the support of the kernel and many debugging tools, tracking down a kernel bug, instead, can be very difficult if you don't know the proper methodologies. This talk will cover some techniques to understand how the kernel works, hunt down and fix kernel bugs in order to become a better kernel developer.
eBPF is an exciting new technology that is poised to transform Linux performance engineering. eBPF enables users to dynamically and programatically trace any kernel or user space code path, safely and efficiently. However, understanding eBPF is not so simple. The goal of this talk is to give audiences a fundamental understanding of eBPF, how it interconnects existing Linux tracing technologies, and provides a powerful aplatform to solve any Linux performance problem.
An Introduction to eBPF (and cBPF). Topics covered include history, implementation, program types & maps. Also gives a brief introduction to XDP and DPDK
SFO15-BFO2: Reducing the arm linux kernel size without losing your mindLinaro
SFO15-BF02: Reducing the arm linux kernel size without losing your mind
Speaker: Nicolas Pitre
Date: September 24, 2015
★ Session Description ★
Automatically reducing the Linux kernel size may be achieved in
different ways. Using LTO (Link Time Optimization) is one such way with many advantages, but it also has major issues. A simpler alternative is linker section garbage collection. However, it turns out that even “simpler” solutions have their share of unsuspected pitfalls, especially on ARM. Those pitfalls and proposed solutions are the subjects of this discussion.
★ Resources ★
Video: https://www.youtube.com/watch?v=tnKO0TKi3wo
Presentation: http://www.slideshare.net/linaroorg/sfo15bfo2-reducing-the-arm-linux-kernel-size-without-losing-your-mind
Pathable: https://sfo15.pathable.com/meetings/318624
★ Event Details ★
Linaro Connect San Francisco 2015 - #SFO15
September 21-25, 2015
Hyatt Regency Hotel
http://www.linaro.org
http://connect.linaro.org
The Hitchhiker's Guide to Faster Builds. Viktor Kirilov. CoreHard Spring 2019corehard_by
C++ is known for things such as performance, expressiveness, the lack of a standard build system and package management, complexity and long compile times. The inability to iterate quickly is one of the biggest killers of productivity. This talk is aimed at anyone interested in improving the last of these points - it will provide insights into why compilation (and linking) take so long for C++ and will then provide an exhaustive list of techniques and tools to mitigate the problem, such as: - tooling and infrastructure - hardware, build systems, caching, distributed builds, diagnostics of bottlenecks, code hygiene - techniques - unity builds, precompiled headers, linking (static vs shared libraries) - source code modification - the PIMPL idiom, better template use, annotations - modules - what they are, when they are coming to C++ and what becomes obsolete because of them
ELC North America 2021 Introduction to pin muxing and gpio control under linuxNeil Armstrong
In the last 10 years, the GPIO and PINCTRL subsystem matured to support almost every possible handling of Programmable Input/Outputs and more generally multiplexing of multiple functions on single "Pins" or group of "Pins". However, what is a "Pin"? What is a multiplexed "Function"? How programmable I/Os and pin functions are designed on the majority of System-On-Chips? Neil will describe this from the Hardware design Point-Of-View, the constraints and the requirements. Then Neil will explain how this particular subject was handled over the years in the Linux kernel, to finally get to the current GPIO & PINCTRL subsystems, and how it articulates with the Device Tree and other Firmware based protocols.
Debugging is an essential part of Linux kernel development. In
user-space we have the support of the kernel and many debugging tools, tracking down a kernel bug, instead, can be very difficult if you don't know the proper methodologies. This talk will cover some techniques to understand how the kernel works, hunt down and fix kernel bugs in order to become a better kernel developer.
eBPF is an exciting new technology that is poised to transform Linux performance engineering. eBPF enables users to dynamically and programatically trace any kernel or user space code path, safely and efficiently. However, understanding eBPF is not so simple. The goal of this talk is to give audiences a fundamental understanding of eBPF, how it interconnects existing Linux tracing technologies, and provides a powerful aplatform to solve any Linux performance problem.
An Introduction to eBPF (and cBPF). Topics covered include history, implementation, program types & maps. Also gives a brief introduction to XDP and DPDK
SFO15-BFO2: Reducing the arm linux kernel size without losing your mindLinaro
SFO15-BF02: Reducing the arm linux kernel size without losing your mind
Speaker: Nicolas Pitre
Date: September 24, 2015
★ Session Description ★
Automatically reducing the Linux kernel size may be achieved in
different ways. Using LTO (Link Time Optimization) is one such way with many advantages, but it also has major issues. A simpler alternative is linker section garbage collection. However, it turns out that even “simpler” solutions have their share of unsuspected pitfalls, especially on ARM. Those pitfalls and proposed solutions are the subjects of this discussion.
★ Resources ★
Video: https://www.youtube.com/watch?v=tnKO0TKi3wo
Presentation: http://www.slideshare.net/linaroorg/sfo15bfo2-reducing-the-arm-linux-kernel-size-without-losing-your-mind
Pathable: https://sfo15.pathable.com/meetings/318624
★ Event Details ★
Linaro Connect San Francisco 2015 - #SFO15
September 21-25, 2015
Hyatt Regency Hotel
http://www.linaro.org
http://connect.linaro.org
The Hitchhiker's Guide to Faster Builds. Viktor Kirilov. CoreHard Spring 2019corehard_by
C++ is known for things such as performance, expressiveness, the lack of a standard build system and package management, complexity and long compile times. The inability to iterate quickly is one of the biggest killers of productivity. This talk is aimed at anyone interested in improving the last of these points - it will provide insights into why compilation (and linking) take so long for C++ and will then provide an exhaustive list of techniques and tools to mitigate the problem, such as: - tooling and infrastructure - hardware, build systems, caching, distributed builds, diagnostics of bottlenecks, code hygiene - techniques - unity builds, precompiled headers, linking (static vs shared libraries) - source code modification - the PIMPL idiom, better template use, annotations - modules - what they are, when they are coming to C++ and what becomes obsolete because of them
ELC North America 2021 Introduction to pin muxing and gpio control under linuxNeil Armstrong
In the last 10 years, the GPIO and PINCTRL subsystem matured to support almost every possible handling of Programmable Input/Outputs and more generally multiplexing of multiple functions on single "Pins" or group of "Pins". However, what is a "Pin"? What is a multiplexed "Function"? How programmable I/Os and pin functions are designed on the majority of System-On-Chips? Neil will describe this from the Hardware design Point-Of-View, the constraints and the requirements. Then Neil will explain how this particular subject was handled over the years in the Linux kernel, to finally get to the current GPIO & PINCTRL subsystems, and how it articulates with the Device Tree and other Firmware based protocols.
Clear Containers is an Open Containers Initiative (OCI) “runtime” that launches an Intel VT-x secured hypervisor rather than a standard Linux container. An introduction of Clear Containers will be provided, followed by an overview of CNM networking plugins which have been created to enhance network connectivity using Clear Containers. More specifically, we will show demonstrations of using VPP with DPDK and SRIO-v based networks to connect Clear Containers. Pending time we will provide and walk through a hands on example of using VPP with Clear Containers.
About the speaker: Manohar Castelino is a Principal Engineer for Intel’s Open Source Technology Center. Manohar has worked on networking, network management, network processors and virtualization for over 15 years. Manohar is currently an architect and developer with the ciao (clearlinux.org/ciao) and the clear containers (https://github.com/01org/cc-oci-runtime) projects focused on networking. Manohar has spoken at many Container Meetups and internal conferences.
UM2019 Extended BPF: A New Type of SoftwareBrendan Gregg
Keynote for Ubuntu Masters 2019 by Brendan Gregg, Netflix. Video https://www.youtube.com/watch?v=7pmXdG8-7WU&feature=youtu.be . "Extended BPF is a new type of software, and the first fundamental change to how kernels are used in 50 years. This new type of software is already in use by major companies: Netflix has 14 BPF programs running by default on all of its cloud servers, which run Ubuntu Linux. Facebook has 40 BPF programs running by default. Extended BPF is composed of an in-kernel runtime for executing a virtual BPF instruction set through a safety verifier and with JIT compilation. So far it has been used for software defined networking, performance tools, security policies, and device drivers, with more uses planned and more we have yet to think of. It is changing how we use and think about systems. This talk explores the past, present, and future of BPF, with BPF performance tools as a use case."
Kernel Recipes 2015 - So you want to write a Linux driver frameworkAnne Nicolas
Writing a new driver framework in Linux is hard. There are many pitfalls along the way; this talk hopes to point out some of those pitfalls and hard lessons learned through examples, advice and humorous anecdotes in the hope that it will aid those adventurous enough to take on the task of writing a new driver framework. The scope of the talk includes internal framework design as well as external API design exposed to drivers and consumers of the framework. This presentation pulls directly from the Michael Turquette’s experience authoring the Common Clock
Framework and maintaining that code for the last four years.
Additionally Mike has solicited tips and advice from other subsystem maintainers, for a well-rounded overview. Be prepared to learn some winning design patterns and hear some embarrassing stories of framework design gone wrong.
Mike Turquette, BayLibre
Share the Experience of Using Embedded Development BoardJian-Hong Pan
(Including Demo videos at end of the description)
Due to the pandemic in the past few years, lacking chips became one of the reasons that vendors cannot produce products. That affects industry, automotive and IT, etc. In addition, many countries propose new policies/acts which start to investigate the source of products recently. Therefore, keeping the flexibility of the usage of parts to maintain the robustness of productivity and service is an important skill. This talk will list the toolchains & debug tools for common chip architectures and share some development experience.
This talk will share how to use the open source toolchain and debug tools to develop and debug, then flash the program to the ARM Cortex-M development board. The same idea can be used on other chip’s development boards. Will have some examples for ARM Cortex-A and RISC-V 32 & 64 Bits environment. Besides, will share the experience of sending patches to the debug tool and co-working with upstream, too.
Demo Videos:
* Develop with Nuvoton's NuTiny-SDK-NUC472 https://www.youtube.com/watch?v=Yz9uw2_9KS8
* Develop with Longan Nano https://www.youtube.com/watch?v=IFqDM_GLUfo
* Boot Custom Linux Image on Raspberry Pi 4B https://www.youtube.com/watch?v=t3PjTtf5MvU
* Boot Linux on QEMU RISC-V 64 Bits VM https://www.youtube.com/watch?v=8c7zfvJYzSo
* Develop with Arduino Nano https://www.youtube.com/watch?v=sU7X9Q35hhY
Dataplane programming with eBPF: architecture and toolsStefano Salsano
eBPF is definitely a complex technology. Developing complex systems based on eBPF is challenging due to the intrinsic limitations of the model and the known shortcomings of the tool chain.
The learning curve of this technology is very steep and needs continuous coaching from experts. This tutorial will investigate:
What is eBPF and why it has gained a prominent position among the solutions to improve the packet processing performance in Linux/x86 nodes. We will shortly present some important use case scenarios for eBPF, like Kubernetes’ Cilium
The architecture of eBPF and its programming toolchain (e.g. bcc
What are the frameworks for eBPF programming, such as Polycube and InKeV.
How to make eBPF programming easier, more flexible and modular with HIKe/eCLAT
How to implement a custom application logic in eBPF with eCLAT using a python-like script
How to extend the framework and develop new modules
eBPF Debugging Infrastructure - Current TechniquesNetronome
eBPF (extended Berkeley Packet Filter), in particular with its driver-level hook XDP (eXpress Data Path), has increased in importance over the past few years. As a result, the ability to rapidly debug and diagnose problems is becoming more relevant. This talk will cover common issues faced and techniques to diagnose them, including the use of bpftool for map and program introspection, the use of disassembly to inspect generated assembly code and other methods such as using debug prints and how to apply these techniques when eBPF programs are offloaded to the hardware.
The talk will also explore where the current gaps in debugging infrastructure are and suggest some of the next steps to improve this, for example, integrations with tools such as strace, valgrind or even the LLDB debugger.
Using open source software to build an industrial grade embedded linux platfo...SZ Lin
Building an embedded Linux platform is like a puzzle; placing the suitable software components in the right positions will constitute an optimal platform. However, selecting suitable components is difficult since it depends on different application scenarios. The essential components of an embedded Linux platform include the bootloader, Linux kernel, toolchain, root filesystem; it also needs the tools for image generation, upgrades, and testing. There are abundant resources in the Linux ecosystem with these components and tools; however, selecting the suitable modules and tools is still a key challenge for system designers.
BPF & Cilium - Turning Linux into a Microservices-aware Operating SystemThomas Graf
Container runtimes cause Linux to return to its original purpose: to serve applications interacting directly with the kernel. At the same time, the Linux kernel is traditionally difficult to change and its development process is full of myths. A new efficient in-kernel programming language called eBPF is changing this and allows everyone to extend existing kernel components or glue them together in new forms without requiring to change the kernel itself.
Linux Kernel Platform Development: Challenges and InsightsGlobalLogic Ukraine
This presentation is about the main tasks which Linux kernel platform engineers take care of. The talk includes real-life cases which help understand the role of respective specialists and might be helpful to those who consider such change in their careers.
The talk was delivered by Sam Protsenko (Software Engineer, Consultant, GlobalLogic) at GlobalLogic Embedded Career Day #2 on February 10, 2018.
More about GlobalLogic Embedded Career Day #2: https://www.globallogic.com/ua/events/globallogic-kyiv-embedded-career-day-2-materials
Implementation of Soft-core processor on FPGA (Final Presentation)Deepak Kumar
Implementation of Soft-core processor(PicoBlaze) on FPGA using Xilinx.
Establishing communication between two PicoBlaze processors.
Creating an application using the multi-core processor.
This talk will provide several examples of how Facebook engineers use BPF to scale the networking, prevent denial of service, secure containers, analyze performance. It’s suitable for BPF newbies and experts.
Alexei Starovoitov, Facebook
The Linux kernel is undergoing the most fundamental architecture evolution in history and is becoming a microkernel. Why is the Linux kernel evolving into a microkernel? The potentially biggest fundamental change ever happening to the Linux kernel. This talk covers how companies like Facebook and Google use BPF to patch 0-day exploits, how BPF will change the way features are added to the kernel forever, and how BPF is introducing a new type of application deployment method for the Linux kernel.
Utilizing AMD GPUs: Tuning, programming models, and roadmapGeorge Markomanolis
A presentation at FOSDEM 2022 about AMD GPUs, tuning, programming models and software roadmap. This is continuation from the previous talk (FOSDEM 2021)
Supporting SW Update via u-boot and GPT/EFIAlison Chaiken
A/B partition flipping is a traditional software update method for embedded devices. The Linux kernel notifies the bootloader of an image flip via a memory message at reboot. The strategy did not work for a processor which required a power-on reset due to a PMIC bug. The solution was to extend u-boot to allow the information to be stored in a GPT partition table on the storage device.
Clear Containers is an Open Containers Initiative (OCI) “runtime” that launches an Intel VT-x secured hypervisor rather than a standard Linux container. An introduction of Clear Containers will be provided, followed by an overview of CNM networking plugins which have been created to enhance network connectivity using Clear Containers. More specifically, we will show demonstrations of using VPP with DPDK and SRIO-v based networks to connect Clear Containers. Pending time we will provide and walk through a hands on example of using VPP with Clear Containers.
About the speaker: Manohar Castelino is a Principal Engineer for Intel’s Open Source Technology Center. Manohar has worked on networking, network management, network processors and virtualization for over 15 years. Manohar is currently an architect and developer with the ciao (clearlinux.org/ciao) and the clear containers (https://github.com/01org/cc-oci-runtime) projects focused on networking. Manohar has spoken at many Container Meetups and internal conferences.
UM2019 Extended BPF: A New Type of SoftwareBrendan Gregg
Keynote for Ubuntu Masters 2019 by Brendan Gregg, Netflix. Video https://www.youtube.com/watch?v=7pmXdG8-7WU&feature=youtu.be . "Extended BPF is a new type of software, and the first fundamental change to how kernels are used in 50 years. This new type of software is already in use by major companies: Netflix has 14 BPF programs running by default on all of its cloud servers, which run Ubuntu Linux. Facebook has 40 BPF programs running by default. Extended BPF is composed of an in-kernel runtime for executing a virtual BPF instruction set through a safety verifier and with JIT compilation. So far it has been used for software defined networking, performance tools, security policies, and device drivers, with more uses planned and more we have yet to think of. It is changing how we use and think about systems. This talk explores the past, present, and future of BPF, with BPF performance tools as a use case."
Kernel Recipes 2015 - So you want to write a Linux driver frameworkAnne Nicolas
Writing a new driver framework in Linux is hard. There are many pitfalls along the way; this talk hopes to point out some of those pitfalls and hard lessons learned through examples, advice and humorous anecdotes in the hope that it will aid those adventurous enough to take on the task of writing a new driver framework. The scope of the talk includes internal framework design as well as external API design exposed to drivers and consumers of the framework. This presentation pulls directly from the Michael Turquette’s experience authoring the Common Clock
Framework and maintaining that code for the last four years.
Additionally Mike has solicited tips and advice from other subsystem maintainers, for a well-rounded overview. Be prepared to learn some winning design patterns and hear some embarrassing stories of framework design gone wrong.
Mike Turquette, BayLibre
Share the Experience of Using Embedded Development BoardJian-Hong Pan
(Including Demo videos at end of the description)
Due to the pandemic in the past few years, lacking chips became one of the reasons that vendors cannot produce products. That affects industry, automotive and IT, etc. In addition, many countries propose new policies/acts which start to investigate the source of products recently. Therefore, keeping the flexibility of the usage of parts to maintain the robustness of productivity and service is an important skill. This talk will list the toolchains & debug tools for common chip architectures and share some development experience.
This talk will share how to use the open source toolchain and debug tools to develop and debug, then flash the program to the ARM Cortex-M development board. The same idea can be used on other chip’s development boards. Will have some examples for ARM Cortex-A and RISC-V 32 & 64 Bits environment. Besides, will share the experience of sending patches to the debug tool and co-working with upstream, too.
Demo Videos:
* Develop with Nuvoton's NuTiny-SDK-NUC472 https://www.youtube.com/watch?v=Yz9uw2_9KS8
* Develop with Longan Nano https://www.youtube.com/watch?v=IFqDM_GLUfo
* Boot Custom Linux Image on Raspberry Pi 4B https://www.youtube.com/watch?v=t3PjTtf5MvU
* Boot Linux on QEMU RISC-V 64 Bits VM https://www.youtube.com/watch?v=8c7zfvJYzSo
* Develop with Arduino Nano https://www.youtube.com/watch?v=sU7X9Q35hhY
Dataplane programming with eBPF: architecture and toolsStefano Salsano
eBPF is definitely a complex technology. Developing complex systems based on eBPF is challenging due to the intrinsic limitations of the model and the known shortcomings of the tool chain.
The learning curve of this technology is very steep and needs continuous coaching from experts. This tutorial will investigate:
What is eBPF and why it has gained a prominent position among the solutions to improve the packet processing performance in Linux/x86 nodes. We will shortly present some important use case scenarios for eBPF, like Kubernetes’ Cilium
The architecture of eBPF and its programming toolchain (e.g. bcc
What are the frameworks for eBPF programming, such as Polycube and InKeV.
How to make eBPF programming easier, more flexible and modular with HIKe/eCLAT
How to implement a custom application logic in eBPF with eCLAT using a python-like script
How to extend the framework and develop new modules
eBPF Debugging Infrastructure - Current TechniquesNetronome
eBPF (extended Berkeley Packet Filter), in particular with its driver-level hook XDP (eXpress Data Path), has increased in importance over the past few years. As a result, the ability to rapidly debug and diagnose problems is becoming more relevant. This talk will cover common issues faced and techniques to diagnose them, including the use of bpftool for map and program introspection, the use of disassembly to inspect generated assembly code and other methods such as using debug prints and how to apply these techniques when eBPF programs are offloaded to the hardware.
The talk will also explore where the current gaps in debugging infrastructure are and suggest some of the next steps to improve this, for example, integrations with tools such as strace, valgrind or even the LLDB debugger.
Using open source software to build an industrial grade embedded linux platfo...SZ Lin
Building an embedded Linux platform is like a puzzle; placing the suitable software components in the right positions will constitute an optimal platform. However, selecting suitable components is difficult since it depends on different application scenarios. The essential components of an embedded Linux platform include the bootloader, Linux kernel, toolchain, root filesystem; it also needs the tools for image generation, upgrades, and testing. There are abundant resources in the Linux ecosystem with these components and tools; however, selecting the suitable modules and tools is still a key challenge for system designers.
BPF & Cilium - Turning Linux into a Microservices-aware Operating SystemThomas Graf
Container runtimes cause Linux to return to its original purpose: to serve applications interacting directly with the kernel. At the same time, the Linux kernel is traditionally difficult to change and its development process is full of myths. A new efficient in-kernel programming language called eBPF is changing this and allows everyone to extend existing kernel components or glue them together in new forms without requiring to change the kernel itself.
Linux Kernel Platform Development: Challenges and InsightsGlobalLogic Ukraine
This presentation is about the main tasks which Linux kernel platform engineers take care of. The talk includes real-life cases which help understand the role of respective specialists and might be helpful to those who consider such change in their careers.
The talk was delivered by Sam Protsenko (Software Engineer, Consultant, GlobalLogic) at GlobalLogic Embedded Career Day #2 on February 10, 2018.
More about GlobalLogic Embedded Career Day #2: https://www.globallogic.com/ua/events/globallogic-kyiv-embedded-career-day-2-materials
Implementation of Soft-core processor on FPGA (Final Presentation)Deepak Kumar
Implementation of Soft-core processor(PicoBlaze) on FPGA using Xilinx.
Establishing communication between two PicoBlaze processors.
Creating an application using the multi-core processor.
This talk will provide several examples of how Facebook engineers use BPF to scale the networking, prevent denial of service, secure containers, analyze performance. It’s suitable for BPF newbies and experts.
Alexei Starovoitov, Facebook
The Linux kernel is undergoing the most fundamental architecture evolution in history and is becoming a microkernel. Why is the Linux kernel evolving into a microkernel? The potentially biggest fundamental change ever happening to the Linux kernel. This talk covers how companies like Facebook and Google use BPF to patch 0-day exploits, how BPF will change the way features are added to the kernel forever, and how BPF is introducing a new type of application deployment method for the Linux kernel.
Utilizing AMD GPUs: Tuning, programming models, and roadmapGeorge Markomanolis
A presentation at FOSDEM 2022 about AMD GPUs, tuning, programming models and software roadmap. This is continuation from the previous talk (FOSDEM 2021)
Similar to Not breaking userspace: the evolving Linux ABI (20)
Supporting SW Update via u-boot and GPT/EFIAlison Chaiken
A/B partition flipping is a traditional software update method for embedded devices. The Linux kernel notifies the bootloader of an image flip via a memory message at reboot. The strategy did not work for a processor which required a power-on reset due to a PMIC bug. The solution was to extend u-boot to allow the information to be stored in a GPT partition table on the storage device.
A presentation by John Kenney of Toyota InfoTechnology Center on Apr 9 2019 to the Silicon Valley Automotive Open Source Group: https://www.meetup.com/Silicon-Valley-Automotive-Open-Source/events/259384384/
Practical Challenges to Deploying Highly Automated VehiclesAlison Chaiken
Presentation by Dr. Steven Shladover of UC Berkeley on Jan 24, 2019 as part of the Silicon Valley Automotive Open Source meetup group speak series
https://www.meetup.com/Silicon-Valley-Automotive-Open-Source/events/256100027/
All about the Linux boot process. Presented at linux.conf.au on January 25, 2018. Video at https://archive.org/details/lca2018-Linux_the_first_second . Associated blog posting at https://opensource.com/article/18/1/analyzing-linux-boot-process
Functional AI and Pervasive Networking in AutomotiveAlison Chaiken
Presented ath the Sept 25, 2017 meeting of the Silicon Valley Automotive Open sSource Group. About RTI's open-source DDS middleware and how it promotes rapid development of vehicle LANs.
IRQs: the Hard, the Soft, the Threaded and the PreemptibleAlison Chaiken
The Linux kernel supports a diverse set of interrupt handlers that partition work into immediate and deferred tasks. The talk introduces the major varieties and explains how IRQs differ in the real-time kernel.
A talk presented at the Automotive Grade Linux All-Members meeting on September 8, 2015. The focus on why AGL should adopt systemd, and highlights two of the more difficult integration issues that may arise while doing so. The embedded SVG image, courtesy Marko Hoyer of ADIT, is at http://she-devel.com/2015-07-23_amm_demo.svg
Talk from Embedded Linux Conference, http://elcabs2015.sched.org/event/551ba3cdefe2d37c478810ef47d4ca4c?iframe=no&w=i:0;&sidebar=yes&bg=no#.VRUCknSQQQs
Trends in and features of automotive Linux, with an emphasis on Android. Presented at Google Developer Group in Mountain View, CA, USA on February 4, 2015.
Systemd: the modern Linux init system you will learn to loveAlison Chaiken
The talk combines a design overview of systemd with some tutorial incofrmation about how to configure it. Systemd's features and pitfalls are illustrated by short demos and real-life examples. Files used in the demos are listed under "Presentations" at http://she-devel.com/
Video of the live presentation will appear here:
http://www.meetup.com/Silicon-Valley-Linux-Technology/events/208133972/
Best practices for long-term support and security of the device-treeAlison Chaiken
Considerations in design of Linux kernel device-tree source, maintenance of source repositories and helpful tools for validation, source examination and over-the-area updates, particular for vehicular and IVI applications.
Final project report on grocery store management system..pdfKamal Acharya
In today’s fast-changing business environment, it’s extremely important to be able to respond to client needs in the most effective and timely manner. If your customers wish to see your business online and have instant access to your products or services.
Online Grocery Store is an e-commerce website, which retails various grocery products. This project allows viewing various products available enables registered users to purchase desired products instantly using Paytm, UPI payment processor (Instant Pay) and also can place order by using Cash on Delivery (Pay Later) option. This project provides an easy access to Administrators and Managers to view orders placed using Pay Later and Instant Pay options.
In order to develop an e-commerce website, a number of Technologies must be studied and understood. These include multi-tiered architecture, server and client-side scripting techniques, implementation technologies, programming language (such as PHP, HTML, CSS, JavaScript) and MySQL relational databases. This is a project with the objective to develop a basic website where a consumer is provided with a shopping cart website and also to know about the technologies used to develop such a website.
This document will discuss each of the underlying technologies to create and implement an e- commerce website.
Welcome to WIPAC Monthly the magazine brought to you by the LinkedIn Group Water Industry Process Automation & Control.
In this month's edition, along with this month's industry news to celebrate the 13 years since the group was created we have articles including
A case study of the used of Advanced Process Control at the Wastewater Treatment works at Lleida in Spain
A look back on an article on smart wastewater networks in order to see how the industry has measured up in the interim around the adoption of Digital Transformation in the Water Industry.
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptxR&R Consult
CFD analysis is incredibly effective at solving mysteries and improving the performance of complex systems!
Here's a great example: At a large natural gas-fired power plant, where they use waste heat to generate steam and energy, they were puzzled that their boiler wasn't producing as much steam as expected.
R&R and Tetra Engineering Group Inc. were asked to solve the issue with reduced steam production.
An inspection had shown that a significant amount of hot flue gas was bypassing the boiler tubes, where the heat was supposed to be transferred.
R&R Consult conducted a CFD analysis, which revealed that 6.3% of the flue gas was bypassing the boiler tubes without transferring heat. The analysis also showed that the flue gas was instead being directed along the sides of the boiler and between the modules that were supposed to capture the heat. This was the cause of the reduced performance.
Based on our results, Tetra Engineering installed covering plates to reduce the bypass flow. This improved the boiler's performance and increased electricity production.
It is always satisfying when we can help solve complex challenges like this. Do your systems also need a check-up or optimization? Give us a call!
Work done in cooperation with James Malloy and David Moelling from Tetra Engineering.
More examples of our work https://www.r-r-consult.dk/en/cases-en/
Immunizing Image Classifiers Against Localized Adversary Attacksgerogepatton
This paper addresses the vulnerability of deep learning models, particularly convolutional neural networks
(CNN)s, to adversarial attacks and presents a proactive training technique designed to counter them. We
introduce a novel volumization algorithm, which transforms 2D images into 3D volumetric representations.
When combined with 3D convolution and deep curriculum learning optimization (CLO), itsignificantly improves
the immunity of models against localized universal attacks by up to 40%. We evaluate our proposed approach
using contemporary CNN architectures and the modified Canadian Institute for Advanced Research (CIFAR-10
and CIFAR-100) and ImageNet Large Scale Visual Recognition Challenge (ILSVRC12) datasets, showcasing
accuracy improvements over previous techniques. The results indicate that the combination of the volumetric
input and curriculum learning holds significant promise for mitigating adversarial attacks without necessitating
adversary training.
Saudi Arabia stands as a titan in the global energy landscape, renowned for its abundant oil and gas resources. It's the largest exporter of petroleum and holds some of the world's most significant reserves. Let's delve into the top 10 oil and gas projects shaping Saudi Arabia's energy future in 2024.
Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...Dr.Costas Sachpazis
Terzaghi's soil bearing capacity theory, developed by Karl Terzaghi, is a fundamental principle in geotechnical engineering used to determine the bearing capacity of shallow foundations. This theory provides a method to calculate the ultimate bearing capacity of soil, which is the maximum load per unit area that the soil can support without undergoing shear failure. The Calculation HTML Code included.
Water scarcity is the lack of fresh water resources to meet the standard water demand. There are two type of water scarcity. One is physical. The other is economic water scarcity.
Student information management system project report ii.pdfKamal Acharya
Our project explains about the student management. This project mainly explains the various actions related to student details. This project shows some ease in adding, editing and deleting the student details. It also provides a less time consuming process for viewing, adding, editing and deleting the marks of the students.
1. Not breaking userspace: the evolving Linux ABI
Alison Chaiken
Southern California Linux Expo 2022
alison@she-devel.com
Slides: http://she-devel.com/Chaiken_LinuxABI.pdf
Blue text indicates hyperlinks.
3. 3
Contents
●
What is an ABI and what is Linux’s?
●
Why does it matter?
– 64-bit time (Y2038)
– Priority inversions and robotics
– Writing and maintaining log monitors
– Mounting old filesystems
– Mixing BPF programs and udev rules
●
How to avoid ABI breaks
●
Summary
4. 4
What is an Application Binary Interface?
●
Library headers and documentation are the API.
●
For C programs in general:
– return types of functions;
– parameter lists of functions;
– layout of structs
– meaning, range or ordering of enums.
●
Lack of “name mangling” in C is a problem.
5. 5
ABI Guarantees are a Contract
compiler
libc
(syscalls)
userspace
(ELF)
Linux
kernel
11. 11
Two bad choices for distros with 32-bit arches
A. complete set of 32- and
64-bit-time packages;
OR
B. distinct 32- and 64-bit-time
images: i386 and i386t
https://tinyurl.com/mryr56ee
13. 13
Priority inversion occurs when L-prio thread holds
a lock that H-prio thread needs
Priority
Time
Lo-prio
takes
lock
Hi-prio
needs
lock
14. 14
Priority Inheritance in Realtime Kernel Boosts the
L-prio thread temporarily
Vital for userspace tasks as well as kernel!
Time
Priority
Hi-prio
needs
lock
Lo-prio
takes
lock
16. 16
Fix Requires an ABI Break
Either:
●
a syscall must take an additional argument;
-or-
●
a function arg (the “futex word”) must change from
32- to 64-bit.
17. 17
Robotics projects need a different pthread library
tinyurl.com/2p99dtan,
https://tinyurl.com/2rmmmban
glibc
librtpi
Or an entirely different
libc!
musl
18. 18
What is in the Linux Kernel Stable ABI?
Advertised: ELF, /proc, /sys and device-tree.
What about :
●
Devices in /dev?
●
printk output (dmesg)?
●
Bootargs (cmdline)?
●
Module params?
●
Netlink sockets?
●
Tracepoints?
●
Valid BPF programs?
●
Filesystem metadata?
●
Meaning of constants
in headers?
?
?
?
?
?
?
?
?
26. 26
Will old filesystems mount with new kernels?
Manipulating FS metadata with custom tool relies on
Undefined Behavior.
“I was under the impression
that mounting existing FSs
fell under the scope of the
kernel⇔userspace
boundary”
it's not just about
"whatever the kernel
happens to accept". It
should also be, "was it
generated using an
official version of the
userspace tools",
27. 27
ABI Contract holds if official userspace tools are used
libc: mount
Linux
kernel
What about FS from Windows, iOS, BSD?
userspace:
e2fsprogs,
zfsutils, etc.
31. 31
What about Kernel Features on which BPF Programs Rely?
Stable ABI is any ‘"user
workflow", whether it uses
BPF or any other kernel
feature’
OSS 2022,
6/21/22
“out-of-tree modules
will have the technical
debt of changing every
time a new kernel
release is out, and so
should out-of-tree bpf
programs.”
Kernel Summit mailing list
6/16/22
Photo:
https://lwn.net/Articles/899182/
33. 33
Method 0: generic syscalls
ioctl()
prctl()
https://tinyurl.com/bdd5yeys
int prctl(int option, unsigned long arg2, unsigned long arg3,
unsigned long arg4, unsigned long arg5);
int ioctl(int fd, unsigned long request, ...);
34. 34
Method 1: Unused Function Parameters
●
Retain deprecated params: man shmctl
●
“Reserved for future use” params: man pid_getfd
●
Bitmasks with unused bits: man statx
●
Multiple versions of the same syscall: apropos clone
●
Some unwrapped syscalls have no glibc implementation.
35. 35
Method 2: avoid procfs and sysfs changes
“I'd just prefer to have
$NEW_FEATURE
under /proc or /sys.”
“This is ABI, you
can't walk back on
it.”
https://pixabay.com/en/speech-bubble-ellipse-shape-arrow-25917/
36. 36
Summary
●
The Linux ABI definition is both fuzzy and controversial.
●
Some ABI breaks are unavoidable.
●
Y2038 fix will be painful for distros.
●
glibc’s thread library NPTL is not suitable for robotics.
●
Trouble arises when users rely on developer tools.
●
Think carefully when writing userspace applications!
39. 39
Resources
●
Please support LWN!
●
“To Save C, We Must Save ABI,” and “
Binary Banshees and Digital Daemons,” JeanHeyd Meneide.
●
“It’s About Time,” Mike Crowe, Overload, 28(156):28-30, April
2020. (about pthreads and condition variables)
●
Gratian Crisan,
librtpi: Conditional Variables for Real-Time Applications,
Embedded Linux Conference 2020 presentation
●
“BPF CO-RE (Compile Once, Run Everywhere),” Andrii
Nakryiko’s blog
41. 41
Behavior of Clocks during Suspension
Should CLOCK_MONOTONIC advance when the system is
suspended?
42. 42
Changing the meaning of bootargs
●
See bootargs with sudo dmesg | grep -i “command line”
●
Should bootarg A means something different alone than in
conjunction with bootarg B?
$ git log -n 1 --grep=consistent – kernel/rcu/tree_nocb.h
●
Someone preferred the old behavior:
$ git log --oneline -n 1 --grep="option to opt" – kernel/rcu
44. 44
Trace Events are “stable API”
●
The list of tracepoints is (mostly) stable.
●
The format of trace events (the ABI!) changes.
The difference between a tracepoint and trace event is that a
tracepoint is the "trace_foo()" in the kernel, whereas the trace
event is the data extracted from the tracepoint via the
TRACE_EVENT() macro and listed in the format files in the
tracefs events directory.
45. 45
Why kernel tracepoints disappear:
optimizing compilers
#linux-rt IRC chat:
<rostedt> I already get people asking me why a function is
traced in one kernel, but not the other
<rostedt> and I have to tell them it was because gcc decided to
inline it in the other kernel
<rostedt> now we are going to lose tracing, because a function
was modified slightly where gcc can do a tail call?
<rostedt> and tail calls are quite common
46. 46
The libc⇔kernel ABI boundary
/usr/include
/usr/include/linux/
/usr/include/x86_64/asm
/usr/include/x86_64/bits
/usr/include/x86_64/sys
Linux kernel headers from
linux-libc-deb
glibc headers from
libc6-dev
47. 47
BPF Programs and
"Compile Once, Run Everywhere"
●
Problem: BPF programs rely on internal kernel ABI.
●
Solution: BPF Type Format, with debug info exported to
/sys/kernel/btf:
– $ bpftool btf dump file /sys/kernel/btf/battery format c
●
CO-RE further has LINUX_KERNEL_VERSION and
CONFIG_FOO_FEATURE macros to help with more complex
changes.
48. 48
Printk indexing will ease log-monitor maintenance
Solution: export kernel format strings to
/sys/kernel/debug for use by log monitors.
49. 49
Method 3: Export info to sysfs (BTF and
printk indexing)
How to access the ABI of the currently running
kernel:
$ ls /sys/kernel/btf
$ bpftool btf dump file /sys/kernel/btf/vfat
$ bpftool btf dump file /sys/kernel/btf/battery format c
Not part of stable ABI!
50. 50
Method 4: JIT Compilation
Works great, but expensive:
– requires kernel headers to be updated along with kernel;
– requires compilation with libclang or libgcc;
– slows startup of applications while JIT runs.
53. 53
C language lacks features that make ABI stability
easier
●
There are no function overloads or overrides.
– No “name mangling.”
– To safely change a function’s ABI, one must rename it.
●
“Encapsulation” methods are limited to static keyword.
– No notion of granular privacy.
– Implementation details tend to “leak” from C programs.
●
Maybe “assembly labels” like __attribute__((alias()) are a path
forward?
55. 55
Backward compatibility is hard
http://stackoverflow.com/questions/28986125/double-curved-shape
i386
strcpy() &
strdup()
32-bit time
56. 56
Why not just recompile?
●
Source code is unavailable.
●
Need to recompile propagates to other libraries/applications.
●
Proprietary toolchain is too old to support needed features.
●
Code would need new FDA, ISO262 … certification.
●
Suppose recompiling is not enough?
57. 57
ABI-Break Demo
$ git clone https://github.com/chaiken/SCALE2022-demo-code
$ cd SCALE2022-demo-code/C-ABI
$ make right-abi-lib
$ $ make wrong-abi-lib
Makefile main.c
is_negative_64.c
is_negative_128.c
59. 59
How should libc’s respond to kernel ABI Break?
Security, Performance, Stability, POSIX:
pick 23
(forgetting readability, logical consistency . . . )
(c)
Chris
Potter
(2012)
Title:
Scales
of
Justice
-
www.flickr.com/photos/86530412@N02/7953227784
60. 60
Debian and Out-of-Tree Kernel Modules
The kernel ABI
An ABI (Application Binary Interface) is an interface
between two software components, considered at the
level of register allocation and memory layout. The ABI
between the kernel and user-space is generally
maintained carefully, and is not a concern here. However,
the ABI between the kernel and its modules is not. In order
to support out-of-tree modules, the kernel version should
be changed when the ABI between the kernel and
modules changes.