Re: linux-next: build warnings after merge of the pwm tree
From: Michal Wilczynski
Date: Tue Oct 28 2025 - 05:52:28 EST
On 10/28/25 03:39, Stephen Rothwell wrote:
> Hi all,
>
> After merging the pwm tree, today's linux-next build (x86_64 allmodconfig)
> produced these warnings:
>
> WARNING: modpost: module pwm_th1520 uses symbol pwmchip_release from namespace PWM, but does not import it.
> WARNING: modpost: module pwm_th1520 uses symbol __pwmchip_add from namespace PWM, but does not import it.
> WARNING: modpost: module pwm_th1520 uses symbol pwmchip_alloc from namespace PWM, but does not import it.
> WARNING: modpost: module pwm_th1520 uses symbol pwmchip_remove from namespace PWM, but does not import it.
Hi, Thank you for the report. Interestingly this seems to be the first
Rust driver that needs to write 'import_ns' in the .modpost section. For
C drivers the macro MODULE_IMPORT_NS("PWM") was simply included with
pwm.h. I think the module! macro needs to be extended to support
import_ns in rust/macros/module.rs. I think I know how to do it code
wise, will post a patch.
>
> Presumably introduced by commit
>
> fb3957af9ec6 ("pwm: Add Rust driver for T-HEAD TH1520 SoC")
>
Best regards,
--
Michal Wilczynski <m.wilczynski@xxxxxxxxxxx>