Linux Platform Bus Driver Device Model

Linux Platform Bus Driver Device Model

Embedded Linux QQ Group: 175159209, enthusiasts are welcome to join and discuss technical issues! The platform bus is a virtual bus, and the corresponding device is a platform_device, while the driver is a platform_driver. In the device driver model of Linux 2.6, I2C, RTC, LCD, etc. are classified as platform_device. The bus binds devices and … Read more

Linux Character Device Driver Example

Linux Character Device Driver Example

globalmem Looking at Linux device driver development details, the chapter on character device drivers provides test code and application programs that are very helpful for beginners. The reason for writing this article is that I noticed I had not yet written about character devices, despite having previously published articles. As for the role of the … Read more

Rust: The Future of Systems Programming, C as New Assembly

Rust: The Future of Systems Programming, C as New Assembly

Author: Bhagyashree R Translator: Ping Chuan Editor: Wang Wenjing At the 2019 Open Source Technology Summit (OSTS), Intel’s Chief Engineer Josh Triplett detailed the work Intel is doing to make Rust, a language loved by many, fully comparable to C. In his talk “Intel and Rust: The Future of Systems Programming,” he also discussed the … Read more

Speed Comparison Between Rust and C

Speed Comparison Between Rust and C

Author | Kornel Translator | Sambodhi Editor | Zhao Yuying This article was originally published on the author’s personal blog and is shared here with the authorization of the original author Kornel, translated by InfoQ Chinese site. Programs written in Rust should have run-time speed and memory usage comparable to those written in C. However, … Read more

Is It Possible to Rewrite the Linux Kernel in Rust?

Is It Possible to Rewrite the Linux Kernel in Rust?

It is well known that Linux is the representative of the C language. However, times have changed, and Rust is on the rise, gaining more and more support, gradually taking on the role of the system language for Linux. At the 2020 Linux Plumbers Conference, developers seriously considered the idea of using Rust for inline … Read more

Don’t Rush to Rewrite in Rust: It May Not Be That Safe

Don't Rush to Rewrite in Rust: It May Not Be That Safe

Author | Anonymous Authors Translator | Nuclear Cola Editor | Chu Xingjuan If you haven’t tried Rust yet, I recommend you hurry up and give it a shot! Haven’t used Rust’s cat, grep, and find? I’m not joking, “once you try it, you will fall in love” is what Rust is all about. Too busy … Read more

Introduction and Usage of Linux LCD Framebuffer

Introduction and Usage of Linux LCD Framebuffer

Today, let’s talk about the LCD Framebuffer in Linux, which is a powerful tool in embedded systems. Despite its fancy name, it’s actually very simple to use; it’s just a large array in memory that stores the color information of each pixel on the screen. What is a Framebuffer? In simple terms, a Framebuffer is … Read more

Linux C Programming: Process Control

Linux C Programming: Process Control

(1) Process Concept A process is a program that has been executed. It does not occupy disk space but consumes system memory, CPU resources, and each running process corresponds to its own virtual address space. (2) Concepts of Parallelism and Concurrency The CPU allocates a time slice to each process, and a process can run … Read more

Zephyr Kernel Data Structures – Singly Linked List

Zephyr Kernel Data Structures - Singly Linked List

Singly Linked List The Zephyr singly linked list is implemented in the following file: zephyr/include/zephyr/sys/slist.h. Zephyr stores singly linked list data in sys_slist_t (i.e., each list element stores a pointer to the next element, rather than the data of the previous element). /** @cond INTERNAL_HIDDEN */ struct _slist { sys_snode_t *head; sys_snode_t *tail; }; /** … Read more

Zephyr Kernel Data Structure – MPSC

Zephyr Kernel Data Structure - MPSC

Overview MPSC_PBUF (Multi Producer Single Consumer Packet Buffer) is a circular buffer where data in MPSC_PBUF is managed in packets, and the size of the packets is variable. Users read or store data from MPSC_PBUF in packet units. To reduce data copying in memory, data production is divided into two steps: allocating packet space and … Read more