]> bbs.cooldavid.org Git - net-next-2.6.git/commit
spi/spi_s3c64xx: Make probe more robust against missing board config
authorMark Brown <broonie@opensource.wolfsonmicro.com>
Wed, 1 Sep 2010 14:55:22 +0000 (08:55 -0600)
committerGrant Likely <grant.likely@secretlab.ca>
Wed, 1 Sep 2010 14:55:22 +0000 (08:55 -0600)
commitcc0fc0bbeb17dd33ed7bfea58d0178e9c007ff67
treee659a873a4095b594d21aa38ccbd415498aa7961
parent2bfc96a127bc1cc94d26bfaa40159966064f9c8c
spi/spi_s3c64xx: Make probe more robust against missing board config

The S3C64xx SPI driver requires the machine to call s3c64xx_spi_set_info()
to select a few options, including the clock to use for the SPI controller.
If this is not done then a NULL will be passed as the clock name for
clk_get(), causing an obscure crash. Guard against this and other missing
configuration by validating that the clock name has been filled in in
the platform data that ets passed in.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
drivers/spi/spi_s3c64xx.c