iio: Add callback to check whether a scan mask is valid