aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/msp3400-driver.c
diff options
context:
space:
mode:
authorHans Verkuil <hverkuil@xs4all.nl>2006-03-20 14:32:52 -0500
committerMauro Carvalho Chehab <mchehab@infradead.org>2006-03-24 14:27:00 -0500
commite3bb83420346534b51a500e3b13f75e269c3dd60 (patch)
tree24fa8baf723fd79c773dd5a2ed53ce554a6fd030 /drivers/media/video/msp3400-driver.c
parentc68735180c6e274d938b8c07d61dcf5077085c7f (diff)
V4L/DVB (3588): Remove VIDIOC_G/S_AUDOUT from msp3400
VIDIOC_G/S_AUDOUT does not belong in msp3400 (it's a user level command, not to be used in internal i2c drivers). Also fix a compile warning and improve LOG_STATUS. Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/msp3400-driver.c')
-rw-r--r--drivers/media/video/msp3400-driver.c39
1 files changed, 2 insertions, 37 deletions
diff --git a/drivers/media/video/msp3400-driver.c b/drivers/media/video/msp3400-driver.c
index fb3d1f41f116..c40e8ba9a2ea 100644
--- a/drivers/media/video/msp3400-driver.c
+++ b/drivers/media/video/msp3400-driver.c
@@ -684,7 +684,6 @@ static int msp_command(struct i2c_client *client, unsigned int cmd, void *arg)
684 { 684 {
685 struct v4l2_routing *rt = arg; 685 struct v4l2_routing *rt = arg;
686 int tuner = (rt->input >> 3) & 1; 686 int tuner = (rt->input >> 3) & 1;
687 int old_tuner = (state->routing.input >> 3) & 1;
688 int sc_in = rt->input & 0x7; 687 int sc_in = rt->input & 0x7;
689 int sc1_out = rt->output & 0xf; 688 int sc1_out = rt->output & 0xf;
690 int sc2_out = (rt->output >> 4) & 0xf; 689 int sc2_out = (rt->output >> 4) & 0xf;
@@ -733,42 +732,6 @@ static int msp_command(struct i2c_client *client, unsigned int cmd, void *arg)
733 break; 732 break;
734 } 733 }
735 734
736 case VIDIOC_G_AUDOUT:
737 {
738 struct v4l2_audioout *a = (struct v4l2_audioout *)arg;
739 int idx = a->index;
740
741 memset(a, 0, sizeof(*a));
742
743 switch (idx) {
744 case 0:
745 strcpy(a->name, "Scart1 Out");
746 break;
747 case 1:
748 strcpy(a->name, "Scart2 Out");
749 break;
750 case 2:
751 strcpy(a->name, "I2S Out");
752 break;
753 default:
754 return -EINVAL;
755 }
756 break;
757 }
758
759 case VIDIOC_S_AUDOUT:
760 {
761 struct v4l2_audioout *a = (struct v4l2_audioout *)arg;
762
763 if (a->index < 0 || a->index > 2)
764 return -EINVAL;
765
766 v4l_dbg(1, msp_debug, client, "Setting audio out on msp34xx to input %i\n", a->index);
767 msp_set_scart(client, state->in_scart, a->index + 1);
768
769 break;
770 }
771
772 case VIDIOC_INT_I2S_CLOCK_FREQ: 735 case VIDIOC_INT_I2S_CLOCK_FREQ:
773 { 736 {
774 u32 *a = (u32 *)arg; 737 u32 *a = (u32 *)arg;
@@ -854,6 +817,8 @@ static int msp_command(struct i2c_client *client, unsigned int cmd, void *arg)
854 (state->rxsubchans & V4L2_TUNER_SUB_LANG2) ? ", dual" : ""); 817 (state->rxsubchans & V4L2_TUNER_SUB_LANG2) ? ", dual" : "");
855 } 818 }
856 v4l_info(client, "Audmode: 0x%04x\n", state->audmode); 819 v4l_info(client, "Audmode: 0x%04x\n", state->audmode);
820 v4l_info(client, "Routing: 0x%08x (input) 0x%08x (output)\n",
821 state->routing.input, state->routing.output);
857 v4l_info(client, "ACB: 0x%04x\n", state->acb); 822 v4l_info(client, "ACB: 0x%04x\n", state->acb);
858 break; 823 break;
859 } 824 }