Re: [PATCH] can: dev: can_set_termination(): Allow gpio sleep

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

On 21.11.24 16:12, Marc Kleine-Budde wrote:
> Hello Nicolai,
> 
> thanks for your contribution!
> 
> On 21.11.2024 16:02:09, Nicolai Buchwitz wrote:
>> The current implementation of can_set_termination() sets the GPIO in a
>> context which cannot sleep. This is an issue if the GPIO controller can
>> sleep (e.g. since the concerning GPIO expander is connected via SPI or
>> I2C). Thus, if the termination resistor is set (eg. with ip link),
>> a warning splat will be issued in the kernel log.
>>
>> Fix this by setting the termination resistor with
>> gpiod_set_value_cansleep() which instead of gpiod_set_value() allows it to
>> sleep.
>>
>> Cc: stable@xxxxxxxxxxxxxxx
>> Signed-off-by: Nicolai Buchwitz <nb@xxxxxxxxxxx>
> 
> I've send the same patch a few hours ago:
> 
> https://lore.kernel.org/all/20241121-dev-fix-can_set_termination-v1-1-41fa6e29216d@xxxxxxxxxxxxxx/
> 
> Marc
> 

Shouldnt this also go to stable?

Regards,
Lino




[Index of Archives]     [Linux Kernel]     [Kernel Development Newbies]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux