Igt-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [igt-dev] [PATCH 0/8] Add GetFB2 ioctl
@ 2018-03-23 13:42 Daniel Stone
  2018-03-23 13:46 ` [igt-dev] [PATCH i-g-t 1/3] tests/kms_getfb: Split property-ID get into helper Daniel Stone
  2018-03-23 13:51 ` [igt-dev] [PATCH 0/8] Add GetFB2 ioctl Daniel Stone
  0 siblings, 2 replies; 9+ messages in thread
From: Daniel Stone @ 2018-03-23 13:42 UTC (permalink / raw)
  To: dri-devel, igt-dev

Hi,
AddFB is single-planar, with no offset and only depth/bpp rather than
an explicit format, so we now have AddFB2 which can carry multiple
planes, an explicit format and also a modifier. At the time we never
actually did GetFB2 to go with GetFB.

This submission rights that historical wrong, which allows Xorg
-background none to continue to work in the face of exotic buffers.
I've written patches to Xorg to use this as UABI verification, and
I'll post a link to that very shortly.

This is also available in git form, in the wip/2018-03/getfb2 branches of:
    https://gitlab.collabora.com/daniels/linux
    https://gitlab.collabora.com/daniels/libdrm
    https://gitlab.collabora.com/daniels/igt-gpu-tools
    https://gitlab.collabora.com/daniels/xserver

Note that the kernel tree is based on top of drm-tip, and has a bunch
of patches to convert drivers to placing objects (rather than creating
handles). At the moment this is just missing amdgpu and nouveau to
complete the set of drivers, and also any testing whatsoever; I'm
sending a patch to convert Intel as that's what I've actually tested
on.

The conversion is necessary since GetFB2 ensures that it does _not_
return duplicate handles if multiple planes of a single buffer share
the same BO. This is impossible if we just use create_handle from the
driver, so instead we just rely on drivers placing the GEM object
pointers in the drm_framebuffer directly. This has the added advantage
of cleaning up a ton of unnecessary code in drivers.

Cheers,
Daniel
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

