Skip to contentSkip to conversation

vmalloc: export vrealloc_node_align_noprof

PATCH Applied Alice Ryhl 2 participants 2 messages Jan 7

Subsystems (3)
lore
Share & tools
lore

Alice Ryhl

author reviewer
#0 lore raw

PATCH 1/1 vmalloc: export vrealloc_node_align_noprof

This symbol is used from the Nova driver, so it needs to be exported to avoid a build failure when building Nova as a module.

ERROR: modpost: "vrealloc_node_align_noprof" [drivers/gpu/nova-core/nova_core.ko] undefined!
ERROR: modpost: "vrealloc_node_align_noprof" [samples/rust/rust_dma.ko] undefined!

This error is only triggered if helpers are inlined into Rust. Otherwise, Nova will call the exported symbol

rust_helper_vrealloc_node_align()

instead. There is no Fixes: tag as that feature is still WIP.

I used non-GPL EXPORT_SYMBOL to match the rest of the file, but let me know if I should use EXPORT_SYMBOL_GPL.

---
This patch was split out from this series:
[PATCH 0/4] Inline helpers into Rust without full LTO
https://lore.kernel.org/all/[email protected]/

---
 mm/vmalloc.c | 1 +
 1 file changed, 1 insertion(+)
mm/vmalloc.c +1 -0
index ecbac900c35f9cf207ac9299be096939509be43c..c248b5edb682e9a08acc1c3e804122f5fea22d19 100644
@@ -4355,6 +4355,7 @@ void *vrealloc_node_align_noprof(const void *p, size_t size, unsigned long align
 
 	return n;
 }
+EXPORT_SYMBOL(vrealloc_node_align_noprof);
 
 #if defined(CONFIG_64BIT) && defined(CONFIG_ZONE_DMA32)
 #define GFP_VMALLOC32 (GFP_DMA32 | GFP_KERNEL)

---
base-commit: 8f0b4cce4481fb22653697cced8d0d04027cb1e8
change-id: 20260107-export-vrealloc_node_align_noprof-1e7fb9b78e56

Best regards,

Signature · 1 line
Alice Ryhl <[email protected]>
reviewer Reviewed-by on v1 1/1
#1 lore raw
Quoted 9 lines · Alice Ryhl

This symbol is used from the Nova driver, so it needs to be exported to avoid a build failure when building Nova as a module.

ERROR: modpost: "vrealloc_node_align_noprof" [drivers/gpu/nova-core/nova_core.ko] undefined!
ERROR: modpost: "vrealloc_node_align_noprof" [samples/rust/rust_dma.ko] undefined!

This error is only triggered if helpers are inlined into Rust. Otherwise, Nova will call the exported symbol

Quoted 8 lines

rust_helper_vrealloc_node_align()

instead. There is no Fixes: tag as that feature is still WIP.

I used non-GPL EXPORT_SYMBOL to match the rest of the file, but let me know if I should use EXPORT_SYMBOL_GPL.