On Fri, Mar 19, 2021 at 04:51:46PM +0000, Marc Zyngier wrote: > On 2021-03-19 16:42, Mark Brown wrote: > > Do compilers actually do much better with this than with a static > > inline like the other functions in this header? Seems like something > > they should be figuring out. > It's not about performance or anything of the sort: in most cases > where we end-up using this, it is on the back of an exception. > So performance is the least of our worries. > However, the "reg" parameter to read/write_sysreg_s() cannot > be a variable, because it is directly fed to the assembler. > If you want to use functions, you need to specialise them per > register. At this point, I'm pretty happy with a #define. Ah, that makes sense - it was more of a "that's weird" than "that's actually a problem", hence the Reviwed-by.