driver list: collect driver desc pointers in linker section (array)
commit2510990b5a0130a49c836bbbdcd382abd6db2aef
authorGerhard Sittig <gerhard.sittig@gmx.net>
Tue, 9 May 2023 19:24:35 +0000 (9 21:24 +0200)
committerGerhard Sittig <gerhard.sittig@gmx.net>
Tue, 9 May 2023 20:27:08 +0000 (9 22:27 +0200)
tree81fdd34792bd846056ef56718a2b9c6183df946b
parent42de14a376ec26d4dae8800b07161b807f8877a3
driver list: collect driver desc pointers in linker section (array)

Extend the drivers.h header file such that a linker section collects a
list of pointers to driver descriptions. The change is transparent to
registering drivers, their API use does not change. The linker section
is created in addition to the constructor logic which creates a list at
runtime.

This implementation works in the author's local setup. Portability may
need more adjustment (symbols visibility).
src/drivers.h