xf86drm: add drmSyncobjEventfd

This is a wrapper for DRM_IOCTL_SYNCOBJ_EVENTFD.

Signed-off-by: Simon Ser <contact@emersion.fr>
main
Simon Ser 2023-07-20 12:45:57 +02:00
parent 431becd4e0
commit c6013245ce
3 changed files with 17 additions and 0 deletions

View File

@ -187,6 +187,7 @@ drmSLNext
drmSwitchToContext drmSwitchToContext
drmSyncobjCreate drmSyncobjCreate
drmSyncobjDestroy drmSyncobjDestroy
drmSyncobjEventfd
drmSyncobjExportSyncFile drmSyncobjExportSyncFile
drmSyncobjFDToHandle drmSyncobjFDToHandle
drmSyncobjHandleToFD drmSyncobjHandleToFD

View File

@ -5102,6 +5102,20 @@ drm_public int drmSyncobjTransfer(int fd,
return ret; return ret;
} }
drm_public int drmSyncobjEventfd(int fd, uint32_t handle, uint64_t point, int ev_fd,
uint32_t flags)
{
struct drm_syncobj_eventfd args;
memclear(args);
args.handle = handle;
args.point = point;
args.fd = ev_fd;
args.flags = flags;
return drmIoctl(fd, DRM_IOCTL_SYNCOBJ_EVENTFD, &args);
}
static char * static char *
drmGetFormatModifierFromSimpleTokens(uint64_t modifier) drmGetFormatModifierFromSimpleTokens(uint64_t modifier)
{ {

View File

@ -947,6 +947,8 @@ extern int drmSyncobjTransfer(int fd,
uint32_t dst_handle, uint64_t dst_point, uint32_t dst_handle, uint64_t dst_point,
uint32_t src_handle, uint64_t src_point, uint32_t src_handle, uint64_t src_point,
uint32_t flags); uint32_t flags);
extern int drmSyncobjEventfd(int fd, uint32_t handle, uint64_t point, int ev_fd,
uint32_t flags);
extern char * extern char *
drmGetFormatModifierVendor(uint64_t modifier); drmGetFormatModifierVendor(uint64_t modifier);