X-Git-Url: https://git.karo-electronics.de/?a=blobdiff_plain;f=Documentation%2Fdma-buf-sharing.txt;h=505e71172ae7f17814cc87a5a18d489cd8cdf6a9;hb=2eaea13b4b586ea832d08cefb3f44f2824426fe2;hp=e31a2a9d2b075e9dda835218b63fd103cb91d6fa;hpb=fa91515cbf2375a64c8bd0a033a05b0859dff591;p=karo-tx-linux.git diff --git a/Documentation/dma-buf-sharing.txt b/Documentation/dma-buf-sharing.txt index e31a2a9d2b07..505e71172ae7 100644 --- a/Documentation/dma-buf-sharing.txt +++ b/Documentation/dma-buf-sharing.txt @@ -407,6 +407,18 @@ Being able to mmap an export dma-buf buffer object has 2 main use-cases: interesting ways depending upong the exporter (if userspace starts depending upon this implicit synchronization). +Other Interfaces Exposed to Userspace on the dma-buf FD +------------------------------------------------------ + +- Since kernel 3.12 the dma-buf FD supports the llseek system call, but only + with offset=0 and whence=SEEK_END|SEEK_SET. SEEK_SET is supported to allow + the usual size discover pattern size = SEEK_END(0); SEEK_SET(0). Every other + llseek operation will report -EINVAL. + + If llseek on dma-buf FDs isn't support the kernel will report -ESPIPE for all + cases. Userspace can use this to detect support for discovering the dma-buf + size using llseek. + Miscellaneous notes -------------------