diff options
author | Jean-Francois Moine <moinejf@free.fr> | 2008-07-05 10:49:20 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2008-07-20 06:17:15 -0400 |
commit | c2446b3eba97243acbe2ad0939a28b5edb97eae7 (patch) | |
tree | f7ff764cf48062c4ef7c243205b85ae73d69763e /drivers/media/video/gspca/sonixb.c | |
parent | efab8211db79d20032fa7d09b8a3671e68a9c5b9 (diff) |
V4L/DVB (8201): gspca: v4l2_pix_format in each subdriver.
main: Parameter comp_fac removed.
main, pac207:
get_buff_size op removed.
(all) v4l2_pix_format in each subdriver.
Signed-off-by: Jean-Francois Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/gspca/sonixb.c')
-rw-r--r-- | drivers/media/video/gspca/sonixb.c | 41 |
1 files changed, 30 insertions, 11 deletions
diff --git a/drivers/media/video/gspca/sonixb.c b/drivers/media/video/gspca/sonixb.c index 4baac51bf40a..574568736317 100644 --- a/drivers/media/video/gspca/sonixb.c +++ b/drivers/media/video/gspca/sonixb.c | |||
@@ -24,8 +24,8 @@ | |||
24 | 24 | ||
25 | #include "gspca.h" | 25 | #include "gspca.h" |
26 | 26 | ||
27 | #define DRIVER_VERSION_NUMBER KERNEL_VERSION(2, 1, 3) | 27 | #define DRIVER_VERSION_NUMBER KERNEL_VERSION(2, 1, 5) |
28 | static const char version[] = "2.1.3"; | 28 | static const char version[] = "2.1.5"; |
29 | 29 | ||
30 | MODULE_AUTHOR("Michel Xhaard <mxhaard@users.sourceforge.net>"); | 30 | MODULE_AUTHOR("Michel Xhaard <mxhaard@users.sourceforge.net>"); |
31 | MODULE_DESCRIPTION("GSPCA/SN9C102 USB Camera Driver"); | 31 | MODULE_DESCRIPTION("GSPCA/SN9C102 USB Camera Driver"); |
@@ -95,15 +95,34 @@ static struct ctrl sd_ctrls[] = { | |||
95 | }, | 95 | }, |
96 | }; | 96 | }; |
97 | 97 | ||
98 | /* fixme: should have V4L2_PIX_FMT_SN9C10X */ | 98 | static struct v4l2_pix_format vga_mode[] = { |
99 | static struct cam_mode vga_mode[] = { | 99 | {160, 120, V4L2_PIX_FMT_SN9C10X, V4L2_FIELD_NONE, |
100 | {V4L2_PIX_FMT_SN9C10X, 160, 120, 2}, | 100 | .bytesperline = 160, |
101 | {V4L2_PIX_FMT_SN9C10X, 320, 240, 1}, | 101 | .sizeimage = 160 * 120, |
102 | {V4L2_PIX_FMT_SN9C10X, 640, 480, 0}, | 102 | .colorspace = V4L2_COLORSPACE_SRGB, |
103 | .priv = 2}, | ||
104 | {320, 240, V4L2_PIX_FMT_SN9C10X, V4L2_FIELD_NONE, | ||
105 | .bytesperline = 320, | ||
106 | .sizeimage = 320 * 240, | ||
107 | .colorspace = V4L2_COLORSPACE_SRGB, | ||
108 | .priv = 1}, | ||
109 | {640, 480, V4L2_PIX_FMT_SN9C10X, V4L2_FIELD_NONE, | ||
110 | .bytesperline = 640, | ||
111 | .sizeimage = 640 * 480, | ||
112 | .colorspace = V4L2_COLORSPACE_SRGB, | ||
113 | .priv = 0}, | ||
103 | }; | 114 | }; |
104 | static struct cam_mode sif_mode[] = { | 115 | static struct v4l2_pix_format sif_mode[] = { |
105 | {V4L2_PIX_FMT_SN9C10X, 176, 144, 1}, | 116 | {176, 144, V4L2_PIX_FMT_SN9C10X, V4L2_FIELD_NONE, |
106 | {V4L2_PIX_FMT_SN9C10X, 352, 288, 0}, | 117 | .bytesperline = 176, |
118 | .sizeimage = 176 * 144, | ||
119 | .colorspace = V4L2_COLORSPACE_SRGB, | ||
120 | .priv = 1}, | ||
121 | {352, 288, V4L2_PIX_FMT_SN9C10X, V4L2_FIELD_NONE, | ||
122 | .bytesperline = 352, | ||
123 | .sizeimage = 352 * 288, | ||
124 | .colorspace = V4L2_COLORSPACE_SRGB, | ||
125 | .priv = 0}, | ||
107 | }; | 126 | }; |
108 | 127 | ||
109 | static const __u8 probe_ov7630[] = {0x08, 0x44}; | 128 | static const __u8 probe_ov7630[] = {0x08, 0x44}; |
@@ -592,7 +611,7 @@ static void sd_start(struct gspca_dev *gspca_dev) | |||
592 | __u8 reg01, reg17; | 611 | __u8 reg01, reg17; |
593 | __u8 reg17_19[3]; | 612 | __u8 reg17_19[3]; |
594 | 613 | ||
595 | mode = gspca_dev->cam.cam_mode[(int) gspca_dev->curr_mode].mode; | 614 | mode = gspca_dev->cam.cam_mode[(int) gspca_dev->curr_mode].priv; |
596 | switch (sd->sensor) { | 615 | switch (sd->sensor) { |
597 | case SENSOR_HV7131R: | 616 | case SENSOR_HV7131R: |
598 | sn9c10x = initHv7131; | 617 | sn9c10x = initHv7131; |