I am working with an embedded device which communicates with my
PowerPC CPU made by NXP (T1022) via PCIe. Due to the QorIQ SDK V2.0 constraints i have to use linux kernel version
4.1.8. This version doesn't have functions related to
cache operations in
$KERNEL_SOURCE/arch/powerpc/include/asm/, such as:
(in this directory
"cacheflush.h" header just contains declaration of mentioned functions.)
Also, my embedded device's SDK needs to call these functions to prepare
Note that Kernel versions higher than
4.5 provide declaration of these functions.
Now i have some questions:
- I can use and copy functions which are implemented in newer kernels, in my old kernel and rebuild it, but modifying the kernel source doesn't make sense, right?
- Can you suggest some workaround or alternate method to resolve it?
- How can i test that cache invalidated or flushed correctly? is there any way to read cache blocks in userspace?