Move masking out bits into cfgreg_read.