Reading that, one could think performance was the only factor.
But it isn't, and wasn't the one which really persuaded me.
And yes we do where that time went. Although it seems that
repeating that info once again won't help...
So it's wrong that <asm-generic/bitops/atomic.h> uses the
same calls to prevent *those* bitops from being prempted?
Thus, that code should switch over to normal spinlocks...
I believe that if I submitted patches to do that, there'd
be a not-so-small riot. And the arguments would all boil
down to much the same ones applying to *these* bitops...
You're certainly talking about "internal-implementation
details" in this case. It's not like the lock is used
outside of those routines. Or as if other implementations
would even *need* such a lock. (Just like the IRQ table,
if the entries can't be removed and are all set up very
early, locking would be pointless.)
Like the three instructions in the "hot paths" for getting
and setting GPIO values, when using raw spinlocks ... check.
- Dave
-