diff mbox series

[1/2] staging: sm750fb: rename dprBase to dpr_base

Message ID d4b30e00ca64a233efc2a7dac4bc568186dafc71.1747605658.git.ericflorin@google.com
State New
Headers show
Series staging: sm750fb: style cleanup in `lynx_accel` | expand

Commit Message

Eric Florin May 18, 2025, 10:09 p.m. UTC
Rename `dprBase` to `dpr_base` to conform with kernel style guidelines
as reported by checkpatch.pl

CHECK: Avoid CamelCase: <dprBase>

Signed-off-by: Eric Florin <ericflorin@google.com>
---
 drivers/staging/sm750fb/sm750.h       | 2 +-
 drivers/staging/sm750fb/sm750_accel.c | 4 ++--
 drivers/staging/sm750fb/sm750_hw.c    | 2 +-
 3 files changed, 4 insertions(+), 4 deletions(-)

Comments

Greg Kroah-Hartman May 21, 2025, 11:47 a.m. UTC | #1
On Sun, May 18, 2025 at 03:09:46PM -0700, Eric Florin wrote:
> Rename `dprBase` to `dpr_base` to conform with kernel style guidelines
> as reported by checkpatch.pl
> 
> CHECK: Avoid CamelCase: <dprBase>
> 
> Signed-off-by: Eric Florin <ericflorin@google.com>
> ---
>  drivers/staging/sm750fb/sm750.h       | 2 +-
>  drivers/staging/sm750fb/sm750_accel.c | 4 ++--
>  drivers/staging/sm750fb/sm750_hw.c    | 2 +-
>  3 files changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/staging/sm750fb/sm750.h b/drivers/staging/sm750fb/sm750.h
> index aff69661c8e6..a2342c69a65a 100644
> --- a/drivers/staging/sm750fb/sm750.h
> +++ b/drivers/staging/sm750fb/sm750.h
> @@ -50,7 +50,7 @@ struct init_status {
>  
>  struct lynx_accel {
>  	/* base virtual address of DPR registers */
> -	volatile unsigned char __iomem *dprBase;
> +	volatile unsigned char __iomem *dpr_base;

Are you sure this isn't coming directly from a hardware data sheet or
description somewhere?  Based on the type, it really looks like it is.
If not, please document it properly that you have researched this in the
changelog text when resending.

Don't change variable names that reflect external names, that just makes
for more confusion over time.

thanks,

greg k-h
diff mbox series

Patch

diff --git a/drivers/staging/sm750fb/sm750.h b/drivers/staging/sm750fb/sm750.h
index aff69661c8e6..a2342c69a65a 100644
--- a/drivers/staging/sm750fb/sm750.h
+++ b/drivers/staging/sm750fb/sm750.h
@@ -50,7 +50,7 @@  struct init_status {
 
 struct lynx_accel {
 	/* base virtual address of DPR registers */
-	volatile unsigned char __iomem *dprBase;
+	volatile unsigned char __iomem *dpr_base;
 	/* base virtual address of de data port */
 	volatile unsigned char __iomem *dpPortBase;
 
diff --git a/drivers/staging/sm750fb/sm750_accel.c b/drivers/staging/sm750fb/sm750_accel.c
index 44b9e3fe3a41..97791f1b0123 100644
--- a/drivers/staging/sm750fb/sm750_accel.c
+++ b/drivers/staging/sm750fb/sm750_accel.c
@@ -19,12 +19,12 @@ 
 #include "sm750_accel.h"
 static inline void write_dpr(struct lynx_accel *accel, int offset, u32 regValue)
 {
-	writel(regValue, accel->dprBase + offset);
+	writel(regValue, accel->dpr_base + offset);
 }
 
 static inline u32 read_dpr(struct lynx_accel *accel, int offset)
 {
-	return readl(accel->dprBase + offset);
+	return readl(accel->dpr_base + offset);
 }
 
 static inline void write_dpPort(struct lynx_accel *accel, u32 data)
diff --git a/drivers/staging/sm750fb/sm750_hw.c b/drivers/staging/sm750fb/sm750_hw.c
index 64b199061d14..159a5ad621f2 100644
--- a/drivers/staging/sm750fb/sm750_hw.c
+++ b/drivers/staging/sm750fb/sm750_hw.c
@@ -58,7 +58,7 @@  int hw_sm750_map(struct sm750_dev *sm750_dev, struct pci_dev *pdev)
 	}
 	pr_info("mmio virtual addr = %p\n", sm750_dev->pvReg);
 
-	sm750_dev->accel.dprBase = sm750_dev->pvReg + DE_BASE_ADDR_TYPE1;
+	sm750_dev->accel.dpr_base = sm750_dev->pvReg + DE_BASE_ADDR_TYPE1;
 	sm750_dev->accel.dpPortBase = sm750_dev->pvReg + DE_PORT_ADDR_TYPE1;
 
 	mmio750 = sm750_dev->pvReg;