^ permalink raw reply	[flat|nested] 9+ messages in thread
* [igt-dev] [PATCH i-g-t 1/3] include: Update DRM uAPI headers
@ 2018-03-30 15:49 Daniel Stone
  2018-03-30 15:49 ` [igt-dev] [PATCH i-g-t 3/3] tests/kms_getfb: Add getfb2 tests Daniel Stone
  0 siblings, 1 reply; 9+ messages in thread
From: Daniel Stone @ 2018-03-30 15:49 UTC (permalink / raw)
  To: igt-dev

Taken from the drm-next pull for 4.17-rc1 (694f54f680f7).

Signed-off-by: Daniel Stone <daniels@collabora.com>
---
 include/drm-uapi/amdgpu_drm.h  | 3 +++
 include/drm-uapi/drm_mode.h    | 9 ++++++---
 include/drm-uapi/etnaviv_drm.h | 6 ++++++
 include/drm-uapi/msm_drm.h     | 2 ++
 include/drm-uapi/virtgpu_drm.h | 1 +
 5 files changed, 18 insertions(+), 3 deletions(-)

diff --git a/include/drm-uapi/amdgpu_drm.h b/include/drm-uapi/amdgpu_drm.h
index 1816bd82..c363b67f 100644
--- a/include/drm-uapi/amdgpu_drm.h
+++ b/include/drm-uapi/amdgpu_drm.h
@@ -618,6 +618,8 @@ struct drm_amdgpu_cs_chunk_data {
 	#define AMDGPU_INFO_FW_SOS		0x0c
 	/* Subquery id: Query PSP ASD firmware version */
 	#define AMDGPU_INFO_FW_ASD		0x0d
+	/* Subquery id: Query VCN firmware version */
+	#define AMDGPU_INFO_FW_VCN		0x0e
 /* number of bytes moved for TTM migration */
 #define AMDGPU_INFO_NUM_BYTES_MOVED		0x0f
 /* the used VRAM size */
@@ -806,6 +808,7 @@ struct drm_amdgpu_info_firmware {
 #define AMDGPU_VRAM_TYPE_GDDR5 5
 #define AMDGPU_VRAM_TYPE_HBM   6
 #define AMDGPU_VRAM_TYPE_DDR3  7
+#define AMDGPU_VRAM_TYPE_DDR4  8
 
 struct drm_amdgpu_info_device {
 	/** PCI Device ID */
diff --git a/include/drm-uapi/drm_mode.h b/include/drm-uapi/drm_mode.h
index 2c575794..50bcf421 100644
--- a/include/drm-uapi/drm_mode.h
+++ b/include/drm-uapi/drm_mode.h
@@ -363,7 +363,7 @@ struct drm_mode_get_connector {
 	__u32 pad;
 };
 
-#define DRM_MODE_PROP_PENDING	(1<<0)
+#define DRM_MODE_PROP_PENDING	(1<<0) /* deprecated, do not use */
 #define DRM_MODE_PROP_RANGE	(1<<1)
 #define DRM_MODE_PROP_IMMUTABLE	(1<<2)
 #define DRM_MODE_PROP_ENUM	(1<<3) /* enumerated type with text strings */
@@ -598,8 +598,11 @@ struct drm_mode_crtc_lut {
 };
 
 struct drm_color_ctm {
-	/* Conversion matrix in S31.32 format. */
-	__s64 matrix[9];
+	/*
+	 * Conversion matrix in S31.32 sign-magnitude
+	 * (not two's complement!) format.
+	 */
+	__u64 matrix[9];
 };
 
 struct drm_color_lut {
diff --git a/include/drm-uapi/etnaviv_drm.h b/include/drm-uapi/etnaviv_drm.h
index e9b997a0..0d5c49dc 100644
--- a/include/drm-uapi/etnaviv_drm.h
+++ b/include/drm-uapi/etnaviv_drm.h
@@ -55,6 +55,12 @@ struct drm_etnaviv_timespec {
 #define ETNAVIV_PARAM_GPU_FEATURES_4                0x07
 #define ETNAVIV_PARAM_GPU_FEATURES_5                0x08
 #define ETNAVIV_PARAM_GPU_FEATURES_6                0x09
+#define ETNAVIV_PARAM_GPU_FEATURES_7                0x0a
+#define ETNAVIV_PARAM_GPU_FEATURES_8                0x0b
+#define ETNAVIV_PARAM_GPU_FEATURES_9                0x0c
+#define ETNAVIV_PARAM_GPU_FEATURES_10               0x0d
+#define ETNAVIV_PARAM_GPU_FEATURES_11               0x0e
+#define ETNAVIV_PARAM_GPU_FEATURES_12               0x0f
 
 #define ETNAVIV_PARAM_GPU_STREAM_COUNT              0x10
 #define ETNAVIV_PARAM_GPU_REGISTER_MAX              0x11
diff --git a/include/drm-uapi/msm_drm.h b/include/drm-uapi/msm_drm.h
index bbbaffad..c06d0a5b 100644
--- a/include/drm-uapi/msm_drm.h
+++ b/include/drm-uapi/msm_drm.h
@@ -201,10 +201,12 @@ struct drm_msm_gem_submit_bo {
 #define MSM_SUBMIT_NO_IMPLICIT   0x80000000 /* disable implicit sync */
 #define MSM_SUBMIT_FENCE_FD_IN   0x40000000 /* enable input fence_fd */
 #define MSM_SUBMIT_FENCE_FD_OUT  0x20000000 /* enable output fence_fd */
+#define MSM_SUBMIT_SUDO          0x10000000 /* run submitted cmds from RB */
 #define MSM_SUBMIT_FLAGS                ( \
 		MSM_SUBMIT_NO_IMPLICIT   | \
 		MSM_SUBMIT_FENCE_FD_IN   | \
 		MSM_SUBMIT_FENCE_FD_OUT  | \
+		MSM_SUBMIT_SUDO          | \
 		0)
 
 /* Each cmdstream submit consists of a table of buffers involved, and
diff --git a/include/drm-uapi/virtgpu_drm.h b/include/drm-uapi/virtgpu_drm.h
index 91a31ffe..9a781f06 100644
--- a/include/drm-uapi/virtgpu_drm.h
+++ b/include/drm-uapi/virtgpu_drm.h
@@ -63,6 +63,7 @@ struct drm_virtgpu_execbuffer {
 };
 
 #define VIRTGPU_PARAM_3D_FEATURES 1 /* do we have 3D features in the hw */
+#define VIRTGPU_PARAM_CAPSET_QUERY_FIX 2 /* do we have the capset fix */
 
 struct drm_virtgpu_getparam {
 	__u64 param;
-- 
2.17.0.rc1

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2018-03-30 15:49 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-03-23 13:42 [igt-dev] [PATCH 0/8] Add GetFB2 ioctl Daniel Stone
2018-03-23 13:46 ` [igt-dev] [PATCH i-g-t 1/3] tests/kms_getfb: Split property-ID get into helper Daniel Stone
2018-03-23 13:46   ` [PATCH i-g-t 2/3] NOMERGE: Update DRM UAPI to latest kernel version Daniel Stone
2018-03-23 13:46   ` [igt-dev] [PATCH i-g-t 3/3] tests/kms_getfb: Add getfb2 tests Daniel Stone
2018-03-23 15:01     ` Ville Syrjälä
2018-03-23 14:53   ` [igt-dev] [PATCH i-g-t 1/3] tests/kms_getfb: Split property-ID get into helper Ville Syrjälä
2018-03-23 14:55     ` Daniel Stone
2018-03-23 13:51 ` [igt-dev] [PATCH 0/8] Add GetFB2 ioctl Daniel Stone
  -- strict thread matches above, loose matches on Subject: below --
2018-03-30 15:49 [igt-dev] [PATCH i-g-t 1/3] include: Update DRM uAPI headers Daniel Stone
2018-03-30 15:49 ` [igt-dev] [PATCH i-g-t 3/3] tests/kms_getfb: Add getfb2 tests Daniel Stone

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox