Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1273694

[PATCH 3/4] spi: mediatek: remove needless pair of writel()/readl()

From Leilk Liu <leilk.liu@mediatek.com>
Newsgroups linux.kernel
Subject [PATCH 3/4] spi: mediatek: remove needless pair of writel()/readl()
Date 2015-11-20 03:30 +0100
Message-ID <qwJCy-10e-17@gated-at.bofh.it> (permalink)
References <qwJCx-10e-7@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


It's not need to re-read and re-write SPI_CMD_REG, so remove it.

Signed-off-by: Leilk Liu <leilk.liu@mediatek.com>
---
 drivers/spi/spi-mt65xx.c |    3 ---
 1 file changed, 3 deletions(-)

diff --git a/drivers/spi/spi-mt65xx.c b/drivers/spi/spi-mt65xx.c
index 7840067..6c1a96e 100644
--- a/drivers/spi/spi-mt65xx.c
+++ b/drivers/spi/spi-mt65xx.c
@@ -154,9 +154,6 @@ static int mtk_spi_prepare_message(struct spi_master *master,
 		reg_val |= SPI_CMD_CPOL;
 	else
 		reg_val &= ~SPI_CMD_CPOL;
-	writel(reg_val, mdata->base + SPI_CMD_REG);
-
-	reg_val = readl(mdata->base + SPI_CMD_REG);
 
 	/* set the mlsbx and mlsbtx */
 	if (chip_config->tx_mlsb)
-- 
1.7.9.5

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH 1/4] spi: mediatek: update document devicetree bindings to fix syntax error Leilk Liu <leilk.liu@mediatek.com> - 2015-11-20 03:30 +0100
  [PATCH 2/4] spi: mediatek: remove unrequired description Leilk Liu <leilk.liu@mediatek.com> - 2015-11-20 03:30 +0100
    Re: [PATCH 2/4] spi: mediatek: remove unrequired description Rob Herring <robh@kernel.org> - 2015-11-20 15:30 +0100
  [PATCH 3/4] spi: mediatek: remove needless pair of writel()/readl() Leilk Liu <leilk.liu@mediatek.com> - 2015-11-20 03:30 +0100
    Re: [PATCH 3/4] spi: mediatek: remove needless pair of  writel()/readl() Matthias Brugger <matthias.bgg@gmail.com> - 2015-11-20 18:00 +0100
  Re: [PATCH 1/4] spi: mediatek: update document devicetree bindings  to fix syntax error Rob Herring <robh@kernel.org> - 2015-11-20 15:20 +0100

csiph-web