pwm: bcm-iproc: Prevent unloading the driver module while in use
authorUwe Kleine-König <u.kleine-koenig@pengutronix.de>
Thu, 17 Oct 2019 19:22:18 +0000 (21:22 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 5 Dec 2019 14:34:12 +0000 (15:34 +0100)
commit339b3e9bb6d746fd1dc92251ccd238dbff3478ea
treef16ec43c403b035cf87464943c950fc21500cdc8
parente00630fa63bb9b42432af56127666e921e3da9ea
pwm: bcm-iproc: Prevent unloading the driver module while in use

[ Upstream commit 24906a41eecb73d51974ade0847c21e429beec60 ]

The owner member of struct pwm_ops must be set to THIS_MODULE to
increase the reference count of the module such that the module cannot
be removed while its code is in use.

Fixes: daa5abc41c80 ("pwm: Add support for Broadcom iProc PWM controller")
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: Thierry Reding <thierry.reding@gmail.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/pwm/pwm-bcm-iproc.c