aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/scripts/python/sctop.py
diff options
context:
space:
mode:
authorJeremy Linton <[email protected]>2020-05-04 20:13:48 +0000
committerGreg Kroah-Hartman <[email protected]>2020-05-05 11:06:46 +0000
commit2bef9aed6f0e22391c8d4570749b1acc9bc3981e (patch)
tree89f8f8a511a9cdb4b3d8e0e148106f7128032a23 /tools/perf/scripts/python/sctop.py
parentusb: typec: intel_pmc_mux: Fix the property names (diff)
downloadkernel-2bef9aed6f0e22391c8d4570749b1acc9bc3981e.tar.gz
kernel-2bef9aed6f0e22391c8d4570749b1acc9bc3981e.zip
usb: usbfs: correct kernel->user page attribute mismatch
On some architectures (e.g. arm64) requests for IO coherent memory may use non-cachable attributes if the relevant device isn't cache coherent. If these pages are then remapped into userspace as cacheable, they may not be coherent with the non-cacheable mappings. In particular this happens with libusb, when it attempts to create zero-copy buffers for use by rtl-sdr (https://github.com/osmocom/rtl-sdr/). On low end arm devices with non-coherent USB ports, the application will be unexpectedly killed, while continuing to work fine on arm machines with coherent USB controllers. This bug has been discovered/reported a few times over the last few years. In the case of rtl-sdr a compile time option to enable/disable zero copy was implemented to work around it. Rather than relaying on application specific workarounds, dma_mmap_coherent() can be used instead of remap_pfn_range(). The page cache/etc attributes will then be correctly set in userspace to match the kernel mapping. Signed-off-by: Jeremy Linton <[email protected]> Cc: stable <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/sctop.py')
0 files changed, 0 insertions, 0 deletions