aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHans Verkuil <hverkuil@xs4all.nl>2007-12-12 05:40:54 -0500
committerMauro Carvalho Chehab <mchehab@infradead.org>2008-01-25 16:04:06 -0500
commit35df38c015866b3c28bfb1914b14eba92086cdd1 (patch)
tree443fa8010f41437b78c971aca72b0344cbbb822f
parent79f998a71b9bca5a16b0b8c30e5c0c849705a5ec (diff)
V4L/DVB (6865): vp27smpx: CodingStyle cleanup
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
-rw-r--r--drivers/media/video/vp27smpx.c40
1 files changed, 20 insertions, 20 deletions
diff --git a/drivers/media/video/vp27smpx.c b/drivers/media/video/vp27smpx.c
index 2d97914d3092..282c81403c97 100644
--- a/drivers/media/video/vp27smpx.c
+++ b/drivers/media/video/vp27smpx.c
@@ -50,27 +50,26 @@ static void vp27smpx_set_audmode(struct i2c_client *client, u32 audmode)
50 u8 data[3] = { 0x00, 0x00, 0x04 }; 50 u8 data[3] = { 0x00, 0x00, 0x04 };
51 51
52 switch (audmode) { 52 switch (audmode) {
53 case V4L2_TUNER_MODE_MONO: 53 case V4L2_TUNER_MODE_MONO:
54 case V4L2_TUNER_MODE_LANG1: 54 case V4L2_TUNER_MODE_LANG1:
55 break; 55 break;
56 case V4L2_TUNER_MODE_STEREO: 56 case V4L2_TUNER_MODE_STEREO:
57 case V4L2_TUNER_MODE_LANG1_LANG2: 57 case V4L2_TUNER_MODE_LANG1_LANG2:
58 data[1] = 0x01; 58 data[1] = 0x01;
59 break; 59 break;
60 case V4L2_TUNER_MODE_LANG2: 60 case V4L2_TUNER_MODE_LANG2:
61 data[1] = 0x02; 61 data[1] = 0x02;
62 break; 62 break;
63 } 63 }
64 64
65 if (i2c_master_send(client, data, sizeof(data)) != sizeof(data)) { 65 if (i2c_master_send(client, data, sizeof(data)) != sizeof(data))
66 v4l_err(client, "%s: I/O error setting audmode\n", client->name); 66 v4l_err(client, "%s: I/O error setting audmode\n",
67 } 67 client->name);
68 else { 68 else
69 state->audmode = audmode; 69 state->audmode = audmode;
70 }
71} 70}
72 71
73static int vp27smpx_command(struct i2c_client *client, unsigned int cmd, void *arg) 72static int vp27smpx_command(struct i2c_client *client, unsigned cmd, void *arg)
74{ 73{
75 struct vp27smpx_state *state = i2c_get_clientdata(client); 74 struct vp27smpx_state *state = i2c_get_clientdata(client);
76 struct v4l2_tuner *vt = arg; 75 struct v4l2_tuner *vt = arg;
@@ -99,7 +98,8 @@ static int vp27smpx_command(struct i2c_client *client, unsigned int cmd, void *a
99 break; 98 break;
100 99
101 case VIDIOC_G_CHIP_IDENT: 100 case VIDIOC_G_CHIP_IDENT:
102 return v4l2_chip_ident_i2c_client(client, arg, V4L2_IDENT_VP27SMPX, 0); 101 return v4l2_chip_ident_i2c_client(client, arg,
102 V4L2_IDENT_VP27SMPX, 0);
103 103
104 case VIDIOC_LOG_STATUS: 104 case VIDIOC_LOG_STATUS:
105 v4l_info(client, "Audio Mode: %u%s\n", state->audmode, 105 v4l_info(client, "Audio Mode: %u%s\n", state->audmode,
@@ -131,12 +131,12 @@ static int vp27smpx_probe(struct i2c_client *client)
131 131
132 snprintf(client->name, sizeof(client->name) - 1, "vp27smpx"); 132 snprintf(client->name, sizeof(client->name) - 1, "vp27smpx");
133 133
134 v4l_info(client, "chip found @ 0x%x (%s)\n", client->addr << 1, client->adapter->name); 134 v4l_info(client, "chip found @ 0x%x (%s)\n",
135 client->addr << 1, client->adapter->name);
135 136
136 state = kzalloc(sizeof(struct vp27smpx_state), GFP_KERNEL); 137 state = kzalloc(sizeof(struct vp27smpx_state), GFP_KERNEL);
137 if (state == NULL) { 138 if (state == NULL)
138 return -ENOMEM; 139 return -ENOMEM;
139 }
140 state->audmode = V4L2_TUNER_MODE_STEREO; 140 state->audmode = V4L2_TUNER_MODE_STEREO;
141 i2c_set_clientdata(client, state); 141 i2c_set_clientdata(client, state);
142 142