Re: [PATCH 2/2] iio: adc: qcom-pm8xxx-xoadc: add support for reading channel labels

From: Antony Kurniawan Soemardi

Date: Thu Mar 26 2026 - 08:29:05 EST


On 3/26/2026 5:18 PM, Andy Shevchenko wrote:
>> Tested-on: Sony Xperia SP (PM8921)
>
> Interesting, never saw this tag before.

Oh, I just realized I misremember Tested-by tag as Tested-on... Let me
know if it's not acceptable.

>> + if (!ch) {
>> + dev_err(adc->dev, "no such channel %lu\n", chan->address);
>> + return -EINVAL;
>> + }
>
> Isn't it a dead code? Also poisoning dmesg with this recurrent message is not
> good idea to begin with (the user space will have a door to flood it, which
> might be considered as an assistance to hackers to clear immediate logs after
> a successful attack).

Good point about the successful attack hint! I was copying the existing
code from pm8xxx_read_raw. Do you think those checks are unnecessary for
pm8xxx_read_raw as well?

Thanks,
Antony K. S.