summaryrefslogtreecommitdiffstats
path: root/sound/pci/cs5535audio/cs5535audio.c
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2014-02-25 16:10:25 +0100
committerTakashi Iwai <tiwai@suse.de>2014-02-26 16:45:25 +0100
commit00980aa9c7ce2b5b54a5a7e7cf259f36fabdb249 (patch)
tree1aff12ccf3dec4e26b5de62e3360bf185d237c2d /sound/pci/cs5535audio/cs5535audio.c
parent74103227a6eee19654a915cbd56307fc8bc78ba6 (diff)
downloadop-kernel-dev-00980aa9c7ce2b5b54a5a7e7cf259f36fabdb249.zip
op-kernel-dev-00980aa9c7ce2b5b54a5a7e7cf259f36fabdb249.tar.gz
ALSA: cs5535audio: Use standard printk helpers
Convert with dev_err() and co from snd_printk(), etc. Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci/cs5535audio/cs5535audio.c')
-rw-r--r--sound/pci/cs5535audio/cs5535audio.c26
1 files changed, 15 insertions, 11 deletions
diff --git a/sound/pci/cs5535audio/cs5535audio.c b/sound/pci/cs5535audio/cs5535audio.c
index 051b3e2..edcbbda 100644
--- a/sound/pci/cs5535audio/cs5535audio.c
+++ b/sound/pci/cs5535audio/cs5535audio.c
@@ -84,7 +84,8 @@ static void wait_till_cmd_acked(struct cs5535audio *cs5535au, unsigned long time
udelay(1);
} while (--timeout);
if (!timeout)
- snd_printk(KERN_ERR "Failure writing to cs5535 codec\n");
+ dev_err(cs5535au->card->dev,
+ "Failure writing to cs5535 codec\n");
}
static unsigned short snd_cs5535audio_codec_read(struct cs5535audio *cs5535au,
@@ -109,8 +110,9 @@ static unsigned short snd_cs5535audio_codec_read(struct cs5535audio *cs5535au,
udelay(1);
} while (--timeout);
if (!timeout)
- snd_printk(KERN_ERR "Failure reading codec reg 0x%x,"
- "Last value=0x%x\n", reg, val);
+ dev_err(cs5535au->card->dev,
+ "Failure reading codec reg 0x%x, Last value=0x%x\n",
+ reg, val);
return (unsigned short) val;
}
@@ -168,7 +170,7 @@ static int snd_cs5535audio_mixer(struct cs5535audio *cs5535au)
olpc_prequirks(card, &ac97);
if ((err = snd_ac97_mixer(pbus, &ac97, &cs5535au->ac97)) < 0) {
- snd_printk(KERN_ERR "mixer failed\n");
+ dev_err(card->dev, "mixer failed\n");
return err;
}
@@ -176,7 +178,7 @@ static int snd_cs5535audio_mixer(struct cs5535audio *cs5535au)
err = olpc_quirks(card, cs5535au->ac97);
if (err < 0) {
- snd_printk(KERN_ERR "olpc quirks failed\n");
+ dev_err(card->dev, "olpc quirks failed\n");
return err;
}
@@ -194,8 +196,9 @@ static void process_bm0_irq(struct cs5535audio *cs5535au)
dma = cs5535au->playback_substream->runtime->private_data;
snd_pcm_period_elapsed(cs5535au->playback_substream);
} else {
- snd_printk(KERN_ERR "unexpected bm0 irq src, bm_stat=%x\n",
- bm_stat);
+ dev_err(cs5535au->card->dev,
+ "unexpected bm0 irq src, bm_stat=%x\n",
+ bm_stat);
}
}
@@ -241,8 +244,9 @@ static irqreturn_t snd_cs5535audio_interrupt(int irq, void *dev_id)
process_bm1_irq(cs5535au);
break;
default:
- snd_printk(KERN_ERR "Unexpected irq src: "
- "0x%x\n", acc_irq_stat);
+ dev_err(cs5535au->card->dev,
+ "Unexpected irq src: 0x%x\n",
+ acc_irq_stat);
break;
}
}
@@ -287,7 +291,7 @@ static int snd_cs5535audio_create(struct snd_card *card,
if (pci_set_dma_mask(pci, DMA_BIT_MASK(32)) < 0 ||
pci_set_consistent_dma_mask(pci, DMA_BIT_MASK(32)) < 0) {
- printk(KERN_WARNING "unable to get 32bit dma\n");
+ dev_warn(card->dev, "unable to get 32bit dma\n");
err = -ENXIO;
goto pcifail;
}
@@ -312,7 +316,7 @@ static int snd_cs5535audio_create(struct snd_card *card,
if (request_irq(pci->irq, snd_cs5535audio_interrupt,
IRQF_SHARED, KBUILD_MODNAME, cs5535au)) {
- snd_printk(KERN_ERR "unable to grab IRQ %d\n", pci->irq);
+ dev_err(card->dev, "unable to grab IRQ %d\n", pci->irq);
err = -EBUSY;
goto sndfail;
}
OpenPOWER on IntegriCloud