Re: [PATCH v6 3/4] tracing: Use vmap_page_range() to map memmap ring buffer

From
Guenter Roeck <linux@roeck-us.net>
Date
2025-04-06 17:39:28
Also in
lkml
Reply to
Steven Rostedt, 2025-04-02
On Wed, Apr 02, 2025 at 10:49:06AM -0400, Steven Rostedt wrote:
From: Steven Rostedt <rostedt@goodmis.org>

The code to map the physical memory retrieved by memmap currently
allocates an array of pages to cover the physical memory and then calls
vmap() to map it to a virtual address. Instead of using this temporary
array of struct page descriptors, simply use vmap_page_range() that can
directly map the contiguous physical memory to a virtual address.

Link: https://lore.kernel.org/all/CAHk-=whUOfVucfJRt7E0AH+GV41ELmS4wJqxHDnui6Giddfkzw@mail.gmail.com/ (local)

Suggested-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
---
 kernel/trace/trace.c | 33 ++++++++++++++++-----------------
...
+	area = get_vm_area(size, VM_IOREMAP);
non-MMU builds (xtensa:nommu_kc705_defconfig):

kernel/trace/trace.o:(.init.literal+0x250): undefined reference to `get_vm_area'

Guenter
Thread (11 messages) 11 messages, 3 authors, last reply 2025-04-07
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help