summaryrefslogtreecommitdiff
path: root/sound
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2010-08-28 12:00:39 +0200
committerTakashi Iwai <tiwai@suse.de>2010-08-28 12:00:39 +0200
commit5b0272b87e748b258b8af6abed58d729c0949d32 (patch)
tree49c4d54e0d30ceca75c7b14861a66aebea63f81d /sound
parenta2d51aea016416962cfb7b0462f6b27c802892e1 (diff)
parent7a28826ac73d31a379d93785d8fbd24ab492b0bd (diff)
Merge branch 'fix/misc' into for-next
Diffstat (limited to 'sound')
-rw-r--r--sound/core/pcm.c6
-rw-r--r--sound/oss/sound_timer.c2
2 files changed, 7 insertions, 1 deletions
diff --git a/sound/core/pcm.c b/sound/core/pcm.c
index cbe815dfbdc8..204af48c5cc1 100644
--- a/sound/core/pcm.c
+++ b/sound/core/pcm.c
@@ -203,10 +203,16 @@ static char *snd_pcm_format_names[] = {
FORMAT(S18_3BE),
FORMAT(U18_3LE),
FORMAT(U18_3BE),
+ FORMAT(G723_24),
+ FORMAT(G723_24_1B),
+ FORMAT(G723_40),
+ FORMAT(G723_40_1B),
};
const char *snd_pcm_format_name(snd_pcm_format_t format)
{
+ if (format >= ARRAY_SIZE(snd_pcm_format_names))
+ return "Unknown";
return snd_pcm_format_names[format];
}
EXPORT_SYMBOL_GPL(snd_pcm_format_name);
diff --git a/sound/oss/sound_timer.c b/sound/oss/sound_timer.c
index f0f0c19fbff7..48cda6c4c257 100644
--- a/sound/oss/sound_timer.c
+++ b/sound/oss/sound_timer.c
@@ -26,7 +26,7 @@ static unsigned long prev_event_time;
static volatile unsigned long usecs_per_tmr; /* Length of the current interval */
static struct sound_lowlev_timer *tmr;
-static spinlock_t lock;
+static DEFINE_SPINLOCK(lock);
static unsigned long tmr2ticks(int tmr_value)
{