Re: [PATCH v2 5/6] mfd: iqs62x: Do not poll during ATI

From: Lee Jones
Date: Wed Jan 20 2021 - 03:46:27 EST


On Sun, 17 Jan 2021, Jeff LaBundy wrote:

> After loading firmware, the driver triggers ATI (calibration) with
> the newly loaded register configuration in place. Next, the driver
> polls a register field to ensure ATI completed in a timely fashion
> and that the device is ready to sense.
>
> However, communicating with the device over I2C while ATI is under-
> way may induce noise in the device and cause ATI to fail. As such,
> the vendor recommends not to poll the device during ATI.
>
> To solve this problem, let the device naturally signal to the host
> that ATI is complete by way of an interrupt. A completion prevents
> the sub-devices from being registered until this happens.
>
> The former logic that scaled ATI timeout and filter settling delay
> is not carried forward with the new implementation, as it produces
> overly conservative delays at lower clock rates. Instead, a single
> pair of delays that covers all cases is used.
>
> Signed-off-by: Jeff LaBundy <jeff@xxxxxxxxxxx>
> ---
> Changes in v2:
> - Removed superfluous newlines throughout all iqs62x_dev_desc structs
>
> drivers/mfd/iqs62x.c | 125 +++++++++++++++++++++++++--------------------
> include/linux/mfd/iqs62x.h | 11 ++--
> 2 files changed, 73 insertions(+), 63 deletions(-)

Applied, thanks.

--
Lee Jones [李琼斯]
Senior Technical Lead - Developer Services
Linaro.org │ Open source software for Arm SoCs
Follow Linaro: Facebook | Twitter | Blog