linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] staging: sm750fb: rename 'proc_setBLANK'
@ 2025-06-18 14:15 Kisub Choe
  2025-06-18 14:26 ` Greg KH
  0 siblings, 1 reply; 7+ messages in thread
From: Kisub Choe @ 2025-06-18 14:15 UTC (permalink / raw)
  To: sudipm.mukherjee, teddy.wang, gregkh
  Cc: linux-fbdev, linux-staging, linux-kernel, kisub.choe.0x1

Rename 'proc_setBLANK' to 'proc_setBLANK' to
conform with kernel style guidelines as reported by checkpatch.pl

CHECK: Avoid CamelCase: <proc_setBLANK>

Signed-off-by: Kisub Choe <kisub.choe.0x1@gmail.com>
---
 drivers/staging/sm750fb/sm750.c | 4 ++--
 drivers/staging/sm750fb/sm750.h | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/staging/sm750fb/sm750.c b/drivers/staging/sm750fb/sm750.c
index 1d929aca399c..bb2ade6030c2 100644
--- a/drivers/staging/sm750fb/sm750.c
+++ b/drivers/staging/sm750fb/sm750.c
@@ -577,7 +577,7 @@ static int lynxfb_ops_blank(int blank, struct fb_info *info)
 	pr_debug("blank = %d.\n", blank);
 	par = info->par;
 	output = &par->output;
-	return output->proc_setBLANK(output, blank);
+	return output->proc_set_blank(output, blank);
 }
 
 static int sm750fb_set_drv(struct lynxfb_par *par)
@@ -605,7 +605,7 @@ static int sm750fb_set_drv(struct lynxfb_par *par)
 	crtc->ypanstep = 1;
 	crtc->ywrapstep = 0;
 
-	output->proc_setBLANK = (sm750_dev->revid == SM750LE_REVISION_ID) ?
+	output->proc_set_blank = (sm750_dev->revid == SM750LE_REVISION_ID) ?
 				 hw_sm750le_set_blank : hw_sm750_set_blank;
 	/* chip specific phase */
 	sm750_dev->accel.de_wait = (sm750_dev->revid == SM750LE_REVISION_ID) ?
diff --git a/drivers/staging/sm750fb/sm750.h b/drivers/staging/sm750fb/sm750.h
index 9cf8b3d30aac..40051798efbf 100644
--- a/drivers/staging/sm750fb/sm750.h
+++ b/drivers/staging/sm750fb/sm750.h
@@ -170,7 +170,7 @@ struct lynxfb_output {
 	 */
 	void *priv;
 
-	int (*proc_setBLANK)(struct lynxfb_output *output, int blank);
+	int (*proc_set_blank)(struct lynxfb_output *output, int blank);
 };
 
 struct lynxfb_par {
-- 
2.34.1


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

* Re: [PATCH] staging: sm750fb: rename 'proc_setBLANK'
  2025-06-18 14:15 [PATCH] staging: sm750fb: rename 'proc_setBLANK' Kisub Choe
@ 2025-06-18 14:26 ` Greg KH
  2025-06-19 13:12   ` [PATCH v2] " Kisub Choe
  0 siblings, 1 reply; 7+ messages in thread
From: Greg KH @ 2025-06-18 14:26 UTC (permalink / raw)
  To: Kisub Choe
  Cc: sudipm.mukherjee, teddy.wang, linux-fbdev, linux-staging,
	linux-kernel

On Wed, Jun 18, 2025 at 11:15:55PM +0900, Kisub Choe wrote:
> Rename 'proc_setBLANK' to 'proc_setBLANK' to

That doesn't rename anything :(



> conform with kernel style guidelines as reported by checkpatch.pl
> 
> CHECK: Avoid CamelCase: <proc_setBLANK>
> 
> Signed-off-by: Kisub Choe <kisub.choe.0x1@gmail.com>
> ---
>  drivers/staging/sm750fb/sm750.c | 4 ++--
>  drivers/staging/sm750fb/sm750.h | 2 +-
>  2 files changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/staging/sm750fb/sm750.c b/drivers/staging/sm750fb/sm750.c
> index 1d929aca399c..bb2ade6030c2 100644
> --- a/drivers/staging/sm750fb/sm750.c
> +++ b/drivers/staging/sm750fb/sm750.c
> @@ -577,7 +577,7 @@ static int lynxfb_ops_blank(int blank, struct fb_info *info)
>  	pr_debug("blank = %d.\n", blank);
>  	par = info->par;
>  	output = &par->output;
> -	return output->proc_setBLANK(output, blank);
> +	return output->proc_set_blank(output, blank);
>  }
>  
>  static int sm750fb_set_drv(struct lynxfb_par *par)
> @@ -605,7 +605,7 @@ static int sm750fb_set_drv(struct lynxfb_par *par)
>  	crtc->ypanstep = 1;
>  	crtc->ywrapstep = 0;
>  
> -	output->proc_setBLANK = (sm750_dev->revid == SM750LE_REVISION_ID) ?
> +	output->proc_set_blank = (sm750_dev->revid == SM750LE_REVISION_ID) ?
>  				 hw_sm750le_set_blank : hw_sm750_set_blank;

Why do we even need this function pointer?  Why not just do the check
above when it is called instead of this indirection?

thanks,

greg k-h

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

* Re: [PATCH v2] staging: sm750fb: rename 'proc_setBLANK'
  2025-06-18 14:26 ` Greg KH
