Reorganizing error code and adding sub-block combining