Device mmio set of registers

Stefan Thöni stefan.thoeni at
Thu Sep 2 15:28:55 CEST 2021

Hello Genodians

What's the best way to handle multiple sets of identical registers on a
hardware device?

In my current use case the device offers multiple DMA engines each of
which has a complex set of registers to set up. Each register is located
at base device address + base engine address + register offset so
uniform handling should be easy.

I handle the device itself and the shared registers using

For the registers associated with each DMA engine I have tried:

a) A template class providing a base offset as the template parameter.
This is unsatisfactory however, as there is no common base class
providing access to the registers for the software to be agnostic to
which engine it handles.

b) A separate class derived from Genode::Mmio. This looks promising, but
the Platform::Device::Mmio unfortunatly offers no public accessor to the
device base address so I cannot provide the base device address + base
engine address to my engine mmio class.

Any suggestions?

Kind regards

Freundliche Grüsse

Stefan Thöni
Chairman of the Board
Senior Security Architect
+41 79 610 64 95

gapfruit AG
Baarerstrasse 135
6300 Zug
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_0x99A5F4B3D4E372A6.asc
Type: application/pgp-keys
Size: 1867 bytes
Desc: OpenPGP public key
URL: <>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature
Type: application/pgp-signature
Size: 313 bytes
Desc: OpenPGP digital signature
URL: <>

More information about the users mailing list