Commit 9075ceea authored by Michal Wilczynski's avatar Michal Wilczynski Committed by Uwe Kleine-König
Browse files

pwm: th1520: Use module_pwm_platform_driver! macro



The `pwm_th1520` Rust driver calls C functions from the `PWM` namespace,
triggering `modpost` warnings due to missing namespace import
declarations in its `.modinfo` section.

Fix these warnings and simplify the module declaration by switching from
the generic `kernel::module_platform_driver!` macro to the newly
introduced PWM-specific `kernel::module_pwm_platform_driver!` macro.
The new macro automatically handles the required `imports_ns: ["PWM"]`
declaration.

Signed-off-by: default avatarMichal Wilczynski <m.wilczynski@samsung.com>
Reviewed-by: default avatarTroy Mitchell <troy.mitchell@linux.dev>
Reviewed-by: default avatarElle Rhumsaa <elle@weathered-steel.dev>
Link: https://patch.msgid.link/20251028-pwm_fixes-v1-3-25a532d31998@samsung.com


Signed-off-by: default avatarUwe Kleine-König <ukleinek@kernel.org>
parent 26dcb420
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -378,7 +378,7 @@ fn probe(
    }
}

kernel::module_platform_driver! {
kernel::module_pwm_platform_driver! {
    type: Th1520PwmPlatformDriver,
    name: "pwm-th1520",
    authors: ["Michal Wilczynski <m.wilczynski@samsung.com>"],