Re: [PATCH] iio: magnetometer: tlv493d: fix magnetic field scale
From: Joshua Crofts
Date: Thu Oct 15 2026 - 05:19:25 EST
On Wed, 14 Oct 2026 23:07:36 +0530
Viral Patel <viral8854@xxxxxxxxx> wrote:
> The TLV493D-A1B6 datasheet specifies a magnetic resolution of
> 98 uT/LSB (0.098 mT/LSB). IIO reports magnetic field in Gauss
> (1 mT = 10 G), so the scale should be 0.98 G/LSB.
>
> The driver currently reports 98/1000 = 0.098 G/LSB, which
> under-reports the magnetic field by a factor of 10. The comment
> also gives the resolution as 0.0098 mT (9.8 uT), mixing up units.
>
> Correct the scale value and the comment.
>
> Fixes: 106511d280c7 ("iio: magnetometer: add support for Infineon TLV493D 3D Magentic sensor")
> Signed-off-by: Viral Patel <viral8854@xxxxxxxxx>
> ---
Good find.
Reviewed-by: Joshua Crofts <joshua.crofts1@xxxxxxxxx>
--
Kind regards,
Joshua Crofts