Skip to contentSkip to conversation

dmaengine: ioatdma: remove unused function missed during dma_v2 removal

PATCH Applied Lukas Bulwahn 3 participants 3 messages Nov 13, 2020 – Nov 16, 2020

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 dmaengine: ioatdma: remove unused function missed during dma_v2 removal

Commit 7f832645d0e5 ("dmaengine: ioatdma: remove ioatdma v2 registration") missed to remove dca2_tag_map_valid() during its removal. Hence, since then, dca2_tag_map_valid() is unused and make CC=clang W=1 warns:

drivers/dma/ioat/dca.c:44:19:
warning: unused function 'dca2_tag_map_valid' [-Wunused-function]

So, remove this unused function and get rid of a -Wused-function warning.

---
applies cleanly on current master and next-20201112

Maciej, please ack.

Vinod, Dan, please pick this minor non-urgent clean-up patch.

 drivers/dma/ioat/dca.c | 10 ----------
 1 file changed, 10 deletions(-)
drivers/dma/ioat/dca.c +0 -10
index 0be385587c4c..289c59ed74b9 100644
@@ -40,16 +40,6 @@
 #define DCA2_TAG_MAP_BYTE3 0x82
 #define DCA2_TAG_MAP_BYTE4 0x82
 
-/* verify if tag map matches expected values */
-static inline int dca2_tag_map_valid(u8 *tag_map)
-{
-	return ((tag_map[0] = DCA2_TAG_MAP_BYTE0) &&
-		(tag_map[1] = DCA2_TAG_MAP_BYTE1) &&
-		(tag_map[2] = DCA2_TAG_MAP_BYTE2) &&
-		(tag_map[3] = DCA2_TAG_MAP_BYTE3) &&
-		(tag_map[4] = DCA2_TAG_MAP_BYTE4));
-}
-
 /*
  * "Legacy" DCA systems do not implement the DCA register set in the
  * I/OAT device.  Software needs direct support for their tag mappings.
Signature · 1 line
2.17.1
Reviewed-by on v1 1/1
#1 lore raw
Quoted 10 lines · Lukas Bulwahn

Commit 7f832645d0e5 ("dmaengine: ioatdma: remove ioatdma v2 registration") missed to remove dca2_tag_map_valid() during its removal. Hence, since then, dca2_tag_map_valid() is unused and make CC=clang W=1 warns:

drivers/dma/ioat/dca.c:44:19:
warning: unused function 'dca2_tag_map_valid' [-Wunused-function]

So, remove this unused function and get rid of a -Wused-function warning.

Quoted 34 lines

---
applies cleanly on current master and next-20201112

Maciej, please ack.

Vinod, Dan, please pick this minor non-urgent clean-up patch.

 drivers/dma/ioat/dca.c | 10 ----------
 1 file changed, 10 deletions(-)
drivers/dma/ioat/dca.c +0 -10
index 0be385587c4c..289c59ed74b9 100644
@@ -40,16 +40,6 @@
 #define DCA2_TAG_MAP_BYTE3 0x82
 #define DCA2_TAG_MAP_BYTE4 0x82
 
-/* verify if tag map matches expected values */
-static inline int dca2_tag_map_valid(u8 *tag_map)
-{
-	return ((tag_map[0] = DCA2_TAG_MAP_BYTE0) &&
-		(tag_map[1] = DCA2_TAG_MAP_BYTE1) &&
-		(tag_map[2] = DCA2_TAG_MAP_BYTE2) &&
-		(tag_map[3] = DCA2_TAG_MAP_BYTE3) &&
-		(tag_map[4] = DCA2_TAG_MAP_BYTE4));
-}
-
 /*
  * "Legacy" DCA systems do not implement the DCA register set in the
  * I/OAT device.  Software needs direct support for their tag mappings.
Signature · 1 line
2.17.1
maintainer Applied
#2 lore raw
In reply to Lukas Bulwahn
Quoted 8 lines · Lukas Bulwahn

Commit 7f832645d0e5 ("dmaengine: ioatdma: remove ioatdma v2 registration") missed to remove dca2_tag_map_valid() during its removal. Hence, since then, dca2_tag_map_valid() is unused and make CC=clang W=1 warns:

drivers/dma/ioat/dca.c:44:19:
warning: unused function 'dca2_tag_map_valid' [-Wunused-function]

So, remove this unused function and get rid of a -Wused-function warning.

Applied, thanks

Signature · 1 line
~Vinod