function bridge_mmap (cdev_ctrl.c, line 195) has 4 variables that need to hold 64 bit values. Unfortunately "unsigned long" seems to provide a 32 bit register in the ARM C compiler. The following fix will make it work reliably in ARM, and I assume in other operating systems too:
cdev_ctrl.c, line 195:
int bridge_mmap(struct file file, struct vm_area_struct vma)
{
struct xdma_dev xdev;
struct xdma_cdev xcdev = (struct xdma_cdev *)file->private_data;
uint64_t off;// LVB 21/2/2021: must be 64 bit
uint64_t phys;// LVB 21/2/2021: must be 64 bit
uint64_t vsize;// LVB 21/2/2021: must be 64 bit
uint64_t psize;// LVB 21/2/2021: must be 64 bit
…..
function bridge_mmap (cdev_ctrl.c, line 195) has 4 variables that need to hold 64 bit values. Unfortunately "unsigned long" seems to provide a 32 bit register in the ARM C compiler. The following fix will make it work reliably in ARM, and I assume in other operating systems too:
cdev_ctrl.c, line 195: int bridge_mmap(struct file file, struct vm_area_struct vma) { struct xdma_dev xdev; struct xdma_cdev xcdev = (struct xdma_cdev *)file->private_data; uint64_t off;// LVB 21/2/2021: must be 64 bit uint64_t phys;// LVB 21/2/2021: must be 64 bit uint64_t vsize;// LVB 21/2/2021: must be 64 bit uint64_t psize;// LVB 21/2/2021: must be 64 bit …..
see support forum: https://support.xilinx.com/s/question/0D52E00006hpPyySAE/xdma-device-driver-ar65444-fix-for-arm?language=en_US