Linux Kernels

pwm: twl: Add .owner to struct pwm_ops

This change “pwm: twl: Add .owner to struct pwm_ops” (commit d5714e8) in Linux kernel is authored by Axel Lin <axel.lin [at]> on Sun Mar 31 11:17:05 2013 +0800.

Description of "pwm: twl: Add .owner to struct pwm_ops"

The change “pwm: twl: Add .owner to struct pwm_ops” introduces changes as follows.

pwm: twl: Add .owner to struct pwm_ops

Add missing .owner of struct pwm_ops. This prevents the module from being
removed from underneath its users.

Signed-off-by: Axel Lin <>
Acked-by: Peter Ujfalusi <>
Signed-off-by: Thierry Reding <>

Linux kernel releases containing commit d5714e8

The Linux kernel releases containing this commit are as follows.

Linux kernel code changes from "pwm: twl: Add .owner to struct pwm_ops"

There are 2 lines of Linux source code added/deleted in this change. Code changes to Linux kernel are as follows.

 drivers/pwm/pwm-twl.c | 2 ++
 1 file changed, 2 insertions(+)
diff --git a/drivers/pwm/pwm-twl.c b/drivers/pwm/pwm-twl.c
index bf3fda294223..ee7fa5ddba5d 100644
--- a/drivers/pwm/pwm-twl.c
+++ b/drivers/pwm/pwm-twl.c
@@ -287,12 +287,14 @@ static const struct pwm_ops twl4030_pwm_ops = {
 	.disable = twl4030_pwm_disable,
 	.request = twl4030_pwm_request,
 	.free = twl4030_pwm_free,
+	.owner = THIS_MODULE,
 static const struct pwm_ops twl6030_pwm_ops = {
 	.config = twl_pwm_config,
 	.enable = twl6030_pwm_enable,
 	.disable = twl6030_pwm_disable,
+	.owner = THIS_MODULE,
 static int twl_pwm_probe(struct platform_device *pdev)

The commit for this change in Linux stable tree is d5714e8 (patch).

Last modified: 2020/01/11 06:50