Re: [PATCH] rust: put C helper exports in a dedicated namespace
From: Miguel Ojeda
Date: Fri Nov 20 2026 - 16:34:48 EST
On Fri, Nov 20, 2026 at 5:32 PM Peder Bergan via B4 Relay
<devnull+peder.bergan.gmail.com@xxxxxxxxxx> wrote:
>
> Suggested-by: Wedson Almeida Filho <wedsonaf@xxxxxxxxx>
> Link: https://github.com/Rust-for-Linux/linux/issues/216
Nice, thanks for going through these old issues! :)
> +rust_export_macro = EXPORT_SYMBOL_RUST_GPL
Do we need a recursively expanded variable?
> +++ b/rust/exports.c
Conflicts ahead; this file happens to be going away with:
https://lore.kernel.org/rust-for-linux/20261112121512.1670347-3-gprocida@xxxxxxxxxx/
Cc'ing Giuliano.
Also, what Sashiko says seems reasonable: if we do it this way, then
we may need manual `MODULE_IMPORT_NS()`s in some places, which may
become a bit annoying, even if there aren't that many mixed language
modules so far.
Actually, perhaps we could just import it in modpost if a Rust module
has any Rust translation unit in it...
Cheers,
Miguel