Skip to contentSkip to conversation

spi: omap-100k: Remove unused pointer in omap1_spi100k_txrx_pio()

PATCH Applied Christian Engelmayer 4 participants 4 messages Feb 8, 2014 – Feb 10, 2014 SPI

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 spi: omap-100k: Remove unused pointer in omap1_spi100k_txrx_pio()

Remove unused devdata pointer 'spi100k' in function omap1_spi100k_txrx_pio().

Detected by Coverity: CID 1077869.

---
Applies against v3.14-rc1 as well as branch for-next in tree git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git

---
 drivers/spi/spi-omap-100k.c | 2 --
 1 file changed, 2 deletions(-)
drivers/spi/spi-omap-100k.c +0 -2
index 0d32054..8eaf0cd 100644
@@ -204,12 +204,10 @@ static void omap1_spi100k_force_cs(struct omap1_spi100k *spi100k, int enable)
 static unsigned
 omap1_spi100k_txrx_pio(struct spi_device *spi, struct spi_transfer *xfer)
 {
-	struct omap1_spi100k    *spi100k;
 	struct omap1_spi100k_cs *cs = spi->controller_state;
 	unsigned int            count, c;
 	int                     word_len;
 
-	spi100k = spi_master_get_devdata(spi->master);
 	count = xfer->len;
 	c = count;
 	word_len = cs->word_len;
Signature · 1 line
1.8.3.2
Reviewed-by on v1 1/1
#1 lore raw
Quoted 6 lines · Christian Engelmayer

Remove unused devdata pointer 'spi100k' in function omap1_spi100k_txrx_pio().

Detected by Coverity: CID 1077869.

Best regards,
Jingoo Han

Quoted 25 lines

---
Applies against v3.14-rc1 as well as branch for-next in tree git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git

---
 drivers/spi/spi-omap-100k.c | 2 --
 1 file changed, 2 deletions(-)
drivers/spi/spi-omap-100k.c +0 -3
index 0d32054..8eaf0cd 100644
@@ -204,12 +204,10 @@ static void omap1_spi100k_force_cs(struct omap1_spi100k *spi100k, int enable)
 static unsigned
 omap1_spi100k_txrx_pio(struct spi_device *spi, struct spi_transfer *xfer)
 {
-	struct omap1_spi100k    *spi100k;
 	struct omap1_spi100k_cs *cs = spi->controller_state;
 	unsigned int            count, c;
 	int                     word_len;
 
-	spi100k = spi_master_get_devdata(spi->master);
 	count = xfer->len;
 	c = count;
 	word_len = cs->word_len;
--
Quoted 1 line

1.8.3.2

--
To unsubscribe from this list: send the line "unsubscribe linux-spi" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

Acked-by on v1 1/1
#2 lore raw
In reply to Christian Engelmayer
Quoted 5 lines · Christian Engelmayer

Remove unused devdata pointer 'spi100k' in function omap1_spi100k_txrx_pio().

Detected by Coverity: CID 1077869.

Quoted 26 lines

---
Applies against v3.14-rc1 as well as branch for-next in tree git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git

---
 drivers/spi/spi-omap-100k.c | 2 --
 1 file changed, 2 deletions(-)
drivers/spi/spi-omap-100k.c +0 -2
index 0d32054..8eaf0cd 100644
@@ -204,12 +204,10 @@ static void omap1_spi100k_force_cs(struct omap1_spi100k *spi100k, int enable)
 static unsigned
 omap1_spi100k_txrx_pio(struct spi_device *spi, struct spi_transfer *xfer)
 {
-	struct omap1_spi100k    *spi100k;
 	struct omap1_spi100k_cs *cs = spi->controller_state;
 	unsigned int            count, c;
 	int                     word_len;
 
-	spi100k = spi_master_get_devdata(spi->master);
 	count = xfer->len;
 	c = count;
 	word_len = cs->word_len;
Signature · 1 line
1.8.3.2
Signature · 4 lines
Best regards,                                         _     _
.o. | Liege of Serenely Enlightened Majesty of      o' \,=./ `o
..o | Computer Science,  Michał “mina86” Nazarewicz    (o o)
ooo +--<[email protected]>--<xmpp:mina86-/[email protected]>--ooO--(_)--Ooo--