Page MenuHomeFreeBSD

config_intrhook: Move from TAILQ to STAILQ and padding

Authored by imp on Mar 2 2021, 12:00 AM.



config_intrhook doesn't need to be a two-pointer TAILQ. We rarely add/delete
from this and so those need not be optimized. Instaed, use the one-pointer
STAILQ plus a uintptr_t to be used as a flags word. This will allow these
changes to be MFC'd to 12 and 13 to fix a race in removable devices.

Diff Detail

rG FreeBSD src repository
Automatic diff as part of commit; lint not applicable.
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

imp requested review of this revision.Mar 2 2021, 12:00 AM
imp created this revision.
mav added a subscriber: mav.

Should probably be merged with D29005.

This revision is now accepted and ready to land.Mar 4 2021, 2:37 PM

Maybe 'and add flags' instead of 'and padding' for the commit subject.

s/Instaed/Instead/ in the log as well.


Since you don't use these flags yet, I would not add these constants until D29005 and just add the ich_flags member in this commit.


Maybe call it ich_pad in this commit since you end up renaming it in D29005 anyway. I guess then you might say "and keep padding" or some such instead in your commit log instead of "and add flags" and similarly adjust the log to say you are leaving the second pointer as a padding placeholder for a subsequent commit.


I'll just call it ich_state, just like in D29005 and tweak the commit message.

In D29004#650789, @mav wrote:

Should probably be merged with D29005.

I'd prefer keeping them separate. I'd like people to have a bisection point that's just the STAILQ in case there's a bug with it...

move to generic ich_padding

This revision now requires review to proceed.Mar 8 2021, 5:17 PM
This revision is now accepted and ready to land.Mar 8 2021, 6:07 PM