]> www.infradead.org Git - users/dwmw2/linux.git/commit
dma-mapping: use trace_dma_alloc for dma_alloc* instead of using trace_dma_map
authorSean Anderson <sean.anderson@linux.dev>
Fri, 18 Oct 2024 15:00:36 +0000 (11:00 -0400)
committerChristoph Hellwig <hch@lst.de>
Tue, 29 Oct 2024 07:54:03 +0000 (08:54 +0100)
commitc4484ab86ee00f2d9236e2851621ea02c105f4cc
treee07e81072bdba4a275f3caa6459e7975fd3cc0b2
parent3afff779a725cba914e6caba360b696ae6f90249
dma-mapping: use trace_dma_alloc for dma_alloc* instead of using trace_dma_map

In some cases, we use trace_dma_map to trace dma_alloc* functions. This
generally follows dma_debug. However, this does not record all of the
relevant information for allocations, such as GFP flags. Create new
dma_alloc tracepoints for these functions. Note that while
dma_alloc_noncontiguous may allocate discontiguous pages (from the CPU's
point of view), the device will only see one contiguous mapping.
Therefore, we just need to trace dma_addr and size.

Signed-off-by: Sean Anderson <sean.anderson@linux.dev>
Reviewed-by: Steven Rostedt (Google) <rostedt@goodmis.org>
Signed-off-by: Christoph Hellwig <hch@lst.de>
include/trace/events/dma.h
kernel/dma/mapping.c