First a note: I gave up on my previous rushed attempt to review this because the patch was just too big for my limited mental capacity. Today I instead split out the relatively trivial prep parts to focus on the changes. I've pushed my split to: git://git.infradead.org/users/hch/xfsprogs.git shutdown-deadlock-split it would be great to pick that up or do something similar for the next round. After your patch I've also added two cosmetic patches. With that the change does look good to me, and the bli reference count scheme looks almost sane to me. Although it makes me wonder if we should just keep a BLI reference for any BLI in the AIL to further simplify it eventually?