Re: [PATCH v5] iio: proximity: srf08: Replace sprintf() with sysfs_emit()

From: Andy Shevchenko

Date: Wed Apr 22 2026 - 08:59:55 EST


On Wed, Apr 22, 2026 at 07:45:05AM -0500, Maxwell Doose wrote:
> Replace sprintf() function calls with sysfs_emit() and
> sysfs_emit_at(). While the current code is fine, sysfs_emit() is
> preferred over sprintf(), and will help modernize the driver.

Reviewed-by: Andy Shevchenko <andriy.shevchenko@xxxxxxxxx>

...

> v5:
> - Reversed decision to put sysfs_emit() call on one line per Jonathan
> Cameron's request.

Oh, I missed that. In any case I consider my suggestion is still better,
it keeps driver in limits and makes the wrap on logical boundary.

> - Fixed some of my editor's tab-spacing issues

--
With Best Regards,
Andy Shevchenko