@ 2025-06-19 13:12   ` Kisub Choe
  2025-06-19 13:24     ` Greg KH
  0 siblings, 1 reply; 7+ messages in thread
From: Kisub Choe @ 2025-06-19 13:12 UTC (permalink / raw)
  To: Greg KH
  Cc: sudipm.mukherjee, teddy.wang, linux-fbdev, linux-staging,
	linux-kernel

On Wed, Jun 18, 2025 at 04:26:10PM +0200, Greg KH wrote:
> On Wed, Jun 18, 2025 at 11:15:55PM +0900, Kisub Choe wrote:
> > Rename 'proc_setBLANK' to 'proc_setBLANK' to
> 
> That doesn't rename anything :(
Rename 'proc_setBLANK' to 'proc_set_blank' to
> 
> 
> 
> > conform with kernel style guidelines as reported by checkpatch.pl
> > 
> > CHECK: Avoid CamelCase: <proc_setBLANK>
> > 
> > Signed-off-by: Kisub Choe <kisub.choe.0x1@gmail.com>
> > ---
> >  drivers/staging/sm750fb/sm750.c | 4 ++--
> >  drivers/staging/sm750fb/sm750.h | 2 +-
> >  2 files changed, 3 insertions(+), 3 deletions(-)
> > 
> > diff --git a/drivers/staging/sm750fb/sm750.c b/drivers/staging/sm750fb/sm750.c
> > index 1d929aca399c..bb2ade6030c2 100644
> > --- a/drivers/staging/sm750fb/sm750.c
> > +++ b/drivers/staging/sm750fb/sm750.c
> > @@ -577,7 +577,7 @@ static int lynxfb_ops_blank(int blank, struct fb_info *info)
> >  	pr_debug("blank = %d.\n", blank);
> >  	par = info->par;
> >  	output = &par->output;
> > -	return output->proc_setBLANK(output, blank);
> > +	return output->proc_set_blank(output, blank);
> >  }
> >  
> >  static int sm750fb_set_drv(struct lynxfb_par *par)
> > @@ -605,7 +605,7 @@ static int sm750fb_set_drv(struct lynxfb_par *par)
> >  	crtc->ypanstep = 1;
> >  	crtc->ywrapstep = 0;
> >  
> > -	output->proc_setBLANK = (sm750_dev->revid == SM750LE_REVISION_ID) ?
> > +	output->proc_set_blank = (sm750_dev->revid == SM750LE_REVISION_ID) ?
> >  				 hw_sm750le_set_blank : hw_sm750_set_blank;
> 
> Why do we even need this function pointer?  Why not just do the check
> above when it is called instead of this indirection?
> 
> thanks,
> 
> greg k-h

