Loading sound/soc/fsl/imx-sgtl5000.c +5 −2 Original line number Original line Diff line number Diff line Loading @@ -62,7 +62,7 @@ static int imx_sgtl5000_probe(struct platform_device *pdev) struct device_node *ssi_np, *codec_np; struct device_node *ssi_np, *codec_np; struct platform_device *ssi_pdev; struct platform_device *ssi_pdev; struct i2c_client *codec_dev; struct i2c_client *codec_dev; struct imx_sgtl5000_data *data; struct imx_sgtl5000_data *data = NULL; int int_port, ext_port; int int_port, ext_port; int ret; int ret; Loading Loading @@ -128,7 +128,7 @@ static int imx_sgtl5000_probe(struct platform_device *pdev) goto fail; goto fail; } } data->codec_clk = devm_clk_get(&codec_dev->dev, NULL); data->codec_clk = clk_get(&codec_dev->dev, NULL); if (IS_ERR(data->codec_clk)) { if (IS_ERR(data->codec_clk)) { ret = PTR_ERR(data->codec_clk); ret = PTR_ERR(data->codec_clk); goto fail; goto fail; Loading Loading @@ -172,6 +172,8 @@ static int imx_sgtl5000_probe(struct platform_device *pdev) return 0; return 0; fail: fail: if (data && !IS_ERR(data->codec_clk)) clk_put(data->codec_clk); if (ssi_np) if (ssi_np) of_node_put(ssi_np); of_node_put(ssi_np); if (codec_np) if (codec_np) Loading @@ -185,6 +187,7 @@ static int imx_sgtl5000_remove(struct platform_device *pdev) struct imx_sgtl5000_data *data = platform_get_drvdata(pdev); struct imx_sgtl5000_data *data = platform_get_drvdata(pdev); snd_soc_unregister_card(&data->card); snd_soc_unregister_card(&data->card); clk_put(data->codec_clk); return 0; return 0; } } Loading Loading
sound/soc/fsl/imx-sgtl5000.c +5 −2 Original line number Original line Diff line number Diff line Loading @@ -62,7 +62,7 @@ static int imx_sgtl5000_probe(struct platform_device *pdev) struct device_node *ssi_np, *codec_np; struct device_node *ssi_np, *codec_np; struct platform_device *ssi_pdev; struct platform_device *ssi_pdev; struct i2c_client *codec_dev; struct i2c_client *codec_dev; struct imx_sgtl5000_data *data; struct imx_sgtl5000_data *data = NULL; int int_port, ext_port; int int_port, ext_port; int ret; int ret; Loading Loading @@ -128,7 +128,7 @@ static int imx_sgtl5000_probe(struct platform_device *pdev) goto fail; goto fail; } } data->codec_clk = devm_clk_get(&codec_dev->dev, NULL); data->codec_clk = clk_get(&codec_dev->dev, NULL); if (IS_ERR(data->codec_clk)) { if (IS_ERR(data->codec_clk)) { ret = PTR_ERR(data->codec_clk); ret = PTR_ERR(data->codec_clk); goto fail; goto fail; Loading Loading @@ -172,6 +172,8 @@ static int imx_sgtl5000_probe(struct platform_device *pdev) return 0; return 0; fail: fail: if (data && !IS_ERR(data->codec_clk)) clk_put(data->codec_clk); if (ssi_np) if (ssi_np) of_node_put(ssi_np); of_node_put(ssi_np); if (codec_np) if (codec_np) Loading @@ -185,6 +187,7 @@ static int imx_sgtl5000_remove(struct platform_device *pdev) struct imx_sgtl5000_data *data = platform_get_drvdata(pdev); struct imx_sgtl5000_data *data = platform_get_drvdata(pdev); snd_soc_unregister_card(&data->card); snd_soc_unregister_card(&data->card); clk_put(data->codec_clk); return 0; return 0; } } Loading