[Patch v6] i2c: pnx: Fix potential deadlock warning from del_timer_sync() call in isr
Piotr Wojtaszczyk
piotr.wojtaszczyk at timesys.com
Tue Jul 2 02:13:06 PDT 2024
On Tue, Jul 2, 2024 at 1:01 AM Andi Shyti <andi.shyti at kernel.org> wrote:
> > @@ -653,7 +624,10 @@ static int i2c_pnx_probe(struct platform_device *pdev)
> > alg_data->adapter.algo_data = alg_data;
> > alg_data->adapter.nr = pdev->id;
> >
> > - alg_data->timeout = I2C_PNX_TIMEOUT_DEFAULT;
> > + alg_data->timeout = msecs_to_jiffies(I2C_PNX_TIMEOUT_DEFAULT);
> > + if (alg_data->timeout <= 1)
> > + alg_data->timeout = 2;
>
> I don't see the need for this check. The default timeout is
> defined as 10.
>
> Thanks,
> Andi
That's the timeout value which was in the previous timer in i2c_pnx_arm_timer(),
without this I had time out events.
--
Piotr Wojtaszczyk
Timesys
More information about the linux-arm-kernel
mailing list