diff options
author | Antti Palosaari <crope@iki.fi> | 2012-12-09 18:23:22 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2013-01-06 07:17:26 -0500 |
commit | 7b75322af1bd3b365ce3a5f2ac6df329bf725656 (patch) | |
tree | 7309a83dd26c8f453b77e931261dab61522d6709 | |
parent | eed5670a31c511e196fd50fc591689ffdab61f80 (diff) |
[media] az6007: make remote controller optional
Do not compile remote controller when RC-core is disabled by Kconfig.
Signed-off-by: Antti Palosaari <crope@iki.fi>
Acked-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
-rw-r--r-- | drivers/media/usb/dvb-usb-v2/az6007.c | 26 |
1 files changed, 15 insertions, 11 deletions
diff --git a/drivers/media/usb/dvb-usb-v2/az6007.c b/drivers/media/usb/dvb-usb-v2/az6007.c index d75dbf27e99e..3b33f1ec2295 100644 --- a/drivers/media/usb/dvb-usb-v2/az6007.c +++ b/drivers/media/usb/dvb-usb-v2/az6007.c | |||
@@ -189,6 +189,7 @@ static int az6007_streaming_ctrl(struct dvb_frontend *fe, int onoff) | |||
189 | return az6007_write(d, 0xbc, onoff, 0, NULL, 0); | 189 | return az6007_write(d, 0xbc, onoff, 0, NULL, 0); |
190 | } | 190 | } |
191 | 191 | ||
192 | #if defined(CONFIG_RC_CORE) || defined(CONFIG_RC_CORE_MODULE) | ||
192 | /* remote control stuff (does not work with my box) */ | 193 | /* remote control stuff (does not work with my box) */ |
193 | static int az6007_rc_query(struct dvb_usb_device *d) | 194 | static int az6007_rc_query(struct dvb_usb_device *d) |
194 | { | 195 | { |
@@ -215,6 +216,20 @@ static int az6007_rc_query(struct dvb_usb_device *d) | |||
215 | return 0; | 216 | return 0; |
216 | } | 217 | } |
217 | 218 | ||
219 | static int az6007_get_rc_config(struct dvb_usb_device *d, struct dvb_usb_rc *rc) | ||
220 | { | ||
221 | pr_debug("Getting az6007 Remote Control properties\n"); | ||
222 | |||
223 | rc->allowed_protos = RC_BIT_NEC; | ||
224 | rc->query = az6007_rc_query; | ||
225 | rc->interval = 400; | ||
226 | |||
227 | return 0; | ||
228 | } | ||
229 | #else | ||
230 | #define az6007_get_rc_config NULL | ||
231 | #endif | ||
232 | |||
218 | static int az6007_ci_read_attribute_mem(struct dvb_ca_en50221 *ca, | 233 | static int az6007_ci_read_attribute_mem(struct dvb_ca_en50221 *ca, |
219 | int slot, | 234 | int slot, |
220 | int address) | 235 | int address) |
@@ -822,17 +837,6 @@ static void az6007_usb_disconnect(struct usb_interface *intf) | |||
822 | dvb_usbv2_disconnect(intf); | 837 | dvb_usbv2_disconnect(intf); |
823 | } | 838 | } |
824 | 839 | ||
825 | static int az6007_get_rc_config(struct dvb_usb_device *d, struct dvb_usb_rc *rc) | ||
826 | { | ||
827 | pr_debug("Getting az6007 Remote Control properties\n"); | ||
828 | |||
829 | rc->allowed_protos = RC_BIT_NEC; | ||
830 | rc->query = az6007_rc_query; | ||
831 | rc->interval = 400; | ||
832 | |||
833 | return 0; | ||
834 | } | ||
835 | |||
836 | static int az6007_download_firmware(struct dvb_usb_device *d, | 840 | static int az6007_download_firmware(struct dvb_usb_device *d, |
837 | const struct firmware *fw) | 841 | const struct firmware *fw) |
838 | { | 842 | { |