dma-mapping fixes for Linux 6.18:
- two small fixes for the recently performed code refactoring (Shigeru Yoshida) and missing handling of direction parameter in DMA debug code (Petr Tesarik) -----BEGIN PGP SIGNATURE----- iHUEABYIAB0WIQSrngzkoBtlA8uaaJ+Jp1EFxbsSRAUCaOTg+QAKCRCJp1EFxbsS RDFkAQCxV0khAeYDuiPdub+9d5XGVGTjBxG1ErYsvDbbsZ3QpAEAhheuAdbMBYU1 kOwmGuBUY32d0cMz0/4BfKbIzuQs9wE= =aE76 -----END PGP SIGNATURE----- Merge tag 'dma-mapping-6.18-2025-10-07' of git://git.kernel.org/pub/scm/linux/kernel/git/mszyprowski/linux Pull dma-mapping fixes from Marek Szyprowski: "Two small fixes for the recently performed code refactoring (Shigeru Yoshida) and missing handling of direction parameter in DMA debug code (Petr Tesarik)" * tag 'dma-mapping-6.18-2025-10-07' of git://git.kernel.org/pub/scm/linux/kernel/git/mszyprowski/linux: dma-mapping: fix direction in dma_alloc direction traces kmsan: fix kmsan_handle_dma() to avoid false positives
This commit is contained in:
commit
16d1ba7c96
|
@ -133,6 +133,7 @@ DECLARE_EVENT_CLASS(dma_alloc_class,
|
|||
__entry->dma_addr = dma_addr;
|
||||
__entry->size = size;
|
||||
__entry->flags = flags;
|
||||
__entry->dir = dir;
|
||||
__entry->attrs = attrs;
|
||||
),
|
||||
|
||||
|
|
|
@ -339,13 +339,12 @@ static void kmsan_handle_dma_page(const void *addr, size_t size,
|
|||
void kmsan_handle_dma(phys_addr_t phys, size_t size,
|
||||
enum dma_data_direction dir)
|
||||
{
|
||||
struct page *page = phys_to_page(phys);
|
||||
u64 page_offset, to_go;
|
||||
void *addr;
|
||||
|
||||
if (PhysHighMem(phys))
|
||||
return;
|
||||
addr = page_to_virt(page);
|
||||
addr = phys_to_virt(phys);
|
||||
/*
|
||||
* The kernel may occasionally give us adjacent DMA pages not belonging
|
||||
* to the same allocation. Process them separately to avoid triggering
|
||||
|
|
Loading…
Reference in New Issue