Skip to content

Commit

Permalink
spi: atmel: print version only after successful registration
Browse files Browse the repository at this point in the history
Don't print the version at the beginning of atmel_spi_probe(). This avoids
spamming the log whenever a deferred probe runs.

Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Acked-by: Nicolas Ferre <nicolas.ferre@microchip.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
  • Loading branch information
Baruch Siach authored and Mark Brown committed Jun 6, 2017
1 parent 2ea659a commit 6aba9c6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions drivers/spi/spi-atmel.c
Original file line number Diff line number Diff line change
Expand Up @@ -1422,7 +1422,6 @@ static void atmel_get_caps(struct atmel_spi *as)
unsigned int version;

version = atmel_get_version(as);
dev_info(&as->pdev->dev, "version: 0x%x\n", version);

as->caps.is_spi2 = version > 0x121;
as->caps.has_wdrbt = version >= 0x210;
Expand Down Expand Up @@ -1609,8 +1608,9 @@ static int atmel_spi_probe(struct platform_device *pdev)
goto out_free_dma;

/* go! */
dev_info(&pdev->dev, "Atmel SPI Controller at 0x%08lx (irq %d)\n",
(unsigned long)regs->start, irq);
dev_info(&pdev->dev, "Atmel SPI Controller version 0x%x at 0x%08lx (irq %d)\n",
atmel_get_version(as), (unsigned long)regs->start,
irq);

return 0;

Expand Down

0 comments on commit 6aba9c6

Please sign in to comment.