Skip to content

Commit

Permalink
ASoC: fsl_esai: convert tasklets to use new tasklet_setup() API
Browse files Browse the repository at this point in the history
In preparation for unconditionally passing the
struct tasklet_struct pointer to all tasklet
callbacks, switch to using the new tasklet_setup()
and from_tasklet() to pass the tasklet pointer explicitly.

Signed-off-by: Romain Perier <[email protected]>
Signed-off-by: Allen Pais <[email protected]>
Acked-by: Mark Brown <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Takashi Iwai <[email protected]>
  • Loading branch information
Allen Pais authored and tiwai committed Sep 2, 2020
1 parent 1a1575a commit b07e4a3
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions sound/soc/fsl/fsl_esai.c
Original file line number Diff line number Diff line change
Expand Up @@ -708,9 +708,9 @@ static void fsl_esai_trigger_stop(struct fsl_esai *esai_priv, bool tx)
ESAI_xFCR_xFR, 0);
}

static void fsl_esai_hw_reset(unsigned long arg)
static void fsl_esai_hw_reset(struct tasklet_struct *t)
{
struct fsl_esai *esai_priv = (struct fsl_esai *)arg;
struct fsl_esai *esai_priv = from_tasklet(esai_priv, t, task);
bool tx = true, rx = false, enabled[2];
unsigned long lock_flags;
u32 tfcr, rfcr;
Expand Down Expand Up @@ -1070,8 +1070,7 @@ static int fsl_esai_probe(struct platform_device *pdev)
return ret;
}

tasklet_init(&esai_priv->task, fsl_esai_hw_reset,
(unsigned long)esai_priv);
tasklet_setup(&esai_priv->task, fsl_esai_hw_reset);

pm_runtime_enable(&pdev->dev);

Expand Down

0 comments on commit b07e4a3

Please sign in to comment.