lkml.org 
[lkml]   [2022]   [Jun]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2] iio: Use octal permissions and DEVICE_ATTR_{RO,RW}.
On Wed, Jun 01, 2022 at 12:01:12PM +0200, Andy Shevchenko wrote:
> On Tue, May 31, 2022 at 9:40 PM Joe Simmons-Talbott
> <joetalbott@gmail.com> wrote:
> >
> > As reported by checkpatch.pl. Where possible use DEVICE_ATTR_RO and
>
> DEVICE_ATTR_RO()
>
> > DEVICE_ATTR_RW. Change function names to be <var>_show() for read and
>
> DEVICE_ATTR_RW()
>
> > <var>_store() for write.
>
> ...
>
> > static struct device_attribute dev_attr_length_ro = __ATTR(length,
> > + 0444, length_show, NULL);
>
> > static struct device_attribute dev_attr_watermark_ro = __ATTR(watermark,
> > + 0444, watermark_show, NULL);
>
> Why not __ATTR_RO() here?

Thank you for reviewing. An updated v3 patch has been sent.

Thanks,
Joe
>
> --
> With Best Regards,
> Andy Shevchenko

\
 
 \ /
  Last update: 2022-06-01 22:53    [W:0.045 / U:0.060 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site