diff options
-rw-r--r-- | linux/drivers/media/video/cx18/cx18-ioctl.c | 10 | ||||
-rw-r--r-- | linux/drivers/media/video/ivtv/ivtv-ioctl.c | 8 | ||||
-rw-r--r-- | linux/include/media/v4l2-common.h | 14 | ||||
-rw-r--r-- | v4l2-apps/util/cx18-ctl.c | 51 | ||||
-rw-r--r-- | v4l2-apps/util/ivtv-ctl.c | 47 |
5 files changed, 7 insertions, 123 deletions
diff --git a/linux/drivers/media/video/cx18/cx18-ioctl.c b/linux/drivers/media/video/cx18/cx18-ioctl.c index b2ebd81be..65e2ef425 100644 --- a/linux/drivers/media/video/cx18/cx18-ioctl.c +++ b/linux/drivers/media/video/cx18/cx18-ioctl.c @@ -951,16 +951,6 @@ static long cx18_default(struct file *file, void *fh, int cmd, void *arg) struct cx18 *cx = ((struct cx18_open_id *)fh)->cx; switch (cmd) { - case VIDIOC_INT_S_AUDIO_ROUTING: { - struct v4l2_routing *route = arg; - - CX18_DEBUG_IOCTL("VIDIOC_INT_S_AUDIO_ROUTING(%d, %d)\n", - route->input, route->output); - cx18_call_hw(cx, cx->card->hw_audio_ctrl, audio, s_routing, - route->input, route->output, 0); - break; - } - case VIDIOC_INT_RESET: { u32 val = *(u32 *)arg; diff --git a/linux/drivers/media/video/ivtv/ivtv-ioctl.c b/linux/drivers/media/video/ivtv/ivtv-ioctl.c index cf48b6ab9..4a2d464f0 100644 --- a/linux/drivers/media/video/ivtv/ivtv-ioctl.c +++ b/linux/drivers/media/video/ivtv/ivtv-ioctl.c @@ -1734,14 +1734,6 @@ static long ivtv_default(struct file *file, void *fh, int cmd, void *arg) struct ivtv *itv = ((struct ivtv_open_id *)fh)->itv; switch (cmd) { - case VIDIOC_INT_S_AUDIO_ROUTING: { - struct v4l2_routing *route = arg; - - ivtv_call_hw(itv, itv->card->hw_audio, audio, s_routing, - route->input, route->output, 0); - break; - } - case VIDIOC_INT_RESET: { u32 val = *(u32 *)arg; diff --git a/linux/include/media/v4l2-common.h b/linux/include/media/v4l2-common.h index 4d8ce3e42..2e1e3a293 100644 --- a/linux/include/media/v4l2-common.h +++ b/linux/include/media/v4l2-common.h @@ -179,10 +179,10 @@ const unsigned short *v4l2_i2c_tuner_addrs(enum v4l2_i2c_tuner_type type); /* ------------------------------------------------------------------------- */ -/* Note: these remaining ioctls should be removed as well, but they are still - used in tuner-simple.c (TUNER_SET_CONFIG) and cx18/ivtv (RESET and - S_AUDIO_ROUTING). To remove these ioctls some more cleanup is needed in - those modules. */ +/* Note: these remaining ioctls/structs should be removed as well, but they are + still used in tuner-simple.c (TUNER_SET_CONFIG), cx18/ivtv (RESET) and + v4l2-int-device.h (v4l2_routing). To remove these ioctls some more cleanup + is needed in those modules. */ /* s_config */ struct v4l2_priv_tun_config { @@ -191,13 +191,11 @@ struct v4l2_priv_tun_config { }; #define TUNER_SET_CONFIG _IOW('d', 92, struct v4l2_priv_tun_config) -/* s_routing: routing definition, device dependent. It specifies which inputs - (if any) should be routed to which outputs (if any). */ +#define VIDIOC_INT_RESET _IOW ('d', 102, u32) + struct v4l2_routing { u32 input; u32 output; }; -#define VIDIOC_INT_S_AUDIO_ROUTING _IOW ('d', 109, struct v4l2_routing) -#define VIDIOC_INT_RESET _IOW ('d', 102, u32) #endif /* V4L2_COMMON_H_ */ diff --git a/v4l2-apps/util/cx18-ctl.c b/v4l2-apps/util/cx18-ctl.c index 3d8ff385d..138f3c26a 100644 --- a/v4l2-apps/util/cx18-ctl.c +++ b/v4l2-apps/util/cx18-ctl.c @@ -52,12 +52,6 @@ #define CX18_DBGFLG_HIGHVOL (1 << 8) /* Internals copied from media/v4l2-common.h */ -struct v4l2_routing { - __u32 input; - __u32 output; -}; -#define VIDIOC_INT_S_AUDIO_ROUTING _IOW('d', 109, struct v4l2_routing) - #define VIDIOC_INT_RESET _IOW('d', 102, __u32) #define __stringify_1(x) #x @@ -80,7 +74,6 @@ enum Option { OptHelp = 'h', OptSetGPIO = 'i', OptListGPIO = 'I', - OptSetAudioRoute = 'v', OptReset = 128, OptVersion, OptLast = 256 @@ -97,7 +90,6 @@ static struct option long_options[] = { {"help", no_argument, 0, OptHelp}, {"set-gpio", required_argument, 0, OptSetGPIO}, {"list-gpio", no_argument, 0, OptListGPIO}, - {"audio-route", required_argument, 0, OptSetAudioRoute}, {"reset", required_argument, 0, OptReset}, {"version", no_argument, 0, OptVersion}, {0, 0, 0, 0} @@ -129,8 +121,6 @@ static void usage(void) printf(" show GPIO input/direction/output bits\n"); printf(" -i, --set-gpio [dir=<dir>,]val=<val>\n"); printf(" set GPIO direction bits to <dir> and set output to <val>\n"); - printf(" -v, --audio-route=input=<in>,output=<out>\n"); - printf(" set the audio input/output routing [VIDIOC_INT_S_AUDIO_ROUTING]\n"); exit(0); } @@ -250,14 +240,8 @@ int main(int argc, char **argv) char *subopts[] = { #define SUB_VAL 0 "val", -#define SUB_YUV_MODE 1 - "mode", -#define SUB_DIR 2 +#define SUB_DIR 1 "dir", -#define SUB_INPUT 3 - "input", -#define SUB_OUTPUT 4 - "output", NULL }; @@ -270,7 +254,6 @@ int main(int argc, char **argv) const char *device = "/dev/video0"; /* -d device */ int ch; int yuv_mode = 0; - struct v4l2_routing route; /* audio_route */ unsigned int gpio_out = 0x0; /* GPIO output data */ unsigned int gpio_dir = 0x0; /* GPIO direction bits */ int gpio_set_dir = 0; @@ -321,34 +304,6 @@ int main(int argc, char **argv) device = newdev; } break; - case OptSetAudioRoute: - subs = optarg; - while (*subs != '\0') { - switch (getsubopt(&subs, subopts, &value)) { - case SUB_INPUT: - if (value == NULL) { - printf - ("No value given to suboption <input>\n"); - usage(); - } - route.input = strtol(value, 0L, 0); - break; - case SUB_OUTPUT: - if (value == NULL) { - printf - ("No value given to suboption <output>\n"); - usage(); - } - route.output = strtol(value, 0L, 0); - break; - default: - printf - ("Invalid suboptions specified\n"); - usage(); - break; - } - } - break; case OptReset: reset = strtol(optarg, 0L, 0); break; @@ -414,10 +369,6 @@ int main(int argc, char **argv) } /* Setting Opts */ - - if (options[OptSetAudioRoute]) - doioctl(fd, VIDIOC_INT_S_AUDIO_ROUTING, &route, "VIDIOC_INT_S_AUDIO_ROUTING"); - if (options[OptSetGPIO]) { struct v4l2_dbg_register reg; diff --git a/v4l2-apps/util/ivtv-ctl.c b/v4l2-apps/util/ivtv-ctl.c index a05dcbba2..6af8fc663 100644 --- a/v4l2-apps/util/ivtv-ctl.c +++ b/v4l2-apps/util/ivtv-ctl.c @@ -56,12 +56,6 @@ #define IVTV_DBGFLG_HIGHVOL (1 << 10) /* Internals copied from media/v4l2-common.h */ -struct v4l2_routing { - __u32 input; - __u32 output; -}; -#define VIDIOC_INT_S_AUDIO_ROUTING _IOW('d', 109, struct v4l2_routing) - #define VIDIOC_INT_RESET _IOW('d', 102, __u32) #include <linux/ivtv.h> @@ -81,7 +75,6 @@ enum Option { OptListGPIO = 'I', OptPassThrough = 'K', OptFrameSync = 'k', - OptSetAudioRoute = 'v', OptReset = 128, OptSetYuvMode, OptGetYuvMode, @@ -106,7 +99,6 @@ static struct option long_options[] = { {"list-gpio", no_argument, 0, OptListGPIO}, {"passthrough", required_argument, 0, OptPassThrough}, {"sync", no_argument, 0, OptFrameSync}, - {"audio-route", required_argument, 0, OptSetAudioRoute}, {"reset", required_argument, 0, OptReset}, {"get-yuv-mode", no_argument, 0, OptGetYuvMode}, {"set-yuv-mode", required_argument, 0, OptSetYuvMode}, @@ -167,8 +159,6 @@ static void usage(void) printf(" -i, --set-gpio [dir=<dir>,]val=<val>\n"); printf(" set GPIO direction bits to <dir> and set output to <val>\n"); printf(" -k, --sync test vsync's capabilities [VIDEO_GET_EVENT]\n"); - printf(" -v, --audio-route=input=<in>,output=<out>\n"); - printf(" set the audio input/output routing [VIDIOC_INT_S_AUDIO_ROUTING]\n"); exit(0); } @@ -330,10 +320,6 @@ int main(int argc, char **argv) "mode", #define SUB_DIR 2 "dir", -#define SUB_INPUT 3 - "input", -#define SUB_OUTPUT 4 - "output", NULL }; @@ -346,7 +332,6 @@ int main(int argc, char **argv) const char *device = "/dev/video0"; /* -d device */ int ch; int yuv_mode = 0; - struct v4l2_routing route; /* audio_route */ unsigned short gpio_out = 0x0; /* GPIO output data */ unsigned short gpio_dir = 0x0; /* GPIO direction bits */ int gpio_set_dir = 0; @@ -424,34 +409,6 @@ int main(int argc, char **argv) device = newdev; } break; - case OptSetAudioRoute: - subs = optarg; - while (*subs != '\0') { - switch (getsubopt(&subs, subopts, &value)) { - case SUB_INPUT: - if (value == NULL) { - printf - ("No value given to suboption <input>\n"); - usage(); - } - route.input = strtol(value, 0L, 0); - break; - case SUB_OUTPUT: - if (value == NULL) { - printf - ("No value given to suboption <output>\n"); - usage(); - } - route.output = strtol(value, 0L, 0); - break; - default: - printf - ("Invalid suboptions specified\n"); - usage(); - break; - } - } - break; case OptReset: reset = strtol(optarg, 0L, 0); break; @@ -529,10 +486,6 @@ int main(int argc, char **argv) /* Setting Opts */ - if (options[OptSetAudioRoute]) - doioctl(fd, VIDIOC_INT_S_AUDIO_ROUTING, &route, - "VIDIOC_INT_S_AUDIO_ROUTING"); - if (options[OptFrameSync]) { printf("ioctl: VIDEO_GET_EVENT\n"); |