Dear Greg,

Here is the updated patch with revised commit message. No code changes.

Regards,
Kisub Choe.

From 9c32c6f5091c8babe54bfde7b3a6de47d9026a55 Mon Sep 17 00:00:00 2001
From: Kisub Choe <kisub.choe.0x1@gmail.com>
Date: Wed, 18 Jun 2025 22:55:00 +0900
Subject: [PATCH] staging: sm750fb: rename 'proc_setBLANK'

Rename 'proc_setBLANK' to 'proc_set_blank' to
conform with kernel style guidelines as reported by checkpatch.pl

CHECK: Avoid CamelCase: <proc_setBLANK>

Signed-off-by: Kisub Choe <kisub.choe.0x1@gmail.com>
---
 drivers/staging/sm750fb/sm750.c | 4 ++--
 drivers/staging/sm750fb/sm750.h | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/staging/sm750fb/sm750.c b/drivers/staging/sm750fb/sm750.c
index 1d929aca399c..bb2ade6030c2 100644
--- a/drivers/staging/sm750fb/sm750.c
+++ b/drivers/staging/sm750fb/sm750.c
@@ -577,7 +577,7 @@ static int lynxfb_ops_blank(int blank, struct fb_info *info)
 	pr_debug("blank = %d.\n", blank);
 	par = info->par;
 	output = &par->output;
-	return output->proc_setBLANK(output, blank);
+	return output->proc_set_blank(output, blank);
 }
 
 static int sm750fb_set_drv(struct lynxfb_par *par)
@@ -605,7 +605,7 @@ static int sm750fb_set_drv(struct lynxfb_par *par)
 	crtc->ypanstep = 1;
 	crtc->ywrapstep = 0;
 
-	output->proc_setBLANK = (sm750_dev->revid == SM750LE_REVISION_ID) ?
+	output->proc_set_blank = (sm750_dev->revid == SM750LE_REVISION_ID) ?
 				 hw_sm750le_set_blank : hw_sm750_set_blank;
 	/* chip specific phase */
 	sm750_dev->accel.de_wait = (sm750_dev->revid == SM750LE_REVISION_ID) ?
