Re: [PATCH 1/2] iio: magnetometer: add support for Infineon TLV493D 3D Magentic sensor

Christophe JAILLET
2025-07-26T22:13:09Z

Le 26/07/2025 à 11:37, Dixit Parmar a écrit :
> The Infineon TLV493D is a Low-Power 3D Magnetic Sensor. The Sensor
> applications includes joysticks, control elements (white goods,
> multifunction knops), or electric meters (anti tampering) and any
> other application that requires accurate angular measurements at
> low power consumptions.

Hi,

> + ret = read_poll_timeout(regmap_bulk_read, err, err ||
> + FIELD_GET(TLV493D_VAL_CHANNEL, buff[TLV493D_RD_REG_TEMP]) == 0,
> + mode->sleep_us, (3 * mode->sleep_us), false, data->map, TLV493D_RD_REG_BX,
> + buff, ARRAY_SIZE(buff));
> + if (ret) {
> + dev_err(data->dev, "read poll timeout, error:%d", ret);

Nitpick: missing trailing \n

> + goto out;
> + }
> + if (err) {
> + dev_err(data->dev, "read data failed, error:%d\n", ret);
> + ret = err;
> + goto out;
> + }

...

> + ret = tlv493d_init(data);
> + if (ret)
> + return dev_err_probe(dev, ret, "failed to initialized\n");

Nitpick: to initialize (without a d)

> +
> + indio_dev->info = &tlv493d_info;
> + indio_dev->modes = INDIO_DIRECT_MODE;

...

CJ