Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 31804f63 authored by Jingoo Han's avatar Jingoo Han Committed by Mark Brown
Browse files

spi: omap-100k: fix spacing coding style issue



Fix the following checkpatch issues.

  ERROR: space prohibited after that open parenthesis '('
  ERROR: space required before the open parenthesis '('
  ERROR: trailing statements should be on next line
  ERROR: space required after that ',' (ctx:VxV)
  ERROR: spaces required around that '-=' (ctx:VxV)
  WARNING: sizeof *cs should be sizeof(*cs)

Signed-off-by: default avatarJingoo Han <jg1.han@samsung.com>
Signed-off-by: default avatarMark Brown <broonie@linaro.org>
parent 79c2f49a
Loading
Loading
Loading
Loading
+19 −17
Original line number Original line Diff line number Diff line
@@ -136,7 +136,8 @@ static void spi100k_write_data(struct spi_master *master, int len, int data)
	       spi100k->base + SPI_CTRL);
	       spi100k->base + SPI_CTRL);


	/* Wait for bit ack send change */
	/* Wait for bit ack send change */
	while((readw(spi100k->base + SPI_STATUS) & SPI_STATUS_WE) != SPI_STATUS_WE);
	while ((readw(spi100k->base + SPI_STATUS) & SPI_STATUS_WE) != SPI_STATUS_WE)
		;
	udelay(1000);
	udelay(1000);


	spi100k_disable_clock(master);
	spi100k_disable_clock(master);
@@ -157,7 +158,8 @@ static int spi100k_read_data(struct spi_master *master, int len)
	       SPI_CTRL_RD,
	       SPI_CTRL_RD,
	       spi100k->base + SPI_CTRL);
	       spi100k->base + SPI_CTRL);


	while((readw(spi100k->base + SPI_STATUS) & SPI_STATUS_RD) != SPI_STATUS_RD);
	while ((readw(spi100k->base + SPI_STATUS) & SPI_STATUS_RD) != SPI_STATUS_RD)
		;
	udelay(1000);
	udelay(1000);


	dataL = readw(spi100k->base + SPI_RX_LSB);
	dataL = readw(spi100k->base + SPI_RX_LSB);
@@ -281,7 +283,7 @@ static int omap1_spi100k_setup(struct spi_device *spi)
	spi100k = spi_master_get_devdata(spi->master);
	spi100k = spi_master_get_devdata(spi->master);


	if (!cs) {
	if (!cs) {
		cs = kzalloc(sizeof *cs, GFP_KERNEL);
		cs = kzalloc(sizeof(*cs), GFP_KERNEL);
		if (!cs)
		if (!cs)
			return -ENOMEM;
			return -ENOMEM;
		cs->base = spi100k->base + spi->chip_select * 0x14;
		cs->base = spi100k->base + spi->chip_select * 0x14;
@@ -398,7 +400,7 @@ static int omap1_spi100k_probe(struct platform_device *pdev)
	if (!pdev->id)
	if (!pdev->id)
		return -EINVAL;
		return -EINVAL;


	master = spi_alloc_master(&pdev->dev, sizeof *spi100k);
	master = spi_alloc_master(&pdev->dev, sizeof(*spi100k));
	if (master == NULL) {
	if (master == NULL) {
		dev_dbg(&pdev->dev, "master allocation failed\n");
		dev_dbg(&pdev->dev, "master allocation failed\n");
		return -ENOMEM;
		return -ENOMEM;