diff --git a/drivers/staging/sm750fb/sm750.h b/drivers/staging/sm750fb/sm750.h
index 9cf8b3d30aac..40051798efbf 100644
--- a/drivers/staging/sm750fb/sm750.h
+++ b/drivers/staging/sm750fb/sm750.h
@@ -170,7 +170,7 @@ struct lynxfb_output {
 	 */
 	void *priv;
 
-	int (*proc_setBLANK)(struct lynxfb_output *output, int blank);
+	int (*proc_set_blank)(struct lynxfb_output *output, int blank);
 };
 
 struct lynxfb_par {
-- 
2.34.1


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

* Re: [PATCH v2] staging: sm750fb: rename 'proc_setBLANK'
  2025-06-19 13:12   ` [PATCH v2] " Kisub Choe
@ 2025-06-19 13:24     ` Greg KH
  2025-06-19 13:49       ` Kisub Choe
  0 siblings, 1 reply; 7+ messages in thread
From: Greg KH @ 2025-06-19 13:24 UTC (permalink / raw)
  To: Kisub Choe
  Cc: sudipm.mukherjee, teddy.wang, linux-fbdev, linux-staging,
	linux-kernel

On Thu, Jun 19, 2025 at 10:12:13PM +0900, Kisub Choe wrote:
> On Wed, Jun 18, 2025 at 04:26:10PM +0200, Greg KH wrote:
> > On Wed, Jun 18, 2025 at 11:15:55PM +0900, Kisub Choe wrote:
> > > Rename 'proc_setBLANK' to 'proc_setBLANK' to
> > 
> > That doesn't rename anything :(
> Rename 'proc_setBLANK' to 'proc_set_blank' to
> > 
> > 
> > 
> > > conform with kernel style guidelines as reported by checkpatch.pl
> > > 
> > > CHECK: Avoid CamelCase: <proc_setBLANK>
> > > 
> > > Signed-off-by: Kisub Choe <kisub.choe.0x1@gmail.com>
> > > ---
> > >  drivers/staging/sm750fb/sm750.c | 4 ++--
> > >  drivers/staging/sm750fb/sm750.h | 2 +-
> > >  2 files changed, 3 insertions(+), 3 deletions(-)
> > > 
> > > diff --git a/drivers/staging/sm750fb/sm750.c b/drivers/staging/sm750fb/sm750.c
> > > index 1d929aca399c..bb2ade6030c2 100644
> > > --- a/drivers/staging/sm750fb/sm750.c
> > > +++ b/drivers/staging/sm750fb/sm750.c
> > > @@ -577,7 +577,7 @@ static int lynxfb_ops_blank(int blank, struct fb_info *info)
> > >  	pr_debug("blank = %d.\n", blank);
> > >  	par = info->par;
> > >  	output = &par->output;
> > > -	return output->proc_setBLANK(output, blank);
> > > +	return output->proc_set_blank(output, blank);
> > >  }
> > >  
> > >  static int sm750fb_set_drv(struct lynxfb_par *par)
> > > @@ -605,7 +605,7 @@ static int sm750fb_set_drv(struct lynxfb_par *par)
> > >  	crtc->ypanstep = 1;
> > >  	crtc->ywrapstep = 0;
> > >  
> > > -	output->proc_setBLANK = (sm750_dev->revid == SM750LE_REVISION_ID) ?
> > > +	output->proc_set_blank = (sm750_dev->revid == SM750LE_REVISION_ID) ?
> > >  				 hw_sm750le_set_blank : hw_sm750_set_blank;
> > 
> > Why do we even need this function pointer?  Why not just do the check
> > above when it is called instead of this indirection?
> > 
> > thanks,
> > 
> > greg k-h
> 
> Dear Greg,
> 
> Here is the updated patch with revised commit message. No code changes.

Please read the documentation for how to send an updated patch (hint, it
needs to be a new version).

Also, see my comments above about what you should do here instead of
just renaming the variable.  Please make that change which will remove
the variable entirely.

thanks,

greg k-h

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

* Re: [PATCH v2] staging: sm750fb: rename 'proc_setBLANK'
  2025-06-19 13:24     ` Greg KH
@ 2025-06-19 13:49       ` Kisub Choe
  2025-06-19 13:52         ` Greg KH
  0 siblings, 1 reply; 7+ messages in thread
From: Kisub Choe @ 2025-06-19 13:49 UTC (permalink / raw)
  To: Greg KH
  Cc: Kisub Choe, sudipm.mukherjee, teddy.wang, linux-fbdev,
	linux-staging, linux-kernel

On Thu, Jun 19, 2025 at 03:24:26PM +0200, Greg KH wrote:
> On Thu, Jun 19, 2025 at 10:12:13PM +0900, Kisub Choe wrote:
> > On Wed, Jun 18, 2025 at 04:26:10PM +0200, Greg KH wrote:
> > > On Wed, Jun 18, 2025 at 11:15:55PM +0900, Kisub Choe wrote:
> > > > Rename 'proc_setBLANK' to 'proc_setBLANK' to
> > > 
> > > That doesn't rename anything :(
> > Rename 'proc_setBLANK' to 'proc_set_blank' to
> > > 
> > > 
> > > 
> > > > conform with kernel style guidelines as reported by checkpatch.pl
> > > > 
> > > > CHECK: Avoid CamelCase: <proc_setBLANK>
> > > > 
> > > > Signed-off-by: Kisub Choe <kisub.choe.0x1@gmail.com>
> > > > ---
> > > >  drivers/staging/sm750fb/sm750.c | 4 ++--
> > > >  drivers/staging/sm750fb/sm750.h | 2 +-
> > > >  2 files changed, 3 insertions(+), 3 deletions(-)
> > > > 
> > > > diff --git a/drivers/staging/sm750fb/sm750.c b/drivers/staging/sm750fb/sm750.c
> > > > index 1d929aca399c..bb2ade6030c2 100644
> > > > --- a/drivers/staging/sm750fb/sm750.c
> > > > +++ b/drivers/staging/sm750fb/sm750.c
> > > > @@ -577,7 +577,7 @@ static int lynxfb_ops_blank(int blank, struct fb_info *info)
> > > >  	pr_debug("blank = %d.\n", blank);
> > > >  	par = info->par;
> > > >  	output = &par->output;
> > > > -	return output->proc_setBLANK(output, blank);
> > > > +	return output->proc_set_blank(output, blank);
> > > >  }
> > > >  
> > > >  static int sm750fb_set_drv(struct lynxfb_par *par)
> > > > @@ -605,7 +605,7 @@ static int sm750fb_set_drv(struct lynxfb_par *par)
> > > >  	crtc->ypanstep = 1;
> > > >  	crtc->ywrapstep = 0;
> > > >  
> > > > -	output->proc_setBLANK = (sm750_dev->revid == SM750LE_REVISION_ID) ?
> > > > +	output->proc_set_blank = (sm750_dev->revid == SM750LE_REVISION_ID) ?
> > > >  				 hw_sm750le_set_blank : hw_sm750_set_blank;
> > > 
> > > Why do we even need this function pointer?  Why not just do the check
> > > above when it is called instead of this indirection?
> > > 
> > > thanks,
> > > 
> > > greg k-h
> > 
> > Dear Greg,
> > 
> > Here is the updated patch with revised commit message. No code changes.
> 
> Please read the documentation for how to send an updated patch (hint, it
> needs to be a new version).
> 
> Also, see my comments above about what you should do here instead of
> just renaming the variable.  Please make that change which will remove
> the variable entirely.
> 
> thanks,
> 
> greg k-h

