[BUG] net: rocker: accessing the data mapped to streaming DMA

From: Jia-Ju Bai <hidden>
Date: 2020-08-02 14:26:55
Also in: lkml

In rocker_dma_test_offset(), "buf" is mapped to streaming DMA on line 203:
   dma_handle = pci_map_single(..., buf, ...);

Then, "buf" is accessed on line 229:
   expect[i] = ~buf[i];

This access may cause data inconsistency between CPU cache and hardware.

I am not sure how to properly fix this problem, and thus I only report it.


Best wishes,
Jia-Ju Bai
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help