Skip to contentSkip to conversation

Macro Ordering and Typo Correction

PATCH Superseded Devendra K Verma 3 participants 9 messages Sep 7 – Sep 17

Subsystems (3)

v1 of 3 Superseded Latest is v3 →

lore
Share & tools
lore
#0 lore raw

cover Macro Ordering and Typo Correction

These are minor and cosmetic changes.

o If the macros declaring the bit positions of a register are in order then it provides a good view. Corrected the ordering for once such register.
o Corrected the typo under the IP related data struct to have the correct name under respective IP structs.

Previous reviewed-by tags were part of the following review:

https://lore.kernel.org/all/aoW7vxy2lpXEbmRq@SMW015318/
https://lore.kernel.org/all/dx5jvko7ygrqugzkt3k74l3d7lk7iauikmxrzuhvn2b4bdv5ub@s2l6zl3alx3z/#t

Devendra K Verma (2):
dmaengine: dw-edma: Macro order as per reg bit position
dmaengine: dw-edma: IP name corrected under its struct

 drivers/dma/dw-edma/dw-edma-pcie.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
Signature · 1 line
2.43.0
#1 lore raw

PATCH 1/2 dmaengine: dw-edma: Macro order as per reg bit position

For a register the macros providing masks for bit ranges. These macros if placed in order provide good view of the bits. Placed macros in ascending order.

---
 drivers/dma/dw-edma/dw-edma-pcie.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/dma/dw-edma/dw-edma-pcie.c +1 -1
index 9f237ba916de..006dea7d6322 100644
@@ -31,8 +31,8 @@
 
 #define DW_PCIE_XILINX_MDB_VSEC_DMA_ID		0x6
 #define DW_PCIE_XILINX_MDB_VSEC_ID		0x20
-#define DW_PCIE_XILINX_MDB_VSEC_DMA_BAR		GENMASK(10, 8)
 #define DW_PCIE_XILINX_MDB_VSEC_DMA_MAP		GENMASK(2, 0)
+#define DW_PCIE_XILINX_MDB_VSEC_DMA_BAR		GENMASK(10, 8)
 #define DW_PCIE_XILINX_MDB_VSEC_DMA_WR_CH	GENMASK(9, 0)
 #define DW_PCIE_XILINX_MDB_VSEC_DMA_RD_CH	GENMASK(25, 16)
 
Signature · 1 line
2.43.0
#2 lore raw

Re: [PATCH v1 1/2] dmaengine: dw-edma: Macro order as per reg bit position

Sashiko has reviewed this patch and found no issues. It looks great!
Quoted 5 lines

For a register the macros providing masks for bit ranges. These macros if placed in order provide good view of the bits. Placed macros in ascending order.

Sashiko has reviewed this patch and found no issues. It looks great!

Signature · 1 line
Sashiko AI review · https://sashiko.dev/#/patchset/[email protected]?part=1
#3 lore raw

Re: [PATCH v1 1/2] dmaengine: dw-edma: Macro order as per reg bit position

In reply to Devendra K Verma
Quoted 3 lines · Devendra K Verma

For a register the macros providing masks for bit ranges. These macros if placed in order provide good view of the bits. Placed macros in ascending order.

dmaengine: dw-edma: sort register field macros by bit position

Sort register field macros by bit position to improve readability.

No functional change intended.

Frank

Quoted 23 lines
---
 drivers/dma/dw-edma/dw-edma-pcie.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/dma/dw-edma/dw-edma-pcie.c +1 -2
index 9f237ba916de..006dea7d6322 100644
@@ -31,8 +31,8 @@
 
 #define DW_PCIE_XILINX_MDB_VSEC_DMA_ID		0x6
 #define DW_PCIE_XILINX_MDB_VSEC_ID		0x20
-#define DW_PCIE_XILINX_MDB_VSEC_DMA_BAR		GENMASK(10, 8)
 #define DW_PCIE_XILINX_MDB_VSEC_DMA_MAP		GENMASK(2, 0)
+#define DW_PCIE_XILINX_MDB_VSEC_DMA_BAR		GENMASK(10, 8)
 #define DW_PCIE_XILINX_MDB_VSEC_DMA_WR_CH	GENMASK(9, 0)
 #define DW_PCIE_XILINX_MDB_VSEC_DMA_RD_CH	GENMASK(25, 16)
 
--

2.43.0

#4 lore raw

PATCH 2/2 dmaengine: dw-edma: IP name corrected under its struct

In reply to Devendra K Verma

For 'xilinx_cpm6_dma_data' struct which is CPM6 IP, the comment under this struct has typo and mentiones 'MDB' registers when it shall be 'CPM6' regisers.

---
 drivers/dma/dw-edma/dw-edma-pcie.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/dma/dw-edma/dw-edma-pcie.c +1 -1