Thank you for feedback.

I was wondering if you could share additional feedback regarding
pros and cons calling a function directly based on the condition instead of the
current implementation?

Regards,
Kisub Choe.

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

* Re: [PATCH v2] staging: sm750fb: rename 'proc_setBLANK'
  2025-06-19 13:49       ` Kisub Choe
@ 2025-06-19 13:52         ` Greg KH
  2025-06-19 14:22           ` Kisub Choe
  0 siblings, 1 reply; 7+ messages in thread
From: Greg KH @ 2025-06-19 13:52 UTC (permalink / raw)
  To: Kisub Choe
  Cc: sudipm.mukherjee, teddy.wang, linux-fbdev, linux-staging,
	linux-kernel

On Thu, Jun 19, 2025 at 10:49:24PM +0900, Kisub Choe wrote:
> On Thu, Jun 19, 2025 at 03:24:26PM +0200, Greg KH wrote:
> > On Thu, Jun 19, 2025 at 10:12:13PM +0900, Kisub Choe wrote:
> > > On Wed, Jun 18, 2025 at 04:26:10PM +0200, Greg KH wrote:
> > > > On Wed, Jun 18, 2025 at 11:15:55PM +0900, Kisub Choe wrote:
> > > > > Rename 'proc_setBLANK' to 'proc_setBLANK' to
> > > > 
> > > > That doesn't rename anything :(
> > > Rename 'proc_setBLANK' to 'proc_set_blank' to
> > > > 
> > > > 
> > > > 
> > > > > conform with kernel style guidelines as reported by checkpatch.pl
> > > > > 
> > > > > CHECK: Avoid CamelCase: <proc_setBLANK>
> > > > > 
> > > > > Signed-off-by: Kisub Choe <kisub.choe.0x1@gmail.com>
> > > > > ---
> > > > >  drivers/staging/sm750fb/sm750.c | 4 ++--
> > > > >  drivers/staging/sm750fb/sm750.h | 2 +-
> > > > >  2 files changed, 3 insertions(+), 3 deletions(-)
> > > > > 
> > > > > diff --git a/drivers/staging/sm750fb/sm750.c b/drivers/staging/sm750fb/sm750.c
> > > > > index 1d929aca399c..bb2ade6030c2 100644
> > > > > --- a/drivers/staging/sm750fb/sm750.c
> > > > > +++ b/drivers/staging/sm750fb/sm750.c
> > > > > @@ -577,7 +577,7 @@ static int lynxfb_ops_blank(int blank, struct fb_info *info)
> > > > >  	pr_debug("blank = %d.\n", blank);
> > > > >  	par = info->par;
> > > > >  	output = &par->output;
> > > > > -	return output->proc_setBLANK(output, blank);
> > > > > +	return output->proc_set_blank(output, blank);
> > > > >  }
> > > > >  
> > > > >  static int sm750fb_set_drv(struct lynxfb_par *par)
> > > > > @@ -605,7 +605,7 @@ static int sm750fb_set_drv(struct lynxfb_par *par)
> > > > >  	crtc->ypanstep = 1;
> > > > >  	crtc->ywrapstep = 0;
> > > > >  
> > > > > -	output->proc_setBLANK = (sm750_dev->revid == SM750LE_REVISION_ID) ?
> > > > > +	output->proc_set_blank = (sm750_dev->revid == SM750LE_REVISION_ID) ?
> > > > >  				 hw_sm750le_set_blank : hw_sm750_set_blank;
> > > > 
> > > > Why do we even need this function pointer?  Why not just do the check
> > > > above when it is called instead of this indirection?
> > > > 
> > > > thanks,
> > > > 
> > > > greg k-h
> > > 
> > > Dear Greg,
> > > 
> > > Here is the updated patch with revised commit message. No code changes.
> > 
> > Please read the documentation for how to send an updated patch (hint, it
> > needs to be a new version).
> > 
> > Also, see my comments above about what you should do here instead of
> > just renaming the variable.  Please make that change which will remove
> > the variable entirely.
> > 
> > thanks,
> > 
> > greg k-h
> 
> Thank you for feedback.
> 
> I was wondering if you could share additional feedback regarding
> pros and cons calling a function directly based on the condition instead of the
> current implementation?

I'll leave that as an exercise for the reader to complete :)

have fun!

greg k-h

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

* Re: [PATCH v2] staging: sm750fb: rename 'proc_setBLANK'
  2025-06-19 13:52         ` Greg KH
