From f2f9307a4f26a9fbe47fff486a9cee5885af748f Mon Sep 17 00:00:00 2001 From: Takashi Iwai Date: Tue, 4 Feb 2014 18:21:03 +0100 Subject: ALSA: core: Use standard printk helpers Use dev_err() & co as much as possible. If not available (no device assigned at the calling point), use pr_xxx() helpers instead. Signed-off-by: Takashi Iwai --- sound/core/info.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'sound/core/info.c') diff --git a/sound/core/info.c b/sound/core/info.c index 7916c07b9324..051d55b05521 100644 --- a/sound/core/info.c +++ b/sound/core/info.c @@ -418,9 +418,14 @@ static int snd_info_entry_release(struct inode *inode, struct file *file) if (entry->c.text.write) { entry->c.text.write(entry, data->wbuffer); if (data->wbuffer->error) { - snd_printk(KERN_WARNING "data write error to %s (%i)\n", - entry->name, - data->wbuffer->error); + if (entry->card) + dev_warn(entry->card->dev, "info: data write error to %s (%i)\n", + entry->name, + data->wbuffer->error); + else + pr_warn("ALSA: info: data write error to %s (%i)\n", + entry->name, + data->wbuffer->error); } } kfree(data->wbuffer->buffer); -- cgit v1.2.3