Skip to content

Commit

Permalink
ASoC: AD1836: drop unnecessary spi register check
Browse files Browse the repository at this point in the history
The only thing the init func does is register a spi driver, so if that
fails, we return the value back up to the caller who will display an
error message for us.  So drop the redundant checking/message.

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Acked-by: Liam Girdwood <lrg@ti.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
  • Loading branch information
Mike Frysinger authored and Mark Brown committed Jun 16, 2011
1 parent 42f32c5 commit 15e8705
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions sound/soc/codecs/ad1836.c
Original file line number Diff line number Diff line change
Expand Up @@ -385,15 +385,7 @@ static struct spi_driver ad1836_spi_driver = {

static int __init ad1836_init(void)
{
int ret;

ret = spi_register_driver(&ad1836_spi_driver);
if (ret != 0) {
printk(KERN_ERR "Failed to register ad1836 SPI driver: %d\n",
ret);
}

return ret;
return spi_register_driver(&ad1836_spi_driver);
}
module_init(ad1836_init);

Expand Down

0 comments on commit 15e8705

Please sign in to comment.