summaryrefslogtreecommitdiffstats
path: root/drivers/spi/spi-dw-bt1.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/spi/spi-dw-bt1.c')
-rw-r--r--drivers/spi/spi-dw-bt1.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/spi/spi-dw-bt1.c b/drivers/spi/spi-dw-bt1.c
index da4f4d82617c..4aa8596fb1f2 100644
--- a/drivers/spi/spi-dw-bt1.c
+++ b/drivers/spi/spi-dw-bt1.c
@@ -280,8 +280,10 @@ static int dw_spi_bt1_probe(struct platform_device *pdev)
dws->bus_num = pdev->id;
dws->reg_io_width = 4;
dws->max_freq = clk_get_rate(dwsbt1->clk);
- if (!dws->max_freq)
+ if (!dws->max_freq) {
+ ret = -EINVAL;
goto err_disable_clk;
+ }
init_func = device_get_match_data(&pdev->dev);
ret = init_func(pdev, dwsbt1);