On Tue, 4 Feb 2025, Choong Yong Liang wrote:
The logic could be reversed + return immediately to reduce the indentation
of the block below.
If you just want to have them initialized, it's enough to use {}, no dummy
0 is necessary.
This looks somewhat ugly. Perhaps it would be better if you make the call
on main level of the function and use local variables to hold the regs
array and its number of elements until then.
It would be even better if you could just store the pointer and # of
elements into some platform info structure so that it wouldn't need to be
calculated on the fly here (but I don't know this driver well enough to
know if that's viable/easy to do).
Why are these arrays in a header and not in the C file that uses them???