Re: [PATCH] iio: humidity: htu21: Fix SYMBOLIC_PERMS chekcpatch warning
Andy Shevchenko <[email protected]>
| Newsgroups | dev.linux.lists.linux-kernel-mentees,org.kernel.vger.linux-iio,org.kernel.vger.linux-kernel |
|---|---|
| Organization | Intel Finland Oy - BIC 0357606-4 - c/o Alberga Business Park, 6 krs, Bertel Jungin Aukio 5, 02600 Espoo |
| Message-ID | <[email protected]> |
On Sun, Aug 02, 2026 at 09:23:26AM +0800, Adi Nata wrote: > Checkpatch warning: > > WARNING:SYMBOLIC_PERMS: Symbolic permissions 'S_IRUGO' are not preferred. Consider using octal permissions '0444'. > +static IIO_DEVICE_ATTR(battery_low, S_IRUGO, > > WARNING:SYMBOLIC_PERMS: Symbolic permissions 'S_IRUGO | S_IWUSR' are not preferred. Consider using octal permissions '0644'. > +static IIO_DEVICE_ATTR(heater_enable, S_IRUGO | S_IWUSR, > static IIO_CONST_ATTR_SAMP_FREQ_AVAIL(htu21_show_samp_freq); > -static IIO_DEVICE_ATTR(battery_low, S_IRUGO, > +static IIO_DEVICE_ATTR(battery_low, 0444, > htu21_show_battery_low, NULL, 0); > -static IIO_DEVICE_ATTR(heater_enable, S_IRUGO | S_IWUSR, > +static IIO_DEVICE_ATTR(heater_enable, 0644, > htu21_show_heater, htu21_write_heater, 0); What's wrong with IIO_DEVICE_ATTR_RW()? Same comment to all patches of a kind from you. -- With Best Regards, Andy Shevchenko