Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 165358
b: refs/heads/master
c: ad80efc
h: refs/heads/master
v: v3
  • Loading branch information
Cliff Cai authored and Mark Brown committed Sep 18, 2009
1 parent 6b94bb6 commit 3a4378d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 13 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: fab19bae0c2951ed8bc517a53848b027fead293d
refs/heads/master: ad80efc469f56d41f3f4adc1b2c86bf65689ebeb
19 changes: 7 additions & 12 deletions trunk/sound/soc/blackfin/bf5xx-i2s.c
Original file line number Diff line number Diff line change
Expand Up @@ -237,36 +237,31 @@ static void bf5xx_i2s_remove(struct platform_device *pdev,
#ifdef CONFIG_PM
static int bf5xx_i2s_suspend(struct snd_soc_dai *dai)
{
struct sport_device *sport =
(struct sport_device *)dai->private_data;

pr_debug("%s : sport %d\n", __func__, dai->id);
if (!dai->active)
return 0;

if (dai->capture.active)
sport_rx_stop(sport);
sport_rx_stop(sport_handle);
if (dai->playback.active)
sport_tx_stop(sport);
sport_tx_stop(sport_handle);
return 0;
}

static int bf5xx_i2s_resume(struct snd_soc_dai *dai)
{
int ret;
struct sport_device *sport =
(struct sport_device *)dai->private_data;

pr_debug("%s : sport %d\n", __func__, dai->id);
if (!dai->active)
return 0;

ret = sport_config_rx(sport, RFSR | RCKFE, RSFSE|0x1f, 0, 0);
ret = sport_config_rx(sport_handle, bf5xx_i2s.rcr1,
bf5xx_i2s.rcr2, 0, 0);
if (ret) {
pr_err("SPORT is busy!\n");
return -EBUSY;
}

ret = sport_config_tx(sport, TFSR | TCKFE, TSFSE|0x1f, 0, 0);
ret = sport_config_tx(sport_handle, bf5xx_i2s.tcr1,
bf5xx_i2s.tcr2, 0, 0);
if (ret) {
pr_err("SPORT is busy!\n");
return -EBUSY;
Expand Down

0 comments on commit 3a4378d

Please sign in to comment.