[PATCH AUTOSEL 5.7 53/54] arm64: Move handling of erratum 1418040 into C code