[PATCH 5.18 03/11] x86/speculation: Add a common function for MD_CLEAR mitigation update