]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
iio: magnetometer: ak8975: Fix 'Unexpected device' error
authorAndré Apitzsch <git@apitzsch.eu>
Sun, 1 Oct 2023 16:09:56 +0000 (18:09 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 4 Oct 2024 14:30:04 +0000 (16:30 +0200)
commit72a3aef9640e5e7e4645e76435835ae3d8df0784
tree9c32954763d08356907e3910065b7b4142fac769
parent18b5ee7bf70048d85cc1b424e862cb762421b2c5
iio: magnetometer: ak8975: Fix 'Unexpected device' error

commit 848f68c760ab1e14a9046ea6e45e3304ab9fa50b upstream.

Explicity specify array indices to fix mapping between
asahi_compass_chipset and ak_def_array.
While at it, remove unneeded AKXXXX.

Fixes: 4f9ea93afde1 ("iio: magnetometer: ak8975: Convert enum->pointer for data in the match tables")
Signed-off-by: André Apitzsch <git@apitzsch.eu>
Reviewed-by: Biju Das <biju.das.jz@bp.renesas.com>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20231001-ak_magnetometer-v1-1-09bf3b8798a3@apitzsch.eu
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/iio/magnetometer/ak8975.c