Restore MDS code