]> git.ipfire.org Git - thirdparty/linux.git/commit
iio: common: scmi_sensors: Get rid of const_ilog2()
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Mon, 3 Nov 2025 08:29:11 +0000 (09:29 +0100)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Sun, 9 Nov 2025 14:58:56 +0000 (14:58 +0000)
commit69f5dcaa990e3f43c89fc5cec4ae92ececdb12f3
tree9d1dd8a844b3cecbe311bbf6314bae1a9938441d
parent02f86101e430cce9a99a044b483c4ed5b91bb3b8
iio: common: scmi_sensors: Get rid of const_ilog2()

Fisrt of all, const_ilog2() was a workaround of some sparse issue,
which was never appeared in the C functions. Second, the calls here
are done against constants and work with a bit of luck. Replace
this altogether by a pre-calculated simple integer constant.
Amend a comment to give a hint where it comes from.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/common/scmi_sensors/scmi_iio.c