Electronics, Firmware, hardware, Linux kernel, Networking, Reverse engineering

Analysis and reverse-engineering of the original Starlink router

While waiting for my Dishy, I decided to find and buy the Starlink router separately. Sure, it might be just a WiFi router, but it was very curious what’s inside. Spoiler: there are some interesting implementation details. Lucky enough, I found the router on eBay. It’s the first generation of the router. Currently, it’s impossible to buy (separately) the second…

Continue Reading

Linux kernel, Software

Linux block device driver

My article about character devices is quite popular, so I decided to write something about another big class of devices in Linux – block devices. This type of device is used to access various storage hardware types – hard disks, SSD, etc. Here I want to describe blk-mq based devices in modern (>= 5.0) Linux kernels and a previous type…

Continue Reading

Linux kernel, Linux system development, Software

C++ in Linux kernel

Linux kernel is written in C (and in Assembly in platform-specific portions) language. C language is the only allowed language to write kernel modules. And there is no problem, in most of the cases. But sometimes some stranger things may be required. Let’s see how to use C++ for the Linux kernel modules.

Linux kernel, Linux system development, Networking

Monitoring Linux networking state using netlink

Once in my work, I needed to monitor all changes in the Linux networking subsystem: adding or deleting IP addresses, routes, etc. Maybe the best way to do this is to use socket-based Netlink technology. Using Netlink, we can “subscribe” to some network-related notifications from the kernel. It’s also possible to send commands to the network stack and change the…

Continue Reading