| From 1a41f923f66c03c40e6703dd69f8bfbe2791ce70 Mon Sep 17 00:00:00 2001 |
| From: Sam Shih <sam.shih@mediatek.com> |
| Date: Fri, 2 Jun 2023 13:06:19 +0800 |
| Subject: [PATCH] |
| [spi-and-storage][999-2365-fix-SPIM-NAND-and-NOR-probing.patch] |
| |
| --- |
| drivers/spi/spi-mt65xx.c | 10 +++++----- |
| 1 file changed, 5 insertions(+), 5 deletions(-) |
| |
| diff --git a/drivers/spi/spi-mt65xx.c b/drivers/spi/spi-mt65xx.c |
| index 3a8f67f1e..05697e1d1 100644 |
| --- a/drivers/spi/spi-mt65xx.c |
| +++ b/drivers/spi/spi-mt65xx.c |
| @@ -1072,7 +1072,7 @@ static int mtk_spi_probe(struct platform_device *pdev) |
| goto err_put_master; |
| } |
| |
| -/* |
| + |
| mdata->parent_clk = devm_clk_get(&pdev->dev, "parent-clk"); |
| if (IS_ERR(mdata->parent_clk)) { |
| ret = PTR_ERR(mdata->parent_clk); |
| @@ -1100,17 +1100,17 @@ static int mtk_spi_probe(struct platform_device *pdev) |
| goto err_put_master; |
| } |
| |
| - ret = clk_set_parent(mdata->sel_clk, mdata->parent_clk); |
| + /*ret = clk_set_parent(mdata->sel_clk, mdata->parent_clk); |
| if (ret < 0) { |
| dev_err(&pdev->dev, "failed to clk_set_parent (%d)\n", ret); |
| clk_disable_unprepare(mdata->spi_clk); |
| goto err_put_master; |
| } |
| |
| - clk_disable_unprepare(mdata->spi_clk); |
| + clk_disable_unprepare(mdata->sel_clk);*/ |
| + |
| + //pm_runtime_enable(&pdev->dev); |
| |
| - pm_runtime_enable(&pdev->dev); |
| -*/ |
| ret = devm_spi_register_master(&pdev->dev, master); |
| if (ret) { |
| dev_err(&pdev->dev, "failed to register master (%d)\n", ret); |
| -- |
| 2.34.1 |
| |