diff options
author | Zbigniew Kempczyński <zbigniew.kempczynski@intel.com> | 2020-05-20 13:26:35 +0200 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2020-05-20 18:59:26 +0100 |
commit | 8448c29b21de867212501a9e29901d275329e8b9 (patch) | |
tree | adf448f1059e4c3b6c77bfe81c87029c07e38789 /lib/intel_bufops.h | |
parent | 0f92bcfcc467fd05198a7e98b070d68204f87076 (diff) |
lib/intel_bufops: Add bufops reference and adapt stride requirement
Add bufops reference to intel_buf to allow acquire drm fd against which
buffer was created.
Change stride limitation for intel_buf for non-tiled buffers.
Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'lib/intel_bufops.h')
-rw-r--r-- | lib/intel_bufops.h | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/intel_bufops.h b/lib/intel_bufops.h index f3d6aed8..3a4fae4e 100644 --- a/lib/intel_bufops.h +++ b/lib/intel_bufops.h @@ -2,10 +2,12 @@ #define __INTEL_BUFOPS_H__ #include <stdint.h> +#include "igt_aux.h" struct buf_ops; struct intel_buf { + struct buf_ops *bops; uint32_t handle; uint32_t stride; uint32_t tiling; @@ -58,6 +60,7 @@ intel_buf_aux_height(int gen, const struct intel_buf *buf) struct buf_ops *buf_ops_create(int fd); void buf_ops_destroy(struct buf_ops *bops); +int buf_ops_getfd(struct buf_ops *bops); bool buf_ops_set_software_tiling(struct buf_ops *bops, uint32_t tiling, @@ -73,14 +76,14 @@ bool buf_ops_has_hw_fence(struct buf_ops *bops, uint32_t tiling); bool buf_ops_has_tiling_support(struct buf_ops *bops, uint32_t tiling); void intel_buf_init(struct buf_ops *bops, struct intel_buf *buf, - int width, int height, int bpp, + int width, int height, int bpp, int alignment, uint32_t tiling, uint32_t compression); void intel_buf_close(struct buf_ops *bops, struct intel_buf *buf); void intel_buf_init_using_handle(struct buf_ops *bops, uint32_t handle, struct intel_buf *buf, - int width, int height, int bpp, + int width, int height, int bpp, int alignment, uint32_t req_tiling, uint32_t compression); #endif |