sdm: drm: Add post-processing support in SDM
SDM added support for the DRM driver recently. This change
adds the similar support in the SDM to enable/disable
post-processing features via DRM driver for QDCM.
CRs-Fixed: 2007376
Change-Id: I39d8d2c76a28aac0675c559dceb6dcf74eb170fb
diff --git a/libdrmutils/drm_interface.h b/libdrmutils/drm_interface.h
index 94a48e1..399972b 100644
--- a/libdrmutils/drm_interface.h
+++ b/libdrmutils/drm_interface.h
@@ -136,6 +136,12 @@
*/
CRTC_GET_RELEASE_FENCE,
/*
+ * Op: Sets PP feature
+ * Arg: uint32_t - CRTC ID
+ * DRMPPFeatureInfo * - PP feature data pointer
+ */
+ CRTC_SET_POST_PROC,
+ /*
* Op: Returns retire fence for this commit. Should be called after Commit() on
* DRMAtomicReqInterface.
* Arg: uint32_t - Connector ID
@@ -262,6 +268,33 @@
uint32_t crtc_id;
};
+enum DRMPPFeatureID {
+ kFeaturePcc,
+ kFeatureIgc,
+ kFeaturePgc,
+ kFeatureMixerGc,
+ kFeaturePaV2,
+ kFeatureDither,
+ kFeatureGamut,
+ kFeaturePADither,
+ kPPFeaturesMax,
+};
+
+enum DRMPPPropType {
+ kPropEnum,
+ kPropRange,
+ kPropBlob,
+ kPropTypeMax,
+};
+
+struct DRMPPFeatureInfo {
+ DRMPPFeatureID id;
+ DRMPPPropType type;
+ uint32_t version;
+ uint32_t payload_size;
+ void *payload;
+};
+
/* DRM Atomic Request Property Set.
*
* Helper class to create and populate atomic properties of DRM components
@@ -331,6 +364,11 @@
virtual void GetConnectorInfo(uint32_t conn_id, DRMConnectorInfo *info) = 0;
/*
+ * Will query post propcessing feature info of a CRTC.
+ * [output]: DRMPPFeatureInfo: CRTC post processing feature info
+ */
+ virtual void GetCrtcPPInfo(uint32_t crtc_id, DRMPPFeatureInfo &info) = 0;
+ /*
* Register a logical display to receive a token.
* Each display pipeline in DRM is identified by its CRTC and Connector(s).
* On display connect(bootup or hotplug), clients should invoke this interface to