On 1/17/21 3:49 AM, Andy Shevchenko wrote: > On Wed, Jan 13, 2021 at 8:23 PM Barnabás Pőcze <pobrn@xxxxxxxxxxxxxx> wrote: >> >> Consumers can differentiate an error from a successful read much more >> easily if the read() call fails with the appropriate errno instead of >> returning a magic string like "-1". > > Is user space ready for this (for the record, it seems an ABI breakage)? > read() and getting errno looks sysfs/driver broken to me. I think if button/method is not available, it's better to be something like sysfs_emit(buf, "%d\n", -ENODEV) -- Ike Panhc