index 006dea7d6322..762a693ab55b 100644
@@ -146,7 +146,7 @@ static const struct dw_edma_pcie_data xilinx_mdb_data = {
 };
 
 static const struct dw_edma_pcie_data xilinx_cpm6_dma_data = {
-	/* MDB registers location */
+	/* CPM6 registers location */
 	.rg.bar				= BAR_0,
 	.rg.off				= SZ_4K,	/*  4 Kbytes */
 	.rg.sz				= SZ_8K,	/*  8 Kbytes */
Signature · 1 line
2.43.0
#5 lore raw

Re: [PATCH v1 2/2] dmaengine: dw-edma: IP name corrected under its struct

Sashiko has reviewed this patch and found no issues. It looks great!
Quoted 5 lines

For 'xilinx_cpm6_dma_data' struct which is CPM6 IP, the comment under this struct has typo and mentiones 'MDB' registers when it shall be 'CPM6' regisers.

Sashiko has reviewed this patch and found no issues. It looks great!

Signature · 1 line
Sashiko AI review · https://sashiko.dev/#/patchset/[email protected]?part=2
#6 lore raw

Re: [PATCH v1 2/2] dmaengine: dw-edma: IP name corrected under its struct

In reply to Devendra K Verma
Quoted 6 lines · Devendra K Verma

For 'xilinx_cpm6_dma_data' struct which is CPM6 IP, the comment under this struct has typo and mentiones 'MDB' registers when it shall be 'CPM6' regisers.

---

dmaengine: dw-edma: correct IP name in xilinx_cpm6_dma_data comment

Replace 'MDB' with 'CPM6' in the xilinx_cpm6_dma_data comment to fix the IP name typo.

Frank

Quoted 19 lines
 drivers/dma/dw-edma/dw-edma-pcie.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/dma/dw-edma/dw-edma-pcie.c +1 -2
index 006dea7d6322..762a693ab55b 100644
@@ -146,7 +146,7 @@ static const struct dw_edma_pcie_data xilinx_mdb_data = {
 };
 
 static const struct dw_edma_pcie_data xilinx_cpm6_dma_data = {
-	/* MDB registers location */
+	/* CPM6 registers location */
 	.rg.bar				= BAR_0,
 	.rg.off				= SZ_4K,	/*  4 Kbytes */
 	.rg.sz				= SZ_8K,	/*  8 Kbytes */
--

2.43.0

#7 lore raw

Re: [PATCH v1 2/2] dmaengine: dw-edma: IP name corrected under its struct

Quoted 5 lines · Frank Li
Quoted 4 lines · Devendra K Verma

For 'xilinx_cpm6_dma_data' struct which is CPM6 IP, the comment under this struct has typo and mentiones 'MDB' registers when it shall be 'CPM6' regisers.

Quoted 8 lines
Quoted 2 lines

---

dmaengine: dw-edma: correct IP name in xilinx_cpm6_dma_data comment

Replace 'MDB' with 'CPM6' in the xilinx_cpm6_dma_data comment to fix the IP name typo.

Thanks Frank for the suggestion!
Please check the v2 of the same series with updated titles.

-Devendra

Quoted 21 lines

Frank

Quoted 19 lines
  drivers/dma/dw-edma/dw-edma-pcie.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
drivers/dma/dw-edma/dw-edma-pcie.c +1 -2
index 006dea7d6322..762a693ab55b 100644
@@ -146,7 +146,7 @@ static const struct dw_edma_pcie_data xilinx_mdb_data = {
  };
 
  static const struct dw_edma_pcie_data xilinx_cpm6_dma_data = {
-	/* MDB registers location */
+	/* CPM6 registers location */
  	.rg.bar				= BAR_0,
  	.rg.off				= SZ_4K,	/*  4 Kbytes */
  	.rg.sz				= SZ_8K,	/*  8 Kbytes */
--

2.43.0

#8 lore raw

Re: [PATCH v1 2/2] dmaengine: dw-edma: IP name corrected under its struct

In reply to Frank Li
Quoted 5 lines · Frank Li
Quoted 4 lines · Devendra K Verma

For 'xilinx_cpm6_dma_data' struct which is CPM6 IP, the comment under this struct has typo and mentiones 'MDB' registers when it shall be 'CPM6' regisers.

Quoted 8 lines
Quoted 2 lines

---

dmaengine: dw-edma: correct IP name in xilinx_cpm6_dma_data comment

Replace 'MDB' with 'CPM6' in the xilinx_cpm6_dma_data comment to fix the IP name typo.

Thank you for the suggestion. Please check the v2 of the same patch series.

-Devendra

Quoted 21 lines

Frank

Quoted 19 lines
  drivers/dma/dw-edma/dw-edma-pcie.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
drivers/dma/dw-edma/dw-edma-pcie.c +1 -2
index 006dea7d6322..762a693ab55b 100644
@@ -146,7 +146,7 @@ static const struct dw_edma_pcie_data xilinx_mdb_data = {
  };
 
  static const struct dw_edma_pcie_data xilinx_cpm6_dma_data = {
-	/* MDB registers location */
+	/* CPM6 registers location */
  	.rg.bar				= BAR_0,
  	.rg.off				= SZ_4K,	/*  4 Kbytes */
  	.rg.sz				= SZ_8K,	/*  8 Kbytes */
--

2.43.0