Skip to contentSkip to conversation

Remove an unused variable from the Intel I/OAT DMA engine driver

PATCH Applied Jesper Juhl 3 participants 3 messages Sep 16, 2007 – Sep 17, 2007

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

PATCH 1/1 Remove an unused variable from the Intel I/OAT DMA engine driver

The 'u16 chanctrl' variable in drivers/dma/ioatdma.c::ioat_dma_free_chan_resources() is completely unused and gcc quite rightfully warns about it:

drivers/dma/ioatdma.c:247: warning: unused variable 'chanctrl'

This patch removes the unused variable and silences the warning.

---

 ioatdma.c |    1 -
 1 file changed, 1 deletion(-)
drivers/dma/ioatdma.c renamed from drivers/dma/ioatdma.c~ +0 -1
@@ -244,7 +244,6 @@ static void ioat_dma_free_chan_resources
 	struct ioat_dma_chan *ioat_chan = to_ioat_chan(chan);
 	struct ioat_device *ioat_device = to_ioat_device(chan->device);
 	struct ioat_desc_sw *desc, *_desc;
-	u16 chanctrl;
 	int in_use_descs = 0;
 
 	ioat_dma_memcpy_cleanup(ioat_chan);
Applied
#1 lore raw

From: Jesper Juhl <[email protected]>
Date: Sun, 16 Sep 2007 23:31:50 +0200

Quoted 11 lines

The 'u16 chanctrl' variable in drivers/dma/ioatdma.c::ioat_dma_free_chan_resources() is completely unused and gcc quite rightfully warns about it:

drivers/dma/ioatdma.c:247: warning: unused variable 'chanctrl'

This patch removes the unused variable and silences the warning.

Applied to net-2.6.24, thanks Jesper.

#2 lore raw
In reply to Jesper Juhl
Quoted 32 lines

-----Original Message-----
From: Jesper Juhl [mailto:[email protected]]
Sent: Sunday, September 16, 2007 2:32 PM
To: [email protected]
Cc: Nelson, Shannon; Leech, Christopher; Jesper Juhl
Subject: [PATCH] Remove an unused variable from the Intel I/OAT DMA engine driver

The 'u16 chanctrl' variable in drivers/dma/ioatdma.c::ioat_dma_free_chan_resources() is completely unused and gcc quite rightfully warns about it:

drivers/dma/ioatdma.c:247: warning: unused variable 'chanctrl'

This patch removes the unused variable and silences the warning.

---

ioatdma.c | 1 -

1 file changed, 1 deletion(-)

--- linux-2.6/drivers/dma/ioatdma.c~ 2007-09-16
23:24:20.000000000 +0200
+++ linux-2.6/drivers/dma/ioatdma.c 2007-09-16
23:24:20.000000000 +0200

drivers/dma/ioatdma.c static void ioat_dma_free_chan_resources · line 249

Quoted 7 lines
drivers/dma/ioatdma.c renamed from drivers/dma/ioatdma.c~ +0 -1
@@ -244,7 +244,6 @@ static void ioat_dma_free_chan_resources
 	struct ioat_dma_chan *ioat_chan = to_ioat_chan(chan);
 	struct ioat_device *ioat_device = to_ioat_device(chan->device);
 	struct ioat_desc_sw *desc, *_desc;
-	u16 chanctrl;
 	int in_use_descs = 0;
 
 	ioat_dma_memcpy_cleanup(ioat_chan);

Yep, thanks. That's actually used in an internal version of the driver and got missed in the stipping. I'll be sure it is properly taken care of in the future.