mesa: add sanity check assertion in update_array_format