diff options
author | Mauro Carvalho Chehab <mchehab@redhat.com> | 2010-09-29 13:41:52 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2010-10-20 23:06:09 -0400 |
commit | 896c1422ed49961bf32c980a57218d8c5f8ce3bd (patch) | |
tree | 637d0c64bcabe1aaa3e0d6a434feb8616d9da5a8 | |
parent | e051f69ae3ef9bd87977d7473bf82e2080e37044 (diff) |
V4L/DVB: saa7134: split RC code into a different module
This allows the removal of CONFIG_INPUT from saa7134, and
helps to create a better Kconfig dependency hierarchy.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
-rw-r--r-- | drivers/media/video/saa7134/Kconfig | 14 | ||||
-rw-r--r-- | drivers/media/video/saa7134/Makefile | 6 | ||||
-rw-r--r-- | drivers/media/video/saa7134/saa7134-input.c | 5 | ||||
-rw-r--r-- | drivers/media/video/saa7134/saa7134.h | 16 |
4 files changed, 30 insertions, 11 deletions
diff --git a/drivers/media/video/saa7134/Kconfig b/drivers/media/video/saa7134/Kconfig index fda005e01670..892b0b180938 100644 --- a/drivers/media/video/saa7134/Kconfig +++ b/drivers/media/video/saa7134/Kconfig | |||
@@ -1,8 +1,7 @@ | |||
1 | config VIDEO_SAA7134 | 1 | config VIDEO_SAA7134 |
2 | tristate "Philips SAA7134 support" | 2 | tristate "Philips SAA7134 support" |
3 | depends on VIDEO_DEV && PCI && I2C && INPUT | 3 | depends on VIDEO_DEV && PCI && I2C |
4 | select VIDEOBUF_DMA_SG | 4 | select VIDEOBUF_DMA_SG |
5 | depends on VIDEO_IR | ||
6 | select VIDEO_TUNER | 5 | select VIDEO_TUNER |
7 | select VIDEO_TVEEPROM | 6 | select VIDEO_TVEEPROM |
8 | select CRC32 | 7 | select CRC32 |
@@ -25,6 +24,17 @@ config VIDEO_SAA7134_ALSA | |||
25 | To compile this driver as a module, choose M here: the | 24 | To compile this driver as a module, choose M here: the |
26 | module will be called saa7134-alsa. | 25 | module will be called saa7134-alsa. |
27 | 26 | ||
27 | config VIDEO_SAA7134_RC | ||
28 | tristate "Philips SAA7134 Remote Controller support" | ||
29 | depends on VIDEO_IR | ||
30 | depends on VIDEO_SAA7134 | ||
31 | default y | ||
32 | ---help--- | ||
33 | Enables Remote Controller support for saa7134. | ||
34 | |||
35 | To compile this driver as a module, choose M here: the | ||
36 | module will be called saa7134-rc. | ||
37 | |||
28 | config VIDEO_SAA7134_DVB | 38 | config VIDEO_SAA7134_DVB |
29 | tristate "DVB/ATSC Support for saa7134 based TV cards" | 39 | tristate "DVB/ATSC Support for saa7134 based TV cards" |
30 | depends on VIDEO_SAA7134 && DVB_CORE | 40 | depends on VIDEO_SAA7134 && DVB_CORE |
diff --git a/drivers/media/video/saa7134/Makefile b/drivers/media/video/saa7134/Makefile index 604158a8c235..562446800f0e 100644 --- a/drivers/media/video/saa7134/Makefile +++ b/drivers/media/video/saa7134/Makefile | |||
@@ -1,7 +1,9 @@ | |||
1 | 1 | ||
2 | saa7134-objs := saa7134-cards.o saa7134-core.o saa7134-i2c.o \ | 2 | saa7134-objs := saa7134-cards.o saa7134-core.o saa7134-i2c.o \ |
3 | saa7134-ts.o saa7134-tvaudio.o saa7134-vbi.o \ | 3 | saa7134-ts.o saa7134-tvaudio.o saa7134-vbi.o \ |
4 | saa7134-video.o saa7134-input.o | 4 | saa7134-video.o |
5 | |||
6 | saa7134-rc-objs := saa7134-input.o | ||
5 | 7 | ||
6 | obj-$(CONFIG_VIDEO_SAA7134) += saa6752hs.o saa7134.o saa7134-empress.o | 8 | obj-$(CONFIG_VIDEO_SAA7134) += saa6752hs.o saa7134.o saa7134-empress.o |
7 | 9 | ||
@@ -9,6 +11,8 @@ obj-$(CONFIG_VIDEO_SAA7134_ALSA) += saa7134-alsa.o | |||
9 | 11 | ||
10 | obj-$(CONFIG_VIDEO_SAA7134_DVB) += saa7134-dvb.o | 12 | obj-$(CONFIG_VIDEO_SAA7134_DVB) += saa7134-dvb.o |
11 | 13 | ||
14 | obj-$(CONFIG_VIDEO_SAA7134_RC) += saa7134-rc.o | ||
15 | |||
12 | EXTRA_CFLAGS += -Idrivers/media/video | 16 | EXTRA_CFLAGS += -Idrivers/media/video |
13 | EXTRA_CFLAGS += -Idrivers/media/common/tuners | 17 | EXTRA_CFLAGS += -Idrivers/media/common/tuners |
14 | EXTRA_CFLAGS += -Idrivers/media/dvb/dvb-core | 18 | EXTRA_CFLAGS += -Idrivers/media/dvb/dvb-core |
diff --git a/drivers/media/video/saa7134/saa7134-input.c b/drivers/media/video/saa7134/saa7134-input.c index 3a0ea56f27ff..a6ac46211217 100644 --- a/drivers/media/video/saa7134/saa7134-input.c +++ b/drivers/media/video/saa7134/saa7134-input.c | |||
@@ -28,7 +28,7 @@ | |||
28 | #include "saa7134-reg.h" | 28 | #include "saa7134-reg.h" |
29 | #include "saa7134.h" | 29 | #include "saa7134.h" |
30 | 30 | ||
31 | #define MODULE_NAME "saa7134" | 31 | #define MODULE_NAME "saa7134-rc" |
32 | 32 | ||
33 | static unsigned int disable_ir; | 33 | static unsigned int disable_ir; |
34 | module_param(disable_ir, int, 0444); | 34 | module_param(disable_ir, int, 0444); |
@@ -1211,3 +1211,6 @@ static int saa7134_nec_irq(struct saa7134_dev *dev) | |||
1211 | 1211 | ||
1212 | return 1; | 1212 | return 1; |
1213 | } | 1213 | } |
1214 | |||
1215 | MODULE_LICENSE("GPL"); | ||
1216 | MODULE_AUTHOR("Mauro Carvalho Chehab <mchehab@redhat.com>"); | ||
diff --git a/drivers/media/video/saa7134/saa7134.h b/drivers/media/video/saa7134/saa7134.h index c040a1808542..99f122b0ce95 100644 --- a/drivers/media/video/saa7134/saa7134.h +++ b/drivers/media/video/saa7134/saa7134.h | |||
@@ -810,16 +810,18 @@ void saa7134_irq_oss_done(struct saa7134_dev *dev, unsigned long status); | |||
810 | /* ----------------------------------------------------------- */ | 810 | /* ----------------------------------------------------------- */ |
811 | /* saa7134-input.c */ | 811 | /* saa7134-input.c */ |
812 | 812 | ||
813 | #if defined(CONFIG_VIDEO_SAA7134_RC) || (defined(CONFIG_VIDEO_SAA7134_RC_MODULE) && defined(MODULE)) | ||
813 | int saa7134_input_init1(struct saa7134_dev *dev); | 814 | int saa7134_input_init1(struct saa7134_dev *dev); |
814 | void saa7134_input_fini(struct saa7134_dev *dev); | 815 | void saa7134_input_fini(struct saa7134_dev *dev); |
815 | void saa7134_input_irq(struct saa7134_dev *dev); | 816 | void saa7134_input_irq(struct saa7134_dev *dev); |
816 | void saa7134_probe_i2c_ir(struct saa7134_dev *dev); | 817 | void saa7134_probe_i2c_ir(struct saa7134_dev *dev); |
817 | int saa7134_ir_start(struct saa7134_dev *dev); | 818 | int saa7134_ir_start(struct saa7134_dev *dev); |
818 | void saa7134_ir_stop(struct saa7134_dev *dev); | 819 | void saa7134_ir_stop(struct saa7134_dev *dev); |
819 | 820 | #else | |
820 | 821 | #define saa7134_input_init1(dev) (0) | |
821 | /* | 822 | #define saa7134_input_fini(dev) (0) |
822 | * Local variables: | 823 | #define saa7134_input_irq(dev) (0) |
823 | * c-basic-offset: 8 | 824 | #define saa7134_probe_i2c_ir(dev) (0) |
824 | * End: | 825 | #define saa7134_ir_start(dev) (0) |
825 | */ | 826 | #define saa7134_ir_stop(dev) (0) |
827 | #endif | ||