Backport commit r4598 - savestate firmware less totally wrongly