@ 2025-06-19 14:22           ` Kisub Choe
  0 siblings, 0 replies; 7+ messages in thread
From: Kisub Choe @ 2025-06-19 14:22 UTC (permalink / raw)
  To: Greg KH
  Cc: Kisub Choe, sudipm.mukherjee, teddy.wang, linux-fbdev,
	linux-staging, linux-kernel

On Thu, Jun 19, 2025 at 03:52:53PM +0200, Greg KH wrote:
> On Thu, Jun 19, 2025 at 10:49:24PM +0900, Kisub Choe wrote:
> > On Thu, Jun 19, 2025 at 03:24:26PM +0200, Greg KH wrote:
> > > On Thu, Jun 19, 2025 at 10:12:13PM +0900, Kisub Choe wrote:
> > > > On Wed, Jun 18, 2025 at 04:26:10PM +0200, Greg KH wrote:
> > > > > On Wed, Jun 18, 2025 at 11:15:55PM +0900, Kisub Choe wrote:
> > > > > > Rename 'proc_setBLANK' to 'proc_setBLANK' to
> > > > > 
> > > > > That doesn't rename anything :(
> > > > Rename 'proc_setBLANK' to 'proc_set_blank' to
> > > > > 
> > > > > 
> > > > > 
> > > > > > conform with kernel style guidelines as reported by checkpatch.pl
> > > > > > 
> > > > > > CHECK: Avoid CamelCase: <proc_setBLANK>
> > > > > > 
> > > > > > Signed-off-by: Kisub Choe <kisub.choe.0x1@gmail.com>
> > > > > > ---
> > > > > >  drivers/staging/sm750fb/sm750.c | 4 ++--
> > > > > >  drivers/staging/sm750fb/sm750.h | 2 +-
> > > > > >  2 files changed, 3 insertions(+), 3 deletions(-)
> > > > > > 
> > > > > > diff --git a/drivers/staging/sm750fb/sm750.c b/drivers/staging/sm750fb/sm750.c
> > > > > > index 1d929aca399c..bb2ade6030c2 100644
> > > > > > --- a/drivers/staging/sm750fb/sm750.c
> > > > > > +++ b/drivers/staging/sm750fb/sm750.c
> > > > > > @@ -577,7 +577,7 @@ static int lynxfb_ops_blank(int blank, struct fb_info *info)
> > > > > >  	pr_debug("blank = %d.\n", blank);
> > > > > >  	par = info->par;
> > > > > >  	output = &par->output;
> > > > > > -	return output->proc_setBLANK(output, blank);
> > > > > > +	return output->proc_set_blank(output, blank);
> > > > > >  }
> > > > > >  
> > > > > >  static int sm750fb_set_drv(struct lynxfb_par *par)
> > > > > > @@ -605,7 +605,7 @@ static int sm750fb_set_drv(struct lynxfb_par *par)
> > > > > >  	crtc->ypanstep = 1;
> > > > > >  	crtc->ywrapstep = 0;
> > > > > >  
> > > > > > -	output->proc_setBLANK = (sm750_dev->revid == SM750LE_REVISION_ID) ?
> > > > > > +	output->proc_set_blank = (sm750_dev->revid == SM750LE_REVISION_ID) ?
> > > > > >  				 hw_sm750le_set_blank : hw_sm750_set_blank;
> > > > > 
> > > > > Why do we even need this function pointer?  Why not just do the check
> > > > > above when it is called instead of this indirection?
> > > > > 
> > > > > thanks,
> > > > > 
> > > > > greg k-h
> > > > 
> > > > Dear Greg,
> > > > 
> > > > Here is the updated patch with revised commit message. No code changes.
> > > 
> > > Please read the documentation for how to send an updated patch (hint, it
> > > needs to be a new version).
> > > 
> > > Also, see my comments above about what you should do here instead of
> > > just renaming the variable.  Please make that change which will remove
> > > the variable entirely.
> > > 
> > > thanks,
> > > 
> > > greg k-h
> > 
> > Thank you for feedback.
> > 
> > I was wondering if you could share additional feedback regarding
> > pros and cons calling a function directly based on the condition instead of the
> > current implementation?
> 
> I'll leave that as an exercise for the reader to complete :)
> 
> have fun!
> 
> greg k-h

Thank you!
Let me try to make changes and update.

Regards,
Kisub Choe.

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

end of thread, other threads:[~2025-06-19 14:22 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-06-18 14:15 [PATCH] staging: sm750fb: rename 'proc_setBLANK' Kisub Choe
2025-06-18 14:26 ` Greg KH
2025-06-19 13:12   ` [PATCH v2] " Kisub Choe
2025-06-19 13:24     ` Greg KH
2025-06-19 13:49       ` Kisub Choe
2025-06-19 13:52         ` Greg KH
2025-06-19 14:22           ` Kisub Choe

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).