[PATCH v2 1/5] drm/sitronix/st7571-i2c: Fix encoder callbacks function names

Javier Martinez Canillas posted 5 patches 2 months, 3 weeks ago
There is a newer version of this series
[PATCH v2 1/5] drm/sitronix/st7571-i2c: Fix encoder callbacks function names
Posted by Javier Martinez Canillas 2 months, 3 weeks ago
It seems the driver took some inspiration from ssd130x and some of the
functions (encoder callbacks) were not renamed to use a st7571_ prefix.

Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>
---

(no changes since v1)

 drivers/gpu/drm/sitronix/st7571-i2c.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/drivers/gpu/drm/sitronix/st7571-i2c.c b/drivers/gpu/drm/sitronix/st7571-i2c.c
index eec846892962..634b426e2874 100644
--- a/drivers/gpu/drm/sitronix/st7571-i2c.c
+++ b/drivers/gpu/drm/sitronix/st7571-i2c.c
@@ -550,8 +550,8 @@ static const struct drm_crtc_funcs st7571_crtc_funcs = {
  * Encoder
  */
 
-static void ssd130x_encoder_atomic_enable(struct drm_encoder *encoder,
-					  struct drm_atomic_state *state)
+static void st7571_encoder_atomic_enable(struct drm_encoder *encoder,
+					 struct drm_atomic_state *state)
 {
 	struct drm_device *drm = encoder->dev;
 	struct st7571_device *st7571 = drm_to_st7571(drm);
@@ -565,8 +565,8 @@ static void ssd130x_encoder_atomic_enable(struct drm_encoder *encoder,
 	st7571_send_command_list(st7571, &command, 1);
 }
 
-static void ssd130x_encoder_atomic_disable(struct drm_encoder *encoder,
-					   struct drm_atomic_state *state)
+static void st7571_encoder_atomic_disable(struct drm_encoder *encoder,
+					  struct drm_atomic_state *state)
 {
 	struct drm_device *drm = encoder->dev;
 	struct st7571_device *st7571 = drm_to_st7571(drm);
@@ -581,8 +581,8 @@ static const struct drm_encoder_funcs st7571_encoder_funcs = {
 };
 
 static const struct drm_encoder_helper_funcs st7571_encoder_helper_funcs = {
-	.atomic_enable = ssd130x_encoder_atomic_enable,
-	.atomic_disable = ssd130x_encoder_atomic_disable,
+	.atomic_enable = st7571_encoder_atomic_enable,
+	.atomic_disable = st7571_encoder_atomic_disable,
 };
 
 /*
-- 
2.49.0
Re: [PATCH v2 1/5] drm/sitronix/st7571-i2c: Fix encoder callbacks function names
Posted by Marcus Folkesson 2 months, 3 weeks ago
On Mon, Jul 14, 2025 at 12:44:00PM +0200, Javier Martinez Canillas wrote:
> It seems the driver took some inspiration from ssd130x and some of the
> functions (encoder callbacks) were not renamed to use a st7571_ prefix.

Outch, shame on me.
> 
> Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>

Reviewed-by: Marcus Folkesson <marcus.folkesson@gmail.com>

Re: [PATCH v2 1/5] drm/sitronix/st7571-i2c: Fix encoder callbacks function names
Posted by Javier Martinez Canillas 2 months, 3 weeks ago
Marcus Folkesson <marcus.folkesson@gmail.com> writes:

Hello Marcus,

> On Mon, Jul 14, 2025 at 12:44:00PM +0200, Javier Martinez Canillas wrote:
>> It seems the driver took some inspiration from ssd130x and some of the
>> functions (encoder callbacks) were not renamed to use a st7571_ prefix.
>
> Outch, shame on me.

On the contrary, I'm glad to know that the ssd130x driver was useful :)

>> 
>> Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>
>
> Reviewed-by: Marcus Folkesson <marcus.folkesson@gmail.com>
>

Thanks for your review!

-- 
Best regards,

Javier Martinez Canillas
Core Platforms
Red Hat