Skip to contentSkip to conversation

drm/colorop: Remove read-only comments from interpolation fields

PATCH In review Alex Hung 2 participants 3 messages Apr 2 – Apr 3

Subsystems (2)
lore
Share & tools
lore

Alex Hung

author
#0 lore raw

PATCH 1/1 drm/colorop: Remove read-only comments from interpolation fields

The lut1d_interpolation and lut3d_interpolation fields and their associated properties were marked as read-only, but userspace can set them via drm_atomic_colorop_set_property().

---
 include/drm/drm_colorop.h | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)
include/drm/drm_colorop.h +2 -4
index a3a32f9f918c..5bcb510e56c0 100644
@@ -296,7 +296,6 @@ struct drm_colorop {
 	/**
 	 * @lut1d_interpolation:
 	 *
-	 * Read-only
 	 * Interpolation for DRM_COLOROP_1D_LUT
 	 */
 	enum drm_colorop_lut1d_interpolation_type lut1d_interpolation;
@@ -304,7 +303,6 @@ struct drm_colorop {
 	/**
 	 * @lut3d_interpolation:
 	 *
-	 * Read-only
 	 * Interpolation for DRM_COLOROP_3D_LUT
 	 */
 	enum drm_colorop_lut3d_interpolation_type lut3d_interpolation;
@@ -312,7 +310,7 @@ struct drm_colorop {
 	/**
 	 * @lut1d_interpolation_property:
 	 *
-	 * Read-only property for DRM_COLOROP_1D_LUT interpolation
+	 * Property for DRM_COLOROP_1D_LUT interpolation
 	 */
 	struct drm_property *lut1d_interpolation_property;
 
@@ -340,7 +338,7 @@ struct drm_colorop {
 	/**
 	 * @lut3d_interpolation_property:
 	 *
-	 * Read-only property for DRM_COLOROP_3D_LUT interpolation
+	 * Property for DRM_COLOROP_3D_LUT interpolation
 	 */
 	struct drm_property *lut3d_interpolation_property;
 
Signature · 1 line
2.43.0
#1 lore raw
Quoted 3 lines · Alex Hung

The lut1d_interpolation and lut3d_interpolation fields and their associated properties were marked as read-only, but userspace can set them via drm_atomic_colorop_set_property().

Hi Alex,

Just removing wrong comments is not enough. Those properties still behave as immutable.

lut1d/3d_interpolation should be handle by drm_colorop_state as they are mutable, not in drm_colorop. ...and changes are needed everywhere we manage states of colorop mutable properties.

Melissa

Quoted 44 lines
---
  include/drm/drm_colorop.h | 6 ++----
  1 file changed, 2 insertions(+), 4 deletions(-)
include/drm/drm_colorop.h +2 -4
index a3a32f9f918c..5bcb510e56c0 100644
@@ -296,7 +296,6 @@ struct drm_colorop {
  	/**
  	 * @lut1d_interpolation:
  	 *
-	 * Read-only
  	 * Interpolation for DRM_COLOROP_1D_LUT
  	 */
  	enum drm_colorop_lut1d_interpolation_type lut1d_interpolation;
@@ -304,7 +303,6 @@ struct drm_colorop {
  	/**
  	 * @lut3d_interpolation:
  	 *
-	 * Read-only
  	 * Interpolation for DRM_COLOROP_3D_LUT
  	 */
  	enum drm_colorop_lut3d_interpolation_type lut3d_interpolation;
@@ -312,7 +310,7 @@ struct drm_colorop {
  	/**
  	 * @lut1d_interpolation_property:
  	 *
-	 * Read-only property for DRM_COLOROP_1D_LUT interpolation
+	 * Property for DRM_COLOROP_1D_LUT interpolation
  	 */
  	struct drm_property *lut1d_interpolation_property;
 
@@ -340,7 +338,7 @@ struct drm_colorop {
  	/**
  	 * @lut3d_interpolation_property:
  	 *
-	 * Read-only property for DRM_COLOROP_3D_LUT interpolation
+	 * Property for DRM_COLOROP_3D_LUT interpolation
  	 */
  	struct drm_property *lut3d_interpolation_property;
 
#2 lore raw
Quoted 6 lines · Melissa Wen
Quoted 3 lines · Alex Hung

The lut1d_interpolation and lut3d_interpolation fields and their associated properties were marked as read-only, but userspace can set them via drm_atomic_colorop_set_property().

Quoted 6 lines

Hi Alex,

Just removing wrong comments is not enough. Those properties still behave as immutable.

lut1d/3d_interpolation should be handle by drm_colorop_state as they are mutable, not in drm_colorop. ...and changes are needed everywhere we manage states of colorop mutable properties.

As I was working on tracking changes and my series depends on this change, I just did it and send here:
https://lore.kernel.org/dri-devel/[email protected]/

Melissa

Quoted 45 lines

Melissa

Quoted 42 lines

---
  include/drm/drm_colorop.h | 6 ++----

  1 file changed, 2 insertions(+), 4 deletions(-)
include/drm/drm_colorop.h +1 -3
index a3a32f9f918c..5bcb510e56c0 100644
@@ -296,7 +296,6 @@ struct drm_colorop {
       /**
        * @lut1d_interpolation:
        *
-     * Read-only
        * Interpolation for DRM_COLOROP_1D_LUT
        */
       enum drm_colorop_lut1d_interpolation_type lut1d_interpolation;
@@ -304,7 +303,6 @@ struct drm_colorop {
       /**
        * @lut3d_interpolation:
        *
-     * Read-only
        * Interpolation for DRM_COLOROP_3D_LUT
        */
       enum drm_colorop_lut3d_interpolation_type lut3d_interpolation;
@@ -312,7 +310,7 @@ struct drm_colorop {
       /**
        * @lut1d_interpolation_property:
        *
-     * Read-only property for DRM_COLOROP_1D_LUT interpolation
+     * Property for DRM_COLOROP_1D_LUT interpolation
        */
       struct drm_property *lut1d_interpolation_property;
   @@ -340,7 +338,7 @@ struct drm_colorop {

      /**
       * @lut3d_interpolation_property:
       *
-     * Read-only property for DRM_COLOROP_3D_LUT interpolation +     * Property for DRM_COLOROP_3D_LUT interpolation */
      struct drm_property *lut3d_interpolation_property;