md: linear: Fix a division by zero bug for very small arrays.