diff options
author | Mauro Carvalho Chehab <mchehab@redhat.com> | 2012-10-17 15:59:01 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2012-10-17 15:59:01 -0400 |
commit | fdd1eeb49d36fa79505f96de0f68e8d6768ab0b0 (patch) | |
tree | c9bd13d5cfd6ef0701752be40405962f4d1c507e /drivers/media/common | |
parent | 2c76a12ae9f5e6e2afc400bfbdd8b326e7d36b2a (diff) |
[media] siano: allow compiling it without RC support
Remote controller support should be optional on all drivers.
Make it optional at Siano's driver.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/common')
-rw-r--r-- | drivers/media/common/Kconfig | 7 | ||||
-rw-r--r-- | drivers/media/common/siano/Kconfig | 10 | ||||
-rw-r--r-- | drivers/media/common/siano/Makefile | 3 | ||||
-rw-r--r-- | drivers/media/common/siano/smsir.h | 9 |
4 files changed, 27 insertions, 2 deletions
diff --git a/drivers/media/common/Kconfig b/drivers/media/common/Kconfig index 121b0110af3c..d2a436ce77f8 100644 --- a/drivers/media/common/Kconfig +++ b/drivers/media/common/Kconfig | |||
@@ -1,3 +1,10 @@ | |||
1 | # Used by common drivers, when they need to ask questions | ||
2 | config MEDIA_COMMON_OPTIONS | ||
3 | bool | ||
4 | |||
5 | comment "common driver options" | ||
6 | depends on MEDIA_COMMON_OPTIONS | ||
7 | |||
1 | source "drivers/media/common/b2c2/Kconfig" | 8 | source "drivers/media/common/b2c2/Kconfig" |
2 | source "drivers/media/common/saa7146/Kconfig" | 9 | source "drivers/media/common/saa7146/Kconfig" |
3 | source "drivers/media/common/siano/Kconfig" | 10 | source "drivers/media/common/siano/Kconfig" |
diff --git a/drivers/media/common/siano/Kconfig b/drivers/media/common/siano/Kconfig index 425aeadfb49d..08d5b58dc672 100644 --- a/drivers/media/common/siano/Kconfig +++ b/drivers/media/common/siano/Kconfig | |||
@@ -4,7 +4,7 @@ | |||
4 | 4 | ||
5 | config SMS_SIANO_MDTV | 5 | config SMS_SIANO_MDTV |
6 | tristate | 6 | tristate |
7 | depends on DVB_CORE && RC_CORE && HAS_DMA | 7 | depends on DVB_CORE && HAS_DMA |
8 | depends on SMS_USB_DRV || SMS_SDIO_DRV | 8 | depends on SMS_USB_DRV || SMS_SDIO_DRV |
9 | default y | 9 | default y |
10 | ---help--- | 10 | ---help--- |
@@ -15,3 +15,11 @@ config SMS_SIANO_MDTV | |||
15 | 15 | ||
16 | Further documentation on this driver can be found on the WWW | 16 | Further documentation on this driver can be found on the WWW |
17 | at http://www.siano-ms.com/ | 17 | at http://www.siano-ms.com/ |
18 | config SMS_SIANO_RC | ||
19 | bool "Enable Remote Controller support for Siano devices" | ||
20 | depends on SMS_SIANO_MDTV && RC_CORE | ||
21 | depends on SMS_USB_DRV || SMS_SDIO_DRV | ||
22 | depends on MEDIA_COMMON_OPTIONS | ||
23 | default y | ||
24 | ---help--- | ||
25 | Choose Y to select Remote Controller support for Siano driver. | ||
diff --git a/drivers/media/common/siano/Makefile b/drivers/media/common/siano/Makefile index 2a09279e0648..0e6f5e927137 100644 --- a/drivers/media/common/siano/Makefile +++ b/drivers/media/common/siano/Makefile | |||
@@ -1,6 +1,7 @@ | |||
1 | smsmdtv-objs := smscoreapi.o sms-cards.o smsendian.o smsir.o | 1 | smsmdtv-objs := smscoreapi.o sms-cards.o smsendian.o |
2 | 2 | ||
3 | obj-$(CONFIG_SMS_SIANO_MDTV) += smsmdtv.o smsdvb.o | 3 | obj-$(CONFIG_SMS_SIANO_MDTV) += smsmdtv.o smsdvb.o |
4 | obj-$(CONFIG_SMS_SIANO_RC) += smsir.o | ||
4 | 5 | ||
5 | ccflags-y += -Idrivers/media/dvb-core | 6 | ccflags-y += -Idrivers/media/dvb-core |
6 | ccflags-y += $(extra-cflags-y) $(extra-cflags-m) | 7 | ccflags-y += $(extra-cflags-y) $(extra-cflags-m) |
diff --git a/drivers/media/common/siano/smsir.h b/drivers/media/common/siano/smsir.h index ae92b3a8587e..69b59b9eee28 100644 --- a/drivers/media/common/siano/smsir.h +++ b/drivers/media/common/siano/smsir.h | |||
@@ -46,10 +46,19 @@ struct ir_t { | |||
46 | u32 controller; | 46 | u32 controller; |
47 | }; | 47 | }; |
48 | 48 | ||
49 | #ifdef CONFIG_SMS_SIANO_RC | ||
49 | int sms_ir_init(struct smscore_device_t *coredev); | 50 | int sms_ir_init(struct smscore_device_t *coredev); |
50 | void sms_ir_exit(struct smscore_device_t *coredev); | 51 | void sms_ir_exit(struct smscore_device_t *coredev); |
51 | void sms_ir_event(struct smscore_device_t *coredev, | 52 | void sms_ir_event(struct smscore_device_t *coredev, |
52 | const char *buf, int len); | 53 | const char *buf, int len); |
54 | #else | ||
55 | inline static int sms_ir_init(struct smscore_device_t *coredev) { | ||
56 | return 0; | ||
57 | } | ||
58 | inline static void sms_ir_exit(struct smscore_device_t *coredev) {}; | ||
59 | inline static void sms_ir_event(struct smscore_device_t *coredev, | ||
60 | const char *buf, int len) {}; | ||
61 | #endif | ||
53 | 62 | ||
54 | #endif /* __SMS_IR_H__ */ | 63 | #endif /* __SMS_IR_H__ */ |
55 | 64 | ||