checkpatch is broken.
Heh, I'm not objecting it :)
OTOH, it's also true that ENOTSUPP is no good error code if returned
to user-space. Unfortunately many codes (including what I wrote) use
this code mistakenly, and they can't be changed any longer...
It's also used internally in various places without being returned to
userspace, that's what's going on here - the regmap core has some
specific checks for -ENOTSUPP.
Sure, for such an internal usage any code can be used.
The question is a case like this -- where the return code might be
carried to outside. Though, looking through the grep output, all
callers simply return -EINVAL for any errors, so it doesn't matter
much for now.