diff options
Diffstat (limited to 'xf86drmMode.h')
-rw-r--r-- | xf86drmMode.h | 52 |
1 files changed, 28 insertions, 24 deletions
diff --git a/xf86drmMode.h b/xf86drmMode.h index 9d73be95..3cd27aee 100644 --- a/xf86drmMode.h +++ b/xf86drmMode.h | |||
@@ -369,15 +369,16 @@ extern int drmModeAddFB(int fd, uint32_t width, uint32_t height, uint8_t depth, | |||
369 | uint32_t *buf_id); | 369 | uint32_t *buf_id); |
370 | /* ...with a specific pixel format */ | 370 | /* ...with a specific pixel format */ |
371 | extern int drmModeAddFB2(int fd, uint32_t width, uint32_t height, | 371 | extern int drmModeAddFB2(int fd, uint32_t width, uint32_t height, |
372 | uint32_t pixel_format, uint32_t bo_handles[4], | 372 | uint32_t pixel_format, const uint32_t bo_handles[4], |
373 | uint32_t pitches[4], uint32_t offsets[4], | 373 | const uint32_t pitches[4], const uint32_t offsets[4], |
374 | uint32_t *buf_id, uint32_t flags); | 374 | uint32_t *buf_id, uint32_t flags); |
375 | 375 | ||
376 | /* ...with format modifiers */ | 376 | /* ...with format modifiers */ |
377 | int drmModeAddFB2WithModifiers(int fd, uint32_t width, uint32_t height, | 377 | int drmModeAddFB2WithModifiers(int fd, uint32_t width, uint32_t height, |
378 | uint32_t pixel_format, uint32_t bo_handles[4], | 378 | uint32_t pixel_format, const uint32_t bo_handles[4], |
379 | uint32_t pitches[4], uint32_t offsets[4], | 379 | const uint32_t pitches[4], const uint32_t offsets[4], |
380 | uint64_t modifier[4], uint32_t *buf_id, uint32_t flags); | 380 | const uint64_t modifier[4], uint32_t *buf_id, |
381 | uint32_t flags); | ||
381 | 382 | ||
382 | /** | 383 | /** |
383 | * Destroies the given framebuffer. | 384 | * Destroies the given framebuffer. |
@@ -498,25 +499,6 @@ extern int drmModeObjectSetProperty(int fd, uint32_t object_id, | |||
498 | uint64_t value); | 499 | uint64_t value); |
499 | 500 | ||
500 | 501 | ||
501 | typedef struct _drmModePropertySet drmModePropertySet, *drmModePropertySetPtr; | ||
502 | |||
503 | extern drmModePropertySetPtr drmModePropertySetAlloc(void); | ||
504 | |||
505 | extern int drmModePropertySetAdd(drmModePropertySetPtr set, | ||
506 | uint32_t object_id, | ||
507 | uint32_t property_id, | ||
508 | uint64_t value); | ||
509 | extern int drmModePropertySetAddBlob(drmModePropertySetPtr set, | ||
510 | uint32_t object_id, | ||
511 | uint32_t property_id, | ||
512 | uint64_t length, | ||
513 | void *blob); | ||
514 | |||
515 | extern int drmModePropertySetCommit(int fd, uint32_t flags, | ||
516 | void *user_data, drmModePropertySetPtr set); | ||
517 | |||
518 | extern void drmModePropertySetFree(drmModePropertySetPtr set); | ||
519 | |||
520 | typedef struct _drmModeAtomicReq drmModeAtomicReq, *drmModeAtomicReqPtr; | 502 | typedef struct _drmModeAtomicReq drmModeAtomicReq, *drmModeAtomicReqPtr; |
521 | 503 | ||
522 | extern drmModeAtomicReqPtr drmModeAtomicAlloc(void); | 504 | extern drmModeAtomicReqPtr drmModeAtomicAlloc(void); |
@@ -539,6 +521,28 @@ extern int drmModeCreatePropertyBlob(int fd, const void *data, size_t size, | |||
539 | uint32_t *id); | 521 | uint32_t *id); |
540 | extern int drmModeDestroyPropertyBlob(int fd, uint32_t id); | 522 | extern int drmModeDestroyPropertyBlob(int fd, uint32_t id); |
541 | 523 | ||
524 | /* | ||
525 | * DRM mode lease APIs. These create and manage new drm_masters with | ||
526 | * access to a subset of the available DRM resources | ||
527 | */ | ||
528 | |||
529 | extern int drmModeCreateLease(int fd, const uint32_t *objects, int num_objects, int flags, uint32_t *lessee_id); | ||
530 | |||
531 | typedef struct drmModeLesseeList { | ||
532 | uint32_t count; | ||
533 | uint32_t lessees[0]; | ||
534 | } drmModeLesseeListRes, *drmModeLesseeListPtr; | ||
535 | |||
536 | extern drmModeLesseeListPtr drmModeListLessees(int fd); | ||
537 | |||
538 | typedef struct drmModeObjectList { | ||
539 | uint32_t count; | ||
540 | uint32_t objects[0]; | ||
541 | } drmModeObjectListRes, *drmModeObjectListPtr; | ||
542 | |||
543 | extern drmModeObjectListPtr drmModeGetLease(int fd); | ||
544 | |||
545 | extern int drmModeRevokeLease(int fd, uint32_t lessee_id); | ||
542 | 546 | ||
543 | #if defined(__cplusplus) | 547 | #if defined(__cplusplus) |
544 | } | 548 | } |