node/blockstorage.cpp includes validation.h, and the lint lists node/blockstorage -> validation -> node/blockstorage as an expected circular dependency. This removes it, and the lint confirms the cycle is gone.
The largest user of validation in block storage is ImportBlocks, which drives validation. It moves to node/chainstate and sets the reindex flag through the new BlockManager::SetBlockfilesIndexed(), which writes the flag to the block tree database and sets the in-memory flag under one cs_main hold. The last commit moves FatalError to kernel/fatal_error.h, after which blockstorage.cpp no longer includes validation.h. validation.h still exports FatalError for its other users.
Validation also reaches into BlockManager's private members as a friend. RequestPrune() and MarkBlockIndexDirty() replace the friend declarations, keeping m_check_for_pruning and m_dirty_blockindex non-public. Both require cs_main, and the annotations let the compiler check it. After this, nothing outside BlockManager writes its private state or the block tree database.
There is no behavior change to my knowledge.
Based on #36738. Draft until it is merged.
Thanks to musaHaruna, who suggested RequestPrune() in his review on my fork. The flag marks a pending pruning check, so callers request it and storage decides whether anything qualifies, which keeps the flag private once the friend declarations are gone.