Skip to contentSkip to conversation

gspca pac7302/pac7311: separate the two subdrivers

PATCH In review Németh Márton 1 participant 2 messages Oct 31, 2009 – Nov 1, 2009 Media (V4L/DVB)

lore
Share & tools
lore
#0 lore raw

PATCH 20/21 gspca pac7302/pac7311: separate the two subdrivers

From: Márton Németh <[email protected]>

All PAC7311 specific functions remain in pac7311.c. All PAC7302 specific functions are moved to pac7302.c. The USB device table is also divided into two parts. This makes it possible to remove the last sensor specific decision in sd_probe() functions.

The common functions are just copied to both subdrivers. These common functions can be separated later to a common file or helper module.

Cc Thomas Kaiser <[email protected]>
Cc Theodore Kilgore <[email protected]>
Cc Kyle Guinn <[email protected]>

---

drivers/media/video/gspca/Kconfig +9 -0
diff -uprN t/drivers/media/video/gspca/Kconfig u/drivers/media/video/gspca/Kconfig
@@ -103,6 +103,15 @@ config USB_GSPCA_PAC207
 	  To compile this driver as a module, choose M here: the
 	  module will be called gspca_pac207.
 
+config USB_GSPCA_PAC7302
+	tristate "Pixart PAC7302 USB Camera Driver"
+	depends on VIDEO_V4L2 && USB_GSPCA
+	help
+	  Say Y here if you want support for cameras based on the PAC7302 chip.
+
+	  To compile this driver as a module, choose M here: the
+	  module will be called gspca_pac7302.
+
 config USB_GSPCA_PAC7311
 	tristate "Pixart PAC7311 USB Camera Driver"
 	depends on VIDEO_V4L2 && USB_GSPCA
drivers/media/video/gspca/Makefile +2 -0
diff -uprN t/drivers/media/video/gspca/Makefile u/drivers/media/video/gspca/Makefile
@@ -8,6 +8,7 @@ obj-$(CONFIG_USB_GSPCA_MR97310A) += gspc
 obj-$(CONFIG_USB_GSPCA_OV519)    += gspca_ov519.o
 obj-$(CONFIG_USB_GSPCA_OV534)    += gspca_ov534.o
 obj-$(CONFIG_USB_GSPCA_PAC207)   += gspca_pac207.o
+obj-$(CONFIG_USB_GSPCA_PAC7302)  += gspca_pac7302.o
 obj-$(CONFIG_USB_GSPCA_PAC7311)  += gspca_pac7311.o
 obj-$(CONFIG_USB_GSPCA_SN9C20X)  += gspca_sn9c20x.o
 obj-$(CONFIG_USB_GSPCA_SONIXB)   += gspca_sonixb.o
@@ -37,6 +38,7 @@ gspca_mr97310a-objs := mr97310a.o
 gspca_ov519-objs    := ov519.o
 gspca_ov534-objs    := ov534.o
 gspca_pac207-objs   := pac207.o
+gspca_pac7302-objs  := pac7302.o
 gspca_pac7311-objs  := pac7311.o
 gspca_sn9c20x-objs  := sn9c20x.o
 gspca_sonixb-objs   := sonixb.o
drivers/media/video/gspca/pac7302.c +977 -0

977 lines not on this page · raw message

drivers/media/video/gspca/pac7311.c +3 -712

926 lines not on this page · raw message

#1 lore raw

From: Márton Németh <[email protected]>

All PAC7311 specific functions remain in pac7311.c. All PAC7302 specific functions are moved to pac7302.c. The USB device table is also divided into two parts. This makes it possible to remove the last sensor specific decision in sd_probe() functions.

The common functions are just copied to both subdrivers. These common functions can be separated later to a common file or helper module.

Cc Thomas Kaiser <[email protected]>
Cc Theodore Kilgore <[email protected]>
Cc Kyle Guinn <[email protected]>

---
Patch rebased to the latest http://linuxtv.org/hg/v4l-dvb/ (rev 13254).
---

drivers/media/video/gspca/Kconfig +9 -0
diff -uprN t/drivers/media/video/gspca/Kconfig u/drivers/media/video/gspca/Kconfig
@@ -104,6 +104,15 @@ config USB_GSPCA_PAC207
 	  To compile this driver as a module, choose M here: the
 	  module will be called gspca_pac207.
 
+config USB_GSPCA_PAC7302
+	tristate "Pixart PAC7302 USB Camera Driver"
+	depends on VIDEO_V4L2 && USB_GSPCA
+	help
+	  Say Y here if you want support for cameras based on the PAC7302 chip.
+
+	  To compile this driver as a module, choose M here: the
+	  module will be called gspca_pac7302.
+
 config USB_GSPCA_PAC7311
 	tristate "Pixart PAC7311 USB Camera Driver"
 	depends on VIDEO_V4L2 && USB_GSPCA
drivers/media/video/gspca/Makefile +2 -0
diff -uprN t/drivers/media/video/gspca/Makefile u/drivers/media/video/gspca/Makefile
@@ -8,6 +8,7 @@ obj-$(CONFIG_USB_GSPCA_MR97310A) += gspc
 obj-$(CONFIG_USB_GSPCA_OV519)    += gspca_ov519.o
 obj-$(CONFIG_USB_GSPCA_OV534)    += gspca_ov534.o
 obj-$(CONFIG_USB_GSPCA_PAC207)   += gspca_pac207.o
+obj-$(CONFIG_USB_GSPCA_PAC7302)  += gspca_pac7302.o
 obj-$(CONFIG_USB_GSPCA_PAC7311)  += gspca_pac7311.o
 obj-$(CONFIG_USB_GSPCA_SN9C20X)  += gspca_sn9c20x.o
 obj-$(CONFIG_USB_GSPCA_SONIXB)   += gspca_sonixb.o
@@ -38,6 +39,7 @@ gspca_mr97310a-objs := mr97310a.o
 gspca_ov519-objs    := ov519.o
 gspca_ov534-objs    := ov534.o
 gspca_pac207-objs   := pac207.o
+gspca_pac7302-objs  := pac7302.o
 gspca_pac7311-objs  := pac7311.o
 gspca_sn9c20x-objs  := sn9c20x.o
 gspca_sonixb-objs   := sonixb.o
drivers/media/video/gspca/pac7302.c +978 -0

978 lines not on this page · raw message

drivers/media/video/gspca/pac7311.c +3 -713

927 lines not on this page · raw message