Skip to contentSkip to conversation

accel/ivpu: Document DRM_IVPU_PARAM_CAPABILITIES

PATCH In review Stanislaw Gruszka 2 participants 5 messages Aug 10, 2023 – Aug 11, 2023

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 accel/ivpu: Document DRM_IVPU_PARAM_CAPABILITIES

Add comments regarding new DRM_IVPU_PARAM_CAPABILITIES param.

---
 include/uapi/drm/ivpu_accel.h | 19 +++++++++++++++++--
 1 file changed, 17 insertions(+), 2 deletions(-)
include/uapi/drm/ivpu_accel.h +17 -2
index a58a14c9f222..7d1ecc5bbac3 100644
@@ -69,8 +69,21 @@ extern "C" {
 #define DRM_IVPU_CONTEXT_PRIORITY_FOCUS	    2
 #define DRM_IVPU_CONTEXT_PRIORITY_REALTIME  3
 
-#define DRM_IVPU_CAP_METRIC_STREAMER	    1
-#define DRM_IVPU_CAP_DMA_MEMORY_RANGE       2
+/**
+ * DRM_IVPU_CAP_METRIC_STREAMER
+ *
+ * Metric streamer support, provides sampling of various hardware
+ * performance metrics (like DMA bandwidth, cache miss/hits),
+ * can be used for profiling.
+ */
+#define DRM_IVPU_CAP_METRIC_STREAMER	1
+/**
+ * DRM_IVPU_CAP_DMA_MEMORY_RANGE
+ *
+ * Driver has capability to allocate separate memory range
+ * accessible by hardware DMA.
+ */
+#define DRM_IVPU_CAP_DMA_MEMORY_RANGE	2
 
 /**
  * struct drm_ivpu_param - Get/Set VPU parameters
@@ -123,6 +136,8 @@ struct drm_ivpu_param {
 	 * %DRM_IVPU_PARAM_SKU:
 	 * VPU SKU ID (read-only)
 	 *
+	 * %DRM_IVPU_PARAM_CAPABILITIES:
+	 * Supported capabilities (read-only)
 	 */
 	__u32 param;
 
Signature · 1 line
2.25.1
#1 lore raw
Quoted 13 lines · Stanislaw Gruszka

Add comments regarding new DRM_IVPU_PARAM_CAPABILITIES param.

---
  include/uapi/drm/ivpu_accel.h | 19 +++++++++++++++++--
  1 file changed, 17 insertions(+), 2 deletions(-)
include/uapi/drm/ivpu_accel.h +0 -0
index a58a14c9f222..7d1ecc5bbac3 100644
@@ -69,8 +69,21 @@ extern "C" {
  #define DRM_IVPU_CONTEXT_PRIORITY_FOCUS	    2

include/uapi/drm/ivpu_accel.h extern "C" { · line 77

Quoted 10 lines
include/uapi/drm/ivpu_accel.h +6 -2
  #define DRM_IVPU_CONTEXT_PRIORITY_REALTIME  3
 
-#define DRM_IVPU_CAP_METRIC_STREAMER	    1
-#define DRM_IVPU_CAP_DMA_MEMORY_RANGE       2
+/**
+ * DRM_IVPU_CAP_METRIC_STREAMER
+ *
+ * Metric streamer support, provides sampling of various hardware
+ * performance metrics (like DMA bandwidth, cache miss/hits),
+ * can be used for profiling.

Feels like this is a run-on sentence. I think this reads better -

Metric streamer support. Provides sampling of various hardware performance metrics like DMA bandwidth and cache miss/hits. Can be used for profiling.

What do you think?

Quoted 21 lines
include/uapi/drm/ivpu_accel.h +11 -0
+ */
+#define DRM_IVPU_CAP_METRIC_STREAMER	1
+/**
+ * DRM_IVPU_CAP_DMA_MEMORY_RANGE
+ *
+ * Driver has capability to allocate separate memory range
+ * accessible by hardware DMA.
+ */
+#define DRM_IVPU_CAP_DMA_MEMORY_RANGE	2
 
  /**
   * struct drm_ivpu_param - Get/Set VPU parameters
@@ -123,6 +136,8 @@ struct drm_ivpu_param {
  	 * %DRM_IVPU_PARAM_SKU:
  	 * VPU SKU ID (read-only)
  	 *
+	 * %DRM_IVPU_PARAM_CAPABILITIES:
+	 * Supported capabilities (read-only)
  	 */
  	__u32 param;
 
#2 lore raw
Quoted 26 lines · Jeffrey Hugo
Quoted 12 lines · Stanislaw Gruszka

Add comments regarding new DRM_IVPU_PARAM_CAPABILITIES param.

---
  include/uapi/drm/ivpu_accel.h | 19 +++++++++++++++++--
  1 file changed, 17 insertions(+), 2 deletions(-)
include/uapi/drm/ivpu_accel.h +0 -0
index a58a14c9f222..7d1ecc5bbac3 100644

include/uapi/drm/ivpu_accel.h extern "C" { · line 76

Quoted 10 lines
include/uapi/drm/ivpu_accel.h +6 -2
@@ -69,8 +69,21 @@ extern "C" {
  #define DRM_IVPU_CONTEXT_PRIORITY_FOCUS	    2
  #define DRM_IVPU_CONTEXT_PRIORITY_REALTIME  3
-#define DRM_IVPU_CAP_METRIC_STREAMER	    1
-#define DRM_IVPU_CAP_DMA_MEMORY_RANGE       2
+/**
+ * DRM_IVPU_CAP_METRIC_STREAMER
+ *
+ * Metric streamer support, provides sampling of various hardware
+ * performance metrics (like DMA bandwidth, cache miss/hits),
+ * can be used for profiling.

Feels like this is a run-on sentence. I think this reads better -

Quoted 4 lines

Metric streamer support. Provides sampling of various hardware performance metrics like DMA bandwidth and cache miss/hits. Can be used for profiling.

What do you think?

Looks better :-)

Thanks
Stanislaw

Reviewed-by
#3 lore raw
Quoted 27 lines · Stanislaw Gruszka
Quoted 26 lines · Jeffrey Hugo
Quoted 12 lines · Stanislaw Gruszka

Add comments regarding new DRM_IVPU_PARAM_CAPABILITIES param.

---
   include/uapi/drm/ivpu_accel.h | 19 +++++++++++++++++--
   1 file changed, 17 insertions(+), 2 deletions(-)
include/uapi/drm/ivpu_accel.h +0 -0
index a58a14c9f222..7d1ecc5bbac3 100644

include/uapi/drm/ivpu_accel.h extern "C" { · line 76

Quoted 10 lines
include/uapi/drm/ivpu_accel.h +6 -2
@@ -69,8 +69,21 @@ extern "C" {
   #define DRM_IVPU_CONTEXT_PRIORITY_FOCUS	    2
   #define DRM_IVPU_CONTEXT_PRIORITY_REALTIME  3
-#define DRM_IVPU_CAP_METRIC_STREAMER	    1
-#define DRM_IVPU_CAP_DMA_MEMORY_RANGE       2
+/**
+ * DRM_IVPU_CAP_METRIC_STREAMER
+ *
+ * Metric streamer support, provides sampling of various hardware
+ * performance metrics (like DMA bandwidth, cache miss/hits),
+ * can be used for profiling.

Feels like this is a run-on sentence. I think this reads better -

Quoted 6 lines
Quoted 4 lines

Metric streamer support. Provides sampling of various hardware performance metrics like DMA bandwidth and cache miss/hits. Can be used for profiling.

What do you think?

Looks better :-)

Ok. I guess with that

author Applied
#4 lore raw
Quoted 31 lines · Jeffrey Hugo
Quoted 30 lines · Stanislaw Gruszka
Quoted 29 lines · Jeffrey Hugo
Quoted 12 lines · Stanislaw Gruszka

Add comments regarding new DRM_IVPU_PARAM_CAPABILITIES param.

---
   include/uapi/drm/ivpu_accel.h | 19 +++++++++++++++++--
   1 file changed, 17 insertions(+), 2 deletions(-)
include/uapi/drm/ivpu_accel.h +0 -0
index a58a14c9f222..7d1ecc5bbac3 100644

include/uapi/drm/ivpu_accel.h extern "C" { · line 76

Quoted 10 lines
include/uapi/drm/ivpu_accel.h +6 -2
@@ -69,8 +69,21 @@ extern "C" {
   #define DRM_IVPU_CONTEXT_PRIORITY_FOCUS	    2
   #define DRM_IVPU_CONTEXT_PRIORITY_REALTIME  3
-#define DRM_IVPU_CAP_METRIC_STREAMER	    1
-#define DRM_IVPU_CAP_DMA_MEMORY_RANGE       2
+/**
+ * DRM_IVPU_CAP_METRIC_STREAMER
+ *
+ * Metric streamer support, provides sampling of various hardware
+ * performance metrics (like DMA bandwidth, cache miss/hits),
+ * can be used for profiling.

Feels like this is a run-on sentence. I think this reads better -

Metric streamer support. Provides sampling of various hardware performance metrics like DMA bandwidth and cache miss/hits. Can be used for profiling.

Quoted 6 lines
Quoted 3 lines
Quoted 1 line

What do you think?

Looks better :-)

Ok. I guess with that

Thanks, applied to drm-misc-next

Regards
Stanislaw