Skip to content

Commit

Permalink
ASoC: omap-mcpdm: Drop pdmclk clock handling
Browse files Browse the repository at this point in the history
This reverts commit 65aca64.

The patches for twl6040 MFD and clk missed the merge window and
causing the McPDM driver to never probe since it is put back to
the deferred list because the missing drivers.

Signed-off-by: Peter Ujfalusi <[email protected]>
Signed-off-by: Mark Brown <[email protected]>
  • Loading branch information
Peter Ujfalusi authored and broonie committed Aug 18, 2016
1 parent 29b4817 commit 479e2a8
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 27 deletions.
10 changes: 0 additions & 10 deletions Documentation/devicetree/bindings/sound/omap-mcpdm.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ Required properties:
- interrupts: Interrupt number for McPDM
- interrupt-parent: The parent interrupt controller
- ti,hwmods: Name of the hwmod associated to the McPDM
- clocks: phandle for the pdmclk provider, likely <&twl6040>
- clock-names: Must be "pdmclk"

Example:

Expand All @@ -21,11 +19,3 @@ mcpdm: mcpdm@40132000 {
interrupt-parent = <&gic>;
ti,hwmods = "mcpdm";
};

In board DTS file the pdmclk needs to be added:

&mcpdm {
clocks = <&twl6040>;
clock-names = "pdmclk";
status = "okay";
};
17 changes: 0 additions & 17 deletions sound/soc/omap/omap-mcpdm.c
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@
#include <linux/err.h>
#include <linux/io.h>
#include <linux/irq.h>
#include <linux/clk.h>
#include <linux/slab.h>
#include <linux/pm_runtime.h>
#include <linux/of_device.h>
Expand All @@ -55,7 +54,6 @@ struct omap_mcpdm {
unsigned long phys_base;
void __iomem *io_base;
int irq;
struct clk *pdmclk;

struct mutex mutex;

Expand Down Expand Up @@ -390,7 +388,6 @@ static int omap_mcpdm_probe(struct snd_soc_dai *dai)
struct omap_mcpdm *mcpdm = snd_soc_dai_get_drvdata(dai);
int ret;

clk_prepare_enable(mcpdm->pdmclk);
pm_runtime_enable(mcpdm->dev);

/* Disable lines while request is ongoing */
Expand Down Expand Up @@ -425,7 +422,6 @@ static int omap_mcpdm_remove(struct snd_soc_dai *dai)

pm_runtime_disable(mcpdm->dev);

clk_disable_unprepare(mcpdm->pdmclk);
return 0;
}

Expand All @@ -445,17 +441,13 @@ static int omap_mcpdm_suspend(struct snd_soc_dai *dai)
mcpdm->pm_active_count++;
}

clk_disable_unprepare(mcpdm->pdmclk);

return 0;
}

static int omap_mcpdm_resume(struct snd_soc_dai *dai)
{
struct omap_mcpdm *mcpdm = snd_soc_dai_get_drvdata(dai);

clk_prepare_enable(mcpdm->pdmclk);

if (mcpdm->pm_active_count) {
while (mcpdm->pm_active_count--)
pm_runtime_get_sync(mcpdm->dev);
Expand Down Expand Up @@ -549,15 +541,6 @@ static int asoc_mcpdm_probe(struct platform_device *pdev)

mcpdm->dev = &pdev->dev;

mcpdm->pdmclk = devm_clk_get(&pdev->dev, "pdmclk");
if (IS_ERR(mcpdm->pdmclk)) {
if (PTR_ERR(mcpdm->pdmclk) == -EPROBE_DEFER)
return -EPROBE_DEFER;
dev_warn(&pdev->dev, "Error getting pdmclk (%ld)!\n",
PTR_ERR(mcpdm->pdmclk));
mcpdm->pdmclk = NULL;
}

ret = devm_snd_soc_register_component(&pdev->dev,
&omap_mcpdm_component,
&omap_mcpdm_dai, 1);
Expand Down

0 comments on commit 479e2a8

Please sign in to comment.