public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 0/2] Style fixes for EDAC/bluefield driver
@ 2024-06-13  4:59 David Thompson
  2024-06-13  4:59 ` [PATCH v2 1/2] EDAC/bluefield: fix white space in bluefield_edac_mc_probe David Thompson
  2024-06-13  4:59 ` [PATCH v2 2/2] EDAC/bluefield: fix prefix for GET_DIMM_INFO defines David Thompson
  0 siblings, 2 replies; 4+ messages in thread
From: David Thompson @ 2024-06-13  4:59 UTC (permalink / raw)
  To: bp, tony.luck, james.morse, mchehab, rric
  Cc: shravankr, linux-edac, linux-kernel, David Thompson

The bluefield_edac driver needs two coding style fixes: one fix
addresses an issue raised by checkpatch, and the other fix
provides consistency in declaration of #defines.

David Thompson (2):
  EDAC/bluefield: fix white space in bluefield_edac_mc_probe
  EDAC/bluefield: fix prefix for GET_DIMM_INFO defines

 drivers/edac/bluefield_edac.c | 9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)

-- 
2.30.1


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

* [PATCH v2 1/2] EDAC/bluefield: fix white space in bluefield_edac_mc_probe
  2024-06-13  4:59 [PATCH v2 0/2] Style fixes for EDAC/bluefield driver David Thompson
@ 2024-06-13  4:59 ` David Thompson
  2024-06-13  7:51   ` Borislav Petkov
  2024-06-13  4:59 ` [PATCH v2 2/2] EDAC/bluefield: fix prefix for GET_DIMM_INFO defines David Thompson
  1 sibling, 1 reply; 4+ messages in thread
From: David Thompson @ 2024-06-13  4:59 UTC (permalink / raw)
  To: bp, tony.luck, james.morse, mchehab, rric
  Cc: shravankr, linux-edac, linux-kernel, David Thompson

The routine bluefield_edac_mc_probe() has an extra empty line,
so it must be removed.  This extra line is flagged when running
"scripts/checkpatch --strict":
  CHECK: Blank lines aren't necessary before a close brace '}'
  #324: FILE: drivers/edac/bluefield_edac.c:324:
  +
  +}

Signed-off-by: David Thompson <davthompson@nvidia.com>
Reviewed-by: Shravan Kumar Ramani <shravankr@nvidia.com>
---
v2
- Updated commit message per review comments
---
 drivers/edac/bluefield_edac.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/edac/bluefield_edac.c b/drivers/edac/bluefield_edac.c
index 5b3164560648..1f6f39a7dbf3 100644
--- a/drivers/edac/bluefield_edac.c
+++ b/drivers/edac/bluefield_edac.c
@@ -320,7 +320,6 @@ static int bluefield_edac_mc_probe(struct platform_device *pdev)
 	edac_mc_free(mci);
 
 	return ret;
-
 }
 
 static void bluefield_edac_mc_remove(struct platform_device *pdev)
-- 
2.30.1


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

* [PATCH v2 2/2] EDAC/bluefield: fix prefix for GET_DIMM_INFO defines
  2024-06-13  4:59 [PATCH v2 0/2] Style fixes for EDAC/bluefield driver David Thompson
  2024-06-13  4:59 ` [PATCH v2 1/2] EDAC/bluefield: fix white space in bluefield_edac_mc_probe David Thompson
@ 2024-06-13  4:59 ` David Thompson
  1 sibling, 0 replies; 4+ messages in thread
From: David Thompson @ 2024-06-13  4:59 UTC (permalink / raw)
  To: bp, tony.luck, james.morse, mchehab, rric
  Cc: shravankr, linux-edac, linux-kernel, David Thompson

The GET_DIMM_INFO defines used by the driver have an "MLNX_" prefix.
This prefix does not align with the other #defines in the driver,
which use an "MLXBF_" prefix.  The driver must be consistent in its
prefix usage, so align them to use "MLXBF_" prefix.

Signed-off-by: David Thompson <davthompson@nvidia.com>
Reviewed-by: Shravan Kumar Ramani <shravankr@nvidia.com>
---
v2
- Updated commit message per review comments
---
 drivers/edac/bluefield_edac.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/edac/bluefield_edac.c b/drivers/edac/bluefield_edac.c
index 1f6f39a7dbf3..8f1cc029606f 100644
--- a/drivers/edac/bluefield_edac.c
+++ b/drivers/edac/bluefield_edac.c
@@ -48,12 +48,12 @@
 #define MLXBF_EDAC_ERROR_GRAIN		8
 
 /*
- * Request MLNX_SIP_GET_DIMM_INFO
+ * Request MLXBF_SIP_GET_DIMM_INFO
  *
  * Retrieve information about DIMM on a certain slot.
  *
  * Call register usage:
- * a0: MLNX_SIP_GET_DIMM_INFO
+ * a0: MLXBF_SIP_GET_DIMM_INFO
  * a1: (Memory controller index) << 16 | (Dimm index in memory controller)
  * a2-7: not used.
  *
@@ -61,7 +61,7 @@
  * a0: MLXBF_DIMM_INFO defined below describing the DIMM.
  * a1-3: not used.
  */
-#define MLNX_SIP_GET_DIMM_INFO		0x82000008
+#define MLXBF_SIP_GET_DIMM_INFO		0x82000008
 
 /* Format for the SMC response about the memory information */
 #define MLXBF_DIMM_INFO__SIZE_GB GENMASK_ULL(15, 0)
@@ -189,7 +189,7 @@ static void bluefield_edac_init_dimms(struct mem_ctl_info *mci)
 		dimm = mci->dimms[i];
 
 		smc_arg = mem_ctrl_idx << 16 | i;
-		smc_info = smc_call1(MLNX_SIP_GET_DIMM_INFO, smc_arg);
+		smc_info = smc_call1(MLXBF_SIP_GET_DIMM_INFO, smc_arg);
 
 		if (!FIELD_GET(MLXBF_DIMM_INFO__SIZE_GB, smc_info)) {
 			dimm->mtype = MEM_EMPTY;
-- 
2.30.1


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

* Re: [PATCH v2 1/2] EDAC/bluefield: fix white space in bluefield_edac_mc_probe
  2024-06-13  4:59 ` [PATCH v2 1/2] EDAC/bluefield: fix white space in bluefield_edac_mc_probe David Thompson
@ 2024-06-13  7:51   ` Borislav Petkov
  0 siblings, 0 replies; 4+ messages in thread
From: Borislav Petkov @ 2024-06-13  7:51 UTC (permalink / raw)
  To: David Thompson
  Cc: tony.luck, james.morse, mchehab, rric, shravankr, linux-edac,
	linux-kernel

On Thu, Jun 13, 2024 at 12:59:01AM -0400, David Thompson wrote:
> The routine bluefield_edac_mc_probe() has an extra empty line,
> so it must be removed.  This extra line is flagged when running
> "scripts/checkpatch --strict":
>   CHECK: Blank lines aren't necessary before a close brace '}'
>   #324: FILE: drivers/edac/bluefield_edac.c:324:
>   +
>   +}
> 
> Signed-off-by: David Thompson <davthompson@nvidia.com>
> Reviewed-by: Shravan Kumar Ramani <shravankr@nvidia.com>
> ---
> v2
> - Updated commit message per review comments
> ---
>  drivers/edac/bluefield_edac.c | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/drivers/edac/bluefield_edac.c b/drivers/edac/bluefield_edac.c
> index 5b3164560648..1f6f39a7dbf3 100644
> --- a/drivers/edac/bluefield_edac.c
> +++ b/drivers/edac/bluefield_edac.c
> @@ -320,7 +320,6 @@ static int bluefield_edac_mc_probe(struct platform_device *pdev)
>  	edac_mc_free(mci);
>  
>  	return ret;
> -
>  }
>  
>  static void bluefield_edac_mc_remove(struct platform_device *pdev)
> -- 

Did you get my reply to this and did you read it?

https://lore.kernel.org/r/20240612200056.GGZmn-eO15ePolbAPo@fat_crate.local

-- 
Regards/Gruss,
    Boris.

https://people.kernel.org/tglx/notes-about-netiquette

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

end of thread, other threads:[~2024-06-13  7:51 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-06-13  4:59 [PATCH v2 0/2] Style fixes for EDAC/bluefield driver David Thompson
2024-06-13  4:59 ` [PATCH v2 1/2] EDAC/bluefield: fix white space in bluefield_edac_mc_probe David Thompson
2024-06-13  7:51   ` Borislav Petkov
2024-06-13  4:59 ` [PATCH v2 2/2] EDAC/bluefield: fix prefix for GET_DIMM_INFO defines David Thompson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox