diff options
-rw-r--r-- | drivers/spi/spi_s3c64xx.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/drivers/spi/spi_s3c64xx.c b/drivers/spi/spi_s3c64xx.c index 97365815a729..a0b63b785418 100644 --- a/drivers/spi/spi_s3c64xx.c +++ b/drivers/spi/spi_s3c64xx.c | |||
@@ -919,6 +919,13 @@ static int __init s3c64xx_spi_probe(struct platform_device *pdev) | |||
919 | return -ENODEV; | 919 | return -ENODEV; |
920 | } | 920 | } |
921 | 921 | ||
922 | sci = pdev->dev.platform_data; | ||
923 | if (!sci->src_clk_name) { | ||
924 | dev_err(&pdev->dev, | ||
925 | "Board init must call s3c64xx_spi_set_info()\n"); | ||
926 | return -EINVAL; | ||
927 | } | ||
928 | |||
922 | /* Check for availability of necessary resource */ | 929 | /* Check for availability of necessary resource */ |
923 | 930 | ||
924 | dmatx_res = platform_get_resource(pdev, IORESOURCE_DMA, 0); | 931 | dmatx_res = platform_get_resource(pdev, IORESOURCE_DMA, 0); |
@@ -946,8 +953,6 @@ static int __init s3c64xx_spi_probe(struct platform_device *pdev) | |||
946 | return -ENOMEM; | 953 | return -ENOMEM; |
947 | } | 954 | } |
948 | 955 | ||
949 | sci = pdev->dev.platform_data; | ||
950 | |||
951 | platform_set_drvdata(pdev, master); | 956 | platform_set_drvdata(pdev, master); |
952 | 957 | ||
953 | sdd = spi_master_get_devdata(master); | 958 | sdd = spi_master_get_devdata(master); |