summaryrefslogtreecommitdiff
path: root/linux
diff options
context:
space:
mode:
authorHans Verkuil <devnull@localhost>2005-11-27 12:37:50 +0000
committerHans Verkuil <devnull@localhost>2005-11-27 12:37:50 +0000
commit8d273f80d80b991497467d3f9f8a0667f922b59f (patch)
tree3dbbbd39da32c5ddf4efd3dd84e48fe1629a4d47 /linux
parent65ee7fe6ee3f57a553042a4be5ca762df03c11c1 (diff)
downloadmediapointer-dvb-s2-8d273f80d80b991497467d3f9f8a0667f922b59f.tar.gz
mediapointer-dvb-s2-8d273f80d80b991497467d3f9f8a0667f922b59f.tar.bz2
fix kernel message (print of %s from random pointer)
Fix kernel message ( basically printk("%s", random_pointer) ). Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Diffstat (limited to 'linux')
-rw-r--r--linux/drivers/media/video/saa7115.c14
1 files changed, 8 insertions, 6 deletions
diff --git a/linux/drivers/media/video/saa7115.c b/linux/drivers/media/video/saa7115.c
index fdf70c3d7..cd65bf92b 100644
--- a/linux/drivers/media/video/saa7115.c
+++ b/linux/drivers/media/video/saa7115.c
@@ -780,17 +780,19 @@ static v4l2_std_id saa7115_get_v4lstd(struct i2c_client *client)
static void saa7115_log_status(struct i2c_client *client)
{
- static const char * const audclk_freq_strs[] = {
- "44.1 kHz",
- "48 kHz",
- "32 kHz"
- };
struct saa7115_state *state = i2c_get_clientdata(client);
+ char *audfreq = "undefined";
int reg1e, reg1f;
int signalOk;
int vcr;
- saa7115_info("Audio frequency: %s\n", audclk_freq_strs[state->audclk_freq]);
+ switch (state->audclk_freq) {
+ case V4L2_AUDCLK_32_KHZ: audfreq = "32 kHz"; break;
+ case V4L2_AUDCLK_441_KHZ: audfreq = "44.1 kHz"; break;
+ case V4L2_AUDCLK_48_KHZ: audfreq = "48 kHz"; break;
+ }
+
+ saa7115_info("Audio frequency: %s\n", audfreq);
if (client->name[6] == '4') {
/* status for the saa7114 */
reg1f = saa7115_read(client, 0x1f);