Skip to content

Commit 4777128

Browse files
gregkhnamjaejeon
authored andcommitted
ksmbd: drivers: remove struct module * setting from struct class
There is no need to manually set the owner of a struct class, as the registering function does it automatically, so remove all of the explicit settings from various drivers that did so as it is unneeded. This allows us to remove this pointer entirely from this structure going forward. Cc: "Rafael J. Wysocki" <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]> Signed-off-by: Namjae Jeon <[email protected]>
1 parent 97a76e9 commit 4777128

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

server.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -531,7 +531,9 @@ ATTRIBUTE_GROUPS(ksmbd_control_class);
531531

532532
static struct class ksmbd_control_class = {
533533
.name = "ksmbd-control",
534+
#if LINUX_VERSION_CODE < KERNEL_VERSION(6, 4, 0)
534535
.owner = THIS_MODULE,
536+
#endif
535537
.class_groups = ksmbd_control_class_groups,
536538
};
537539

0 commit comments

Comments
 (0)