Commit cf74dcf3512271bca4bb5fe79274ad23c22f5dd3
1 parent
61efcee860
Exists in
master
and in
13 other branches
ALSA: timer: Use standard printk helpers
Use the standard pr_xxx() helpers instead of home-baked snd_print*(). Signed-off-by: Takashi Iwai <tiwai@suse.de>
Showing 3 changed files with 8 additions and 11 deletions Side-by-side Diff
sound/core/hrtimer.c
... | ... | @@ -126,8 +126,7 @@ |
126 | 126 | |
127 | 127 | hrtimer_get_res(CLOCK_MONOTONIC, &tp); |
128 | 128 | if (tp.tv_sec > 0 || !tp.tv_nsec) { |
129 | - snd_printk(KERN_ERR | |
130 | - "snd-hrtimer: Invalid resolution %u.%09u", | |
129 | + pr_err("snd-hrtimer: Invalid resolution %u.%09u", | |
131 | 130 | (unsigned)tp.tv_sec, (unsigned)tp.tv_nsec); |
132 | 131 | return -EINVAL; |
133 | 132 | } |
sound/core/rtctimer.c
... | ... | @@ -132,8 +132,7 @@ |
132 | 132 | |
133 | 133 | if (rtctimer_freq < 2 || rtctimer_freq > 8192 || |
134 | 134 | !is_power_of_2(rtctimer_freq)) { |
135 | - snd_printk(KERN_ERR "rtctimer: invalid frequency %d\n", | |
136 | - rtctimer_freq); | |
135 | + pr_err("ALSA: rtctimer: invalid frequency %d\n", rtctimer_freq); | |
137 | 136 | return -EINVAL; |
138 | 137 | } |
139 | 138 |
sound/core/timer.c
... | ... | @@ -240,7 +240,8 @@ |
240 | 240 | /* open a slave instance */ |
241 | 241 | if (tid->dev_sclass <= SNDRV_TIMER_SCLASS_NONE || |
242 | 242 | tid->dev_sclass > SNDRV_TIMER_SCLASS_OSS_SEQUENCER) { |
243 | - snd_printd("invalid slave class %i\n", tid->dev_sclass); | |
243 | + pr_debug("ALSA: timer: invalid slave class %i\n", | |
244 | + tid->dev_sclass); | |
244 | 245 | return -EINVAL; |
245 | 246 | } |
246 | 247 | mutex_lock(®ister_mutex); |
... | ... | @@ -774,7 +775,7 @@ |
774 | 775 | *rtimer = NULL; |
775 | 776 | timer = kzalloc(sizeof(*timer), GFP_KERNEL); |
776 | 777 | if (timer == NULL) { |
777 | - snd_printk(KERN_ERR "timer: cannot allocate\n"); | |
778 | + pr_err("ALSA: timer: cannot allocate\n"); | |
778 | 779 | return -ENOMEM; |
779 | 780 | } |
780 | 781 | timer->tmr_class = tid->dev_class; |
... | ... | @@ -813,7 +814,7 @@ |
813 | 814 | if (! list_empty(&timer->open_list_head)) { |
814 | 815 | struct list_head *p, *n; |
815 | 816 | struct snd_timer_instance *ti; |
816 | - snd_printk(KERN_WARNING "timer %p is busy?\n", timer); | |
817 | + pr_warn("ALSA: timer %p is busy?\n", timer); | |
817 | 818 | list_for_each_safe(p, n, &timer->open_list_head) { |
818 | 819 | list_del_init(p); |
819 | 820 | ti = list_entry(p, struct snd_timer_instance, open_list); |
820 | 821 | |
... | ... | @@ -1955,12 +1956,10 @@ |
1955 | 1956 | #endif |
1956 | 1957 | |
1957 | 1958 | if ((err = snd_timer_register_system()) < 0) |
1958 | - snd_printk(KERN_ERR "unable to register system timer (%i)\n", | |
1959 | - err); | |
1959 | + pr_err("ALSA: unable to register system timer (%i)\n", err); | |
1960 | 1960 | if ((err = snd_register_device(SNDRV_DEVICE_TYPE_TIMER, NULL, 0, |
1961 | 1961 | &snd_timer_f_ops, NULL, "timer")) < 0) |
1962 | - snd_printk(KERN_ERR "unable to register timer device (%i)\n", | |
1963 | - err); | |
1962 | + pr_err("ALSA: unable to register timer device (%i)\n", err); | |
1964 | 1963 | snd_timer_proc_init(); |
1965 | 1964 | return 0; |
1966 | 1965 | } |