From 2f1835af8f95aeed8b722b47fcb6a70651f6e1a2 Mon Sep 17 00:00:00 2001 From: Mauro Carvalho Chehab Date: Wed, 15 Oct 2008 17:47:36 +0000 Subject: saa7127: Fix two typos From: Jean Delvare Signed-off-by: Jean Delvare Signed-off-by: Mauro Carvalho Chehab --- linux/include/linux/i2c-id.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'linux/include') diff --git a/linux/include/linux/i2c-id.h b/linux/include/linux/i2c-id.h index 493435bcd..01d67ba9e 100644 --- a/linux/include/linux/i2c-id.h +++ b/linux/include/linux/i2c-id.h @@ -60,7 +60,7 @@ #define I2C_DRIVERID_WM8775 69 /* wm8775 audio processor */ #define I2C_DRIVERID_CS53L32A 70 /* cs53l32a audio processor */ #define I2C_DRIVERID_CX25840 71 /* cx2584x video encoder */ -#define I2C_DRIVERID_SAA7127 72 /* saa7124 video encoder */ +#define I2C_DRIVERID_SAA7127 72 /* saa7127 video encoder */ #define I2C_DRIVERID_SAA711X 73 /* saa711x video encoders */ #define I2C_DRIVERID_AKITAIOEXP 74 /* IO Expander on Sharp SL-C1000 */ #define I2C_DRIVERID_INFRARED 75 /* I2C InfraRed on Video boards */ -- cgit v1.2.3 From ed4d56c859ac68c4480862375d42f62cc9cff38e Mon Sep 17 00:00:00 2001 From: Guennadi Liakhovetski Date: Fri, 17 Oct 2008 00:49:27 +0200 Subject: soc-camera: move sensor power management to soc_camera_platform.c Switching sensors on and off is now done by sensor drivers themselves, typically using platform-provided hooks. Update soc_camera_platform.c to do the same. Also remove a refundant struct soc_camera_platform_info definition from soc_camera_platform.c. Signed-off-by: Guennadi Liakhovetski Tested-by: Magnus Damm --- linux/drivers/media/video/soc_camera_platform.c | 20 +++++++++++--------- linux/include/media/soc_camera_platform.h | 1 + 2 files changed, 12 insertions(+), 9 deletions(-) --- linux/include/media/soc_camera_platform.h | 1 + 1 file changed, 1 insertion(+) (limited to 'linux/include') diff --git a/linux/include/media/soc_camera_platform.h b/linux/include/media/soc_camera_platform.h index 851f18220..7c81ad32b 100644 --- a/linux/include/media/soc_camera_platform.h +++ b/linux/include/media/soc_camera_platform.h @@ -9,6 +9,7 @@ struct soc_camera_platform_info { unsigned long format_depth; struct v4l2_pix_format format; unsigned long bus_param; + void (*power)(int); int (*set_capture)(struct soc_camera_platform_info *info, int enable); }; -- cgit v1.2.3 From fc0873bc5a230ed74a66d4b1caa99ec3fe9aefa1 Mon Sep 17 00:00:00 2001 From: Magnus Damm Date: Fri, 17 Oct 2008 00:51:47 +0200 Subject: video: add header to soc_camera_platform include file Update the soc_camera_platform header with licensing information. Signed-off-by: Magnus Damm Signed-off-by: Guennadi Liakhovetski --- linux/include/media/soc_camera_platform.h | 10 ++++++++++ 1 files changed, 10 insertions(+), 0 deletions(-) --- linux/include/media/soc_camera_platform.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'linux/include') diff --git a/linux/include/media/soc_camera_platform.h b/linux/include/media/soc_camera_platform.h index 7c81ad32b..1d092b467 100644 --- a/linux/include/media/soc_camera_platform.h +++ b/linux/include/media/soc_camera_platform.h @@ -1,3 +1,13 @@ +/* + * Generic Platform Camera Driver Header + * + * Copyright (C) 2008 Magnus Damm + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ + #ifndef __SOC_CAMERA_H__ #define __SOC_CAMERA_H__ -- cgit v1.2.3 From c8efc47aefa864b92537ab1470b913b20e8dcacd Mon Sep 17 00:00:00 2001 From: "darron@kewl.org" Date: Wed, 15 Oct 2008 17:43:41 +0100 Subject: videobuf: data storage optimisation From: Darron Broad To optimise data storage redundant vars are removed. Priority: normal Signed-off-by: Darron Broad Signed-off-by: Steven Toth --- linux/include/media/videobuf-dvb.h | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'linux/include') diff --git a/linux/include/media/videobuf-dvb.h b/linux/include/media/videobuf-dvb.h index 1a401f732..069215c77 100644 --- a/linux/include/media/videobuf-dvb.h +++ b/linux/include/media/videobuf-dvb.h @@ -16,7 +16,6 @@ struct videobuf_dvb { int nfeeds; /* videobuf_dvb_(un)register manges this */ - struct dvb_adapter adapter; struct dvb_demux demux; struct dmxdev dmxdev; struct dmx_frontend fe_hw; @@ -25,17 +24,17 @@ struct videobuf_dvb { }; struct videobuf_dvb_frontend { - void *dev; struct list_head felist; + void *dev; int id; struct videobuf_dvb dvb; }; struct videobuf_dvb_frontends { + struct list_head felist; struct mutex lock; struct dvb_adapter adapter; int active_fe_id; /* Indicates which frontend in the felist is in use */ - struct videobuf_dvb_frontend frontend; int gate; /* Frontend with gate control 0=!MFE,1=fe0,2=fe1 etc */ }; -- cgit v1.2.3 From cebcc9b2ede5e03540724cf09e8f9a39aeb99f8c Mon Sep 17 00:00:00 2001 From: "darron@kewl.org" Date: Wed, 15 Oct 2008 18:14:30 +0100 Subject: tuner: add FMD1216MEX tuner From: Darron Broad This tuner was already supported by proxy as an FMD1216ME, however, the MEX uses a different FM Radio IF so this addition is now required. Priority: normal Signed-off-by: Darron Broad Signed-off-by: Steven Toth --- linux/include/media/tuner.h | 1 + 1 file changed, 1 insertion(+) (limited to 'linux/include') diff --git a/linux/include/media/tuner.h b/linux/include/media/tuner.h index 67c1f514d..7d4e2db78 100644 --- a/linux/include/media/tuner.h +++ b/linux/include/media/tuner.h @@ -123,6 +123,7 @@ #define TUNER_TEA5761 75 /* Only FM Radio Tuner */ #define TUNER_XC5000 76 /* Xceive Silicon Tuner */ #define TUNER_TCL_MF02GIP_5N 77 /* TCL MF02GIP_5N */ +#define TUNER_PHILIPS_FMD1216MEX_MK3 78 /* tv card specific */ #define TDA9887_PRESENT (1<<0) -- cgit v1.2.3 From a02327e81915e000e69a6db7297d68d578b8df97 Mon Sep 17 00:00:00 2001 From: "darron@kewl.org" Date: Thu, 16 Oct 2008 00:26:34 +0100 Subject: videobuf: data storage optimisation (2) From: Darron Broad To optimise data storage even further one other redundant var has been removed. This also removes a redundant assignment. Priority: normal Signed-off-by: Darron Broad iSigned-off-by: Steven Toth --- linux/include/media/videobuf-dvb.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'linux/include') diff --git a/linux/include/media/videobuf-dvb.h b/linux/include/media/videobuf-dvb.h index 069215c77..52ddda90d 100644 --- a/linux/include/media/videobuf-dvb.h +++ b/linux/include/media/videobuf-dvb.h @@ -25,7 +25,6 @@ struct videobuf_dvb { struct videobuf_dvb_frontend { struct list_head felist; - void *dev; int id; struct videobuf_dvb dvb; }; @@ -57,7 +56,7 @@ int videobuf_dvb_register_adapter(struct videobuf_dvb_frontends *f, int videobuf_dvb_register_frontend(struct dvb_adapter *adapter, struct videobuf_dvb *dvb); -struct videobuf_dvb_frontend * videobuf_dvb_alloc_frontend(void *private, struct videobuf_dvb_frontends *f, int id); +struct videobuf_dvb_frontend * videobuf_dvb_alloc_frontend(struct videobuf_dvb_frontends *f, int id); struct videobuf_dvb_frontend * videobuf_dvb_get_frontend(struct videobuf_dvb_frontends *f, int id); int videobuf_dvb_find_frontend(struct videobuf_dvb_frontends *f, struct dvb_frontend *p); -- cgit v1.2.3 From dbf01b0d5f7a9f80a76840c00b032527cf0f5c09 Mon Sep 17 00:00:00 2001 From: Mauro Carvalho Chehab Date: Fri, 17 Oct 2008 13:02:47 -0300 Subject: videobuf-dvb: two functions are now static From: Mauro Carvalho Chehab This patch marks those two functions as static: static int videobuf_dvb_register_adapter(struct videobuf_dvb_frontends *fe, static int videobuf_dvb_register_frontend(struct dvb_adapter *adapter, Since MFE patches changed their calls by videobuf_dvb_register_bus. To avoid having to declare the prototypes, the patch moves videobuf_dvb_register_bus() to be after the declaration of the above functions used there. Priority: normal CC: Steven Toth Signed-off-by: Mauro Carvalho Chehab --- linux/include/media/videobuf-dvb.h | 10 ---------- 1 file changed, 10 deletions(-) (limited to 'linux/include') diff --git a/linux/include/media/videobuf-dvb.h b/linux/include/media/videobuf-dvb.h index 52ddda90d..80471c2b6 100644 --- a/linux/include/media/videobuf-dvb.h +++ b/linux/include/media/videobuf-dvb.h @@ -46,16 +46,6 @@ int videobuf_dvb_register_bus(struct videobuf_dvb_frontends *f, void videobuf_dvb_unregister_bus(struct videobuf_dvb_frontends *f); -int videobuf_dvb_register_adapter(struct videobuf_dvb_frontends *f, - struct module *module, - void *adapter_priv, - struct device *device, - char *adapter_name, - short *adapter_nr, - int mfe_shared); - -int videobuf_dvb_register_frontend(struct dvb_adapter *adapter, struct videobuf_dvb *dvb); - struct videobuf_dvb_frontend * videobuf_dvb_alloc_frontend(struct videobuf_dvb_frontends *f, int id); struct videobuf_dvb_frontend * videobuf_dvb_get_frontend(struct videobuf_dvb_frontends *f, int id); -- cgit v1.2.3 From 8d323d3fcc16d1ae16aa26da0d17bb1044b992a9 Mon Sep 17 00:00:00 2001 From: Hans Verkuil Date: Sat, 18 Oct 2008 17:23:45 +0200 Subject: v4l2-int-if: Add command to get slave private data. From: Sakari Ailus vidioc_int_g_priv is used to get master's slave-related private data structure. The structure can contain for example master's configuration specific to slave. Priority: normal Signed-off-by: Sakari Ailus Signed-off-by: Hans Verkuil --- linux/include/media/v4l2-int-device.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'linux/include') diff --git a/linux/include/media/v4l2-int-device.h b/linux/include/media/v4l2-int-device.h index c8b80e0f0..d9a005365 100644 --- a/linux/include/media/v4l2-int-device.h +++ b/linux/include/media/v4l2-int-device.h @@ -184,6 +184,11 @@ enum v4l2_int_ioctl_num { vidioc_int_dev_exit_num, /* Set device power state: 0 is off, non-zero is on. */ vidioc_int_s_power_num, + /* + * Get slave private data, e.g. platform-specific slave + * configuration used by the master. + */ + vidioc_int_g_priv_num, /* Get slave interface parameters. */ vidioc_int_g_ifparm_num, /* Does the slave need to be reset after VIDIOC_DQBUF? */ @@ -267,6 +272,7 @@ V4L2_INT_WRAPPER_1(s_parm, struct v4l2_streamparm, *); V4L2_INT_WRAPPER_0(dev_init); V4L2_INT_WRAPPER_0(dev_exit); V4L2_INT_WRAPPER_1(s_power, int, ); +V4L2_INT_WRAPPER_1(g_priv, void, *); V4L2_INT_WRAPPER_1(g_ifparm, struct v4l2_ifparm, *); V4L2_INT_WRAPPER_1(g_needs_reset, void, *); -- cgit v1.2.3 From ca1216c6fdfe83552ac10d39f6f1cce0a061636c Mon Sep 17 00:00:00 2001 From: Hans Verkuil Date: Sat, 18 Oct 2008 17:25:28 +0200 Subject: v4l2-int-if: Add cropcap, g_crop and s_crop commands. From: Sameer Venkatraman Priority: normal Signed-off-by: Sameer Venkatraman Signed-off-by: Mohit Jalori Signed-off-by: Hans Verkuil --- linux/include/media/v4l2-int-device.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'linux/include') diff --git a/linux/include/media/v4l2-int-device.h b/linux/include/media/v4l2-int-device.h index d9a005365..cee941c39 100644 --- a/linux/include/media/v4l2-int-device.h +++ b/linux/include/media/v4l2-int-device.h @@ -170,6 +170,9 @@ enum v4l2_int_ioctl_num { vidioc_int_queryctrl_num, vidioc_int_g_ctrl_num, vidioc_int_s_ctrl_num, + vidioc_int_cropcap_num, + vidioc_int_g_crop_num, + vidioc_int_s_crop_num, vidioc_int_g_parm_num, vidioc_int_s_parm_num, @@ -266,6 +269,9 @@ V4L2_INT_WRAPPER_1(try_fmt_cap, struct v4l2_format, *); V4L2_INT_WRAPPER_1(queryctrl, struct v4l2_queryctrl, *); V4L2_INT_WRAPPER_1(g_ctrl, struct v4l2_control, *); V4L2_INT_WRAPPER_1(s_ctrl, struct v4l2_control, *); +V4L2_INT_WRAPPER_1(cropcap, struct v4l2_cropcap, *); +V4L2_INT_WRAPPER_1(g_crop, struct v4l2_crop, *); +V4L2_INT_WRAPPER_1(s_crop, struct v4l2_crop, *); V4L2_INT_WRAPPER_1(g_parm, struct v4l2_streamparm, *); V4L2_INT_WRAPPER_1(s_parm, struct v4l2_streamparm, *); -- cgit v1.2.3 From ac78d9b2a6ad59c839beee937580024a04b1f77e Mon Sep 17 00:00:00 2001 From: Hans Verkuil Date: Sat, 18 Oct 2008 17:26:47 +0200 Subject: v4l2: Add 10-bit RAW Bayer formats From: Sergio Aguirre Add 10-bit raw bayer format expanded to 16 bits. Adds also definition for 10-bit raw bayer format dpcm-compressed to 8 bits. Priority: normal Signed-off-by: Sergio Aguirre Signed-off-by: Hans Verkuil --- linux/include/linux/videodev2.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'linux/include') diff --git a/linux/include/linux/videodev2.h b/linux/include/linux/videodev2.h index 63b2787e6..d633a786d 100644 --- a/linux/include/linux/videodev2.h +++ b/linux/include/linux/videodev2.h @@ -315,6 +315,13 @@ struct v4l2_pix_format { /* see http://www.siliconimaging.com/RGB%20Bayer.htm */ #define V4L2_PIX_FMT_SBGGR8 v4l2_fourcc('B', 'A', '8', '1') /* 8 BGBG.. GRGR.. */ #define V4L2_PIX_FMT_SGBRG8 v4l2_fourcc('G', 'B', 'R', 'G') /* 8 GBGB.. RGRG.. */ +/* + * 10bit raw bayer, expanded to 16 bits + * xxxxrrrrrrrrrrxxxxgggggggggg xxxxggggggggggxxxxbbbbbbbbbb... + */ +#define V4L2_PIX_FMT_SGRBG10 v4l2_fourcc('B', 'A', '1', '0') +/* 10bit raw bayer DPCM compressed to 8 bits */ +#define V4L2_PIX_FMT_SGRBG10DPCM8 v4l2_fourcc('B', 'D', '1', '0') #define V4L2_PIX_FMT_SBGGR16 v4l2_fourcc('B', 'Y', 'R', '2') /* 16 BGBG.. GRGR.. */ /* compressed formats */ -- cgit v1.2.3 From d3d1216cbe72328a396ecc76f9edc7dda77601df Mon Sep 17 00:00:00 2001 From: Hans Verkuil Date: Sat, 18 Oct 2008 17:27:50 +0200 Subject: v4l2-int-if: Define new power state changes From: Sakari Ailus Use enum v4l2_power instead of int as second argument to vidioc_int_s_power. The new functionality is that standby state is also recognised. Priority: normal Signed-off-by: Sakari Ailus Signed-off-by: Hans Verkuil --- linux/include/media/v4l2-int-device.h | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'linux/include') diff --git a/linux/include/media/v4l2-int-device.h b/linux/include/media/v4l2-int-device.h index cee941c39..3351dcffb 100644 --- a/linux/include/media/v4l2-int-device.h +++ b/linux/include/media/v4l2-int-device.h @@ -96,6 +96,12 @@ int v4l2_int_ioctl_1(struct v4l2_int_device *d, int cmd, void *arg); * */ +enum v4l2_power { + V4L2_POWER_OFF = 0, + V4L2_POWER_ON, + V4L2_POWER_STANDBY, +}; + /* Slave interface type. */ enum v4l2_if_type { /* @@ -185,7 +191,7 @@ enum v4l2_int_ioctl_num { vidioc_int_dev_init_num = 1000, /* Delinitialise the device at slave detach. */ vidioc_int_dev_exit_num, - /* Set device power state: 0 is off, non-zero is on. */ + /* Set device power state. */ vidioc_int_s_power_num, /* * Get slave private data, e.g. platform-specific slave @@ -277,7 +283,7 @@ V4L2_INT_WRAPPER_1(s_parm, struct v4l2_streamparm, *); V4L2_INT_WRAPPER_0(dev_init); V4L2_INT_WRAPPER_0(dev_exit); -V4L2_INT_WRAPPER_1(s_power, int, ); +V4L2_INT_WRAPPER_1(s_power, enum v4l2_power, ); V4L2_INT_WRAPPER_1(g_priv, void, *); V4L2_INT_WRAPPER_1(g_ifparm, struct v4l2_ifparm, *); V4L2_INT_WRAPPER_1(g_needs_reset, void, *); -- cgit v1.2.3 From 65aa32e2ff73aaa6f5ac4027e8265e0d81714f9e Mon Sep 17 00:00:00 2001 From: Hans Verkuil Date: Sat, 18 Oct 2008 17:28:36 +0200 Subject: v4l2-int-if: Export more interfaces to modules From: Sakari Ailus Export v4l2_int_device_try_attach_all. This allows initiating the initialisation of int if device after the drivers have been registered. Also allow drivers to call ioctls if v4l2-int-if was compiled as module. Priority: normal Signed-off-by: Sakari Ailus Signed-off-by: Hans Verkuil --- linux/include/media/v4l2-int-device.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'linux/include') diff --git a/linux/include/media/v4l2-int-device.h b/linux/include/media/v4l2-int-device.h index 3351dcffb..b5cee8909 100644 --- a/linux/include/media/v4l2-int-device.h +++ b/linux/include/media/v4l2-int-device.h @@ -84,6 +84,8 @@ struct v4l2_int_device { void *priv; }; +void v4l2_int_device_try_attach_all(void); + int v4l2_int_device_register(struct v4l2_int_device *d); void v4l2_int_device_unregister(struct v4l2_int_device *d); -- cgit v1.2.3 From edeea60fc1ac550b011e8fe6d2e720ece1f38990 Mon Sep 17 00:00:00 2001 From: Hans Verkuil Date: Sat, 18 Oct 2008 17:29:15 +0200 Subject: v4l2-int-if: Add enum_framesizes and enum_frameintervals ioctls. From: Sakari Ailus Priority: normal Signed-off-by: Sakari Ailus Signed-off-by: Hans Verkuil --- linux/include/media/v4l2-int-device.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'linux/include') diff --git a/linux/include/media/v4l2-int-device.h b/linux/include/media/v4l2-int-device.h index b5cee8909..9c2df41db 100644 --- a/linux/include/media/v4l2-int-device.h +++ b/linux/include/media/v4l2-int-device.h @@ -204,6 +204,8 @@ enum v4l2_int_ioctl_num { vidioc_int_g_ifparm_num, /* Does the slave need to be reset after VIDIOC_DQBUF? */ vidioc_int_g_needs_reset_num, + vidioc_int_enum_framesizes_num, + vidioc_int_enum_frameintervals_num, /* * @@ -289,6 +291,8 @@ V4L2_INT_WRAPPER_1(s_power, enum v4l2_power, ); V4L2_INT_WRAPPER_1(g_priv, void, *); V4L2_INT_WRAPPER_1(g_ifparm, struct v4l2_ifparm, *); V4L2_INT_WRAPPER_1(g_needs_reset, void, *); +V4L2_INT_WRAPPER_1(enum_framesizes, struct v4l2_frmsizeenum, *); +V4L2_INT_WRAPPER_1(enum_frameintervals, struct v4l2_frmivalenum, *); V4L2_INT_WRAPPER_0(reset); V4L2_INT_WRAPPER_0(init); -- cgit v1.2.3 From 90a1ccb93b663837f6e2dbed7762ca08d94fc493 Mon Sep 17 00:00:00 2001 From: Hans Verkuil Date: Sat, 18 Oct 2008 18:39:53 +0200 Subject: v4l2: add video_ioctl2_unlocked for unlocked_ioctl support. From: Hans Verkuil Based on an older patch from Sakari Ailus. Priority: normal Signed-off-by: Hans Verkuil CC: Sakari Ailus --- linux/include/media/v4l2-ioctl.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'linux/include') diff --git a/linux/include/media/v4l2-ioctl.h b/linux/include/media/v4l2-ioctl.h index 0bef03add..3e11dfe38 100644 --- a/linux/include/media/v4l2-ioctl.h +++ b/linux/include/media/v4l2-ioctl.h @@ -285,7 +285,9 @@ extern long v4l_compat_ioctl32(struct file *file, unsigned int cmd, unsigned long arg); extern int video_ioctl2(struct inode *inode, struct file *file, - unsigned int cmd, unsigned long arg); + unsigned int cmd, unsigned long arg); +extern long video_ioctl2_unlocked(struct file *file, + unsigned int cmd, unsigned long arg); /* Include support for obsoleted stuff */ extern int video_usercopy(struct inode *inode, struct file *file, -- cgit v1.2.3 From 04aa4b62d67d07cdb0a26eff8eb37482dea62b42 Mon Sep 17 00:00:00 2001 From: Mauro Carvalho Chehab Date: Tue, 21 Oct 2008 12:27:20 -0200 Subject: Get rid of inode parameter at v4l_compat_translate_ioctl() From: Mauro Carvalho Chehab The inode parameter at v4l_compat_translate_ioctl() were just passed over several places just to keep compatible with fops.ioctl. However, it weren't used anywere. This patch gets hid of this unused parameter. Priority: normal CC: Laurent Pinchart CC: Mike Isely Signed-off-by: Mauro Carvalho Chehab --- linux/include/media/v4l2-ioctl.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'linux/include') diff --git a/linux/include/media/v4l2-ioctl.h b/linux/include/media/v4l2-ioctl.h index 3e11dfe38..7a919433a 100644 --- a/linux/include/media/v4l2-ioctl.h +++ b/linux/include/media/v4l2-ioctl.h @@ -271,13 +271,13 @@ extern const char *v4l2_field_names[]; extern const char *v4l2_type_names[]; /* Compatibility layer interface -- v4l1-compat module */ -typedef int (*v4l2_kioctl)(struct inode *inode, struct file *file, +typedef int (*v4l2_kioctl)(struct file *file, unsigned int cmd, void *arg); #ifdef CONFIG_VIDEO_V4L1_COMPAT -int v4l_compat_translate_ioctl(struct inode *inode, struct file *file, +int v4l_compat_translate_ioctl(struct file *file, int cmd, void *arg, v4l2_kioctl driver_ioctl); #else -#define v4l_compat_translate_ioctl(inode, file, cmd, arg, ioctl) (-EINVAL) +#define v4l_compat_translate_ioctl(file, cmd, arg, ioctl) (-EINVAL) #endif /* 32 Bits compatibility layer for 64 bits processors */ -- cgit v1.2.3 From 0510435b844435b557b8c02c5c7d2b0f958cd67a Mon Sep 17 00:00:00 2001 From: "darron@kewl.org" Date: Tue, 21 Oct 2008 15:28:46 +0100 Subject: videobuf: split unregister bus creating self-contained frontend de-allocator From: Darron Broad This creates a self contained frontend de-allocator for the instances where an adapter has not been registered yet frontend de-allocation may be required. Priority: normal Signed-off-by: Darron Broad --- linux/include/media/videobuf-dvb.h | 1 + 1 file changed, 1 insertion(+) (limited to 'linux/include') diff --git a/linux/include/media/videobuf-dvb.h b/linux/include/media/videobuf-dvb.h index 80471c2b6..6ba4f1271 100644 --- a/linux/include/media/videobuf-dvb.h +++ b/linux/include/media/videobuf-dvb.h @@ -47,6 +47,7 @@ int videobuf_dvb_register_bus(struct videobuf_dvb_frontends *f, void videobuf_dvb_unregister_bus(struct videobuf_dvb_frontends *f); struct videobuf_dvb_frontend * videobuf_dvb_alloc_frontend(struct videobuf_dvb_frontends *f, int id); +void videobuf_dvb_dealloc_frontends(struct videobuf_dvb_frontends *f); struct videobuf_dvb_frontend * videobuf_dvb_get_frontend(struct videobuf_dvb_frontends *f, int id); int videobuf_dvb_find_frontend(struct videobuf_dvb_frontends *f, struct dvb_frontend *p); -- cgit v1.2.3 From 9bb0976b93978009b15477a0809c54f5e6fe8594 Mon Sep 17 00:00:00 2001 From: Mauro Carvalho Chehab Date: Tue, 21 Oct 2008 12:58:39 -0200 Subject: Remove unused inode parameter from video_ioctl2 From: Mauro Carvalho Chehab inode is never used on video_ioctl2. Remove it and rename the function to __video_ioctl2. This allows its usage directly as a callback at fops.unlocked_ioctl. Since we still need a callback with inode to be used with fops.ioctl, this patch adds video_ioctl2() that is just a call to __video_ioctl2(). Also, this patch adds some comments about video_ioctl2 and __video_ioctl2 usage at v4l2-ioctl.h. Priority: normal Signed-off-by: Mauro Carvalho Chehab --- linux/include/media/v4l2-ioctl.h | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) (limited to 'linux/include') diff --git a/linux/include/media/v4l2-ioctl.h b/linux/include/media/v4l2-ioctl.h index 7a919433a..e6ba25b3d 100644 --- a/linux/include/media/v4l2-ioctl.h +++ b/linux/include/media/v4l2-ioctl.h @@ -284,15 +284,25 @@ int v4l_compat_translate_ioctl(struct file *file, extern long v4l_compat_ioctl32(struct file *file, unsigned int cmd, unsigned long arg); -extern int video_ioctl2(struct inode *inode, struct file *file, - unsigned int cmd, unsigned long arg); -extern long video_ioctl2_unlocked(struct file *file, - unsigned int cmd, unsigned long arg); - /* Include support for obsoleted stuff */ extern int video_usercopy(struct inode *inode, struct file *file, unsigned int cmd, unsigned long arg, int (*func)(struct inode *inode, struct file *file, unsigned int cmd, void *arg)); +/* Standard handlers for V4L ioctl's */ + +/* This prototype is used on fops.unlocked_ioctl */ +extern int __video_ioctl2(struct file *file, + unsigned int cmd, unsigned long arg); + +/* This prototype is used on fops.ioctl + * Since fops.ioctl enables Kernel Big Lock, it is preferred + * to use __video_ioctl2 instead. + * It should be noticed that there's no lock code inside + * video_ioctl2(). + */ +extern int video_ioctl2(struct inode *inode, struct file *file, + unsigned int cmd, unsigned long arg); + #endif /* _V4L2_IOCTL_H */ -- cgit v1.2.3 From d1fc6a002a584175f0fee4f7e5e2bd94fcfe0bfc Mon Sep 17 00:00:00 2001 From: Mauro Carvalho Chehab Date: Tue, 21 Oct 2008 16:57:54 -0200 Subject: A small sync from kernel tree From: Mauro Carvalho Chehab Just replace to __func__ on a comented printk msg kernel-sync: Priority: normal Signed-off-by: Mauro Carvalho Chehab --- linux/include/media/saa7146.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'linux/include') diff --git a/linux/include/media/saa7146.h b/linux/include/media/saa7146.h index 23b45cb65..8034124f1 100644 --- a/linux/include/media/saa7146.h +++ b/linux/include/media/saa7146.h @@ -25,7 +25,7 @@ extern unsigned int saa7146_debug; -//#define DEBUG_PROLOG printk("(0x%08x)(0x%08x) %s: %s(): ",(dev==0?-1:(dev->mem==0?-1:saa7146_read(dev,RPS_ADDR0))),(dev==0?-1:(dev->mem==0?-1:saa7146_read(dev,IER))),KBUILD_MODNAME,__FUNCTION__) +//#define DEBUG_PROLOG printk("(0x%08x)(0x%08x) %s: %s(): ",(dev==0?-1:(dev->mem==0?-1:saa7146_read(dev,RPS_ADDR0))),(dev==0?-1:(dev->mem==0?-1:saa7146_read(dev,IER))),KBUILD_MODNAME,__func__) #ifndef DEBUG_VARIABLE #define DEBUG_VARIABLE saa7146_debug -- cgit v1.2.3