Hello, On Thu, Sep 05, 2019 at 12:57:28PM +0300, Dan Carpenter wrote: > The problem is we set "led_cdev->trigger = NULL;" and then dereference > it when we call write_lock_irqsave(): > > write_lock_irqsave(&led_cdev->trigger->leddev_list_lock, flags); > ^^^^^^^^^^^^^^^^^ > > Fixes: 2282e125a406 ("leds: triggers: let struct led_trigger::activate() return an error code") > Signed-off-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx> Obviously right. Thanks for catching. Reviewed-by: Uwe Kleine-König <u.kleine-koenig@xxxxxxxxxxxxxx> Did you find this at runtime or by using some static checker? Best regards Uwe -- Pengutronix e.K. | Uwe Kleine-König | Industrial Linux Solutions | http://www.pengutronix.de/ |