Re: [PATCH v3 1/3] iio: adc: Add Allwinner D1/T113s/R329/T507 SoCs GPADC

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi, Andre

>> +	}
>> +
>> +	if (num_channels > SUN20I_GPADC_MAX_CHANNELS) {
>> +		dev_err(dev, "num of channel children out of range");
>> +		return -EINVAL;
>
>Jonathan, but num_channels comes from the device tree. Why do we need to
>validate the upper limit and not simply use as much as we can?
>
>That's why I think this is not a critical error.

Looks like I missed this. So, if we rely on dtbs_check then I agree that
this check is not needed.




[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Input]     [Linux Kernel]     [Linux SCSI]     [X.org]

  Powered by Linux