[PATCH 3/4] pwm: th1520: Use module_pwm_platform_driver! macro

Troy Mitchell troy.mitchell at linux.dev
Tue Oct 28 17:59:49 PDT 2025


On Tue, Oct 28, 2025 at 01:22:34PM +0100, Michal Wilczynski wrote:
> 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: Michal Wilczynski <m.wilczynski at samsung.com>
Reviewed-by: Troy Mitchell <troy.mitchell at linux.dev>



More information about the linux-riscv mailing list