Closed stefano-garzarella closed 4 years ago
Thank you for your precious pull request.
This is just a side note, but udmabuf changed to u-dma-buf. If possible, I would like u-dma-buf to be used instead of udmabuf since Linux Kernel 5.0. u-dma-buf has the same changes as your pull request. Anyway, pull request Thank you.
@ikwzm thanks! I didn't see it, please move the note at the begging of Readme.md in the master branch.
Build failed with this error: udmabuf.c:527:16: error: initialization of ‘vm_fault_t ()(struct vm_fault )’ {aka ‘unsigned int ()(struct vm_fault )’} from incompatible pointer type ‘int ()(struct vm_fault )’ [-Werror=incompatible-pointer-types] 527 | .fault = udmabuf_device_vma_fault, | ^
~~~~~~~Starting from Linux 5.1 'vm_fault_t' switches from int to unsigned int.
vm_fault_t was defined from Linux 4.17, so this commit adds its definition for Linux < 4.17, and it uses vm_fault_t return value for .fault callback.