Driver in kernel::platform
This is the reference page for the platform driver trait in the Linux kernel's Rust API. It shows what a driver must implement to be bound to a built-in device rather than a plug-in card: a probe fun…
Not every device announces itself the way a plug-in card does; many built-in devices are described by a text description of the board that the kernel reads at boot and matches by name. In this stage you keep the working parts of your driver exactly as they are and swap only the outer shell, so the same code is reached through the built-in device bus instead of the card bus. After it you know that what changes between buses is the matching and the way you get a memory mapping, and that the actual device logic is portable, which is why the same driver can serve a card and a chip soldered to a board.
This is the reference page for the platform driver trait in the Linux kernel's Rust API. It shows what a driver must implement to be bound to a built-in device rather than a plug-in card: a probe fun…