[media] media: rc: remove unneeded code
authorHeiner Kallweit <hkallweit1@gmail.com>
Sat, 21 Nov 2015 14:55:03 +0000 (12:55 -0200)
committerMauro Carvalho Chehab <mchehab@osg.samsung.com>
Thu, 3 Dec 2015 17:01:11 +0000 (15:01 -0200)
Now that that the decoder modules are loaded on-demand we can move
loading the lirc module to rc_register_device directly and remove
unneeded functions and comments.

Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
drivers/media/rc/rc-core-priv.h
drivers/media/rc/rc-ir-raw.c
drivers/media/rc/rc-main.c

index 071651ad78051fe3ce7ef51ff1a6e8976d110d64..7359f3d03b647244baeb8c99ad7076e9a11ba74d 100644 (file)
@@ -167,11 +167,4 @@ void ir_raw_init(void);
  * loads the compiled decoders for their usage with IR raw events
  */
 
-/* from ir-lirc-codec.c */
-#ifdef CONFIG_IR_LIRC_CODEC_MODULE
-#define load_lirc_codec()      request_module_nowait("ir-lirc-codec")
-#else
-static inline void load_lirc_codec(void) { }
-#endif
-
 #endif /* _RC_CORE_PRIV */
index c6433e8f03b851927c6c7925b00ec6feb2e54ee4..c69807fe2feff08c47441dc2bf3c780c4440d505 100644 (file)
@@ -360,13 +360,3 @@ void ir_raw_handler_unregister(struct ir_raw_handler *ir_raw_handler)
        mutex_unlock(&ir_raw_handler_lock);
 }
 EXPORT_SYMBOL(ir_raw_handler_unregister);
-
-void ir_raw_init(void)
-{
-       /* Load the decoder modules */
-       load_lirc_codec();
-
-       /* If needed, we may later add some init code. In this case,
-          it is needed to change the CONFIG_MODULE test at rc-core.h
-        */
-}
index 9d05d03caa13b68e8983afffc7dcd47c3a73d64c..1042fa331a0749284762b33a83fd1ac1600548c7 100644 (file)
@@ -1471,10 +1471,8 @@ int rc_register_device(struct rc_dev *dev)
        kfree(path);
 
        if (dev->driver_type == RC_DRIVER_IR_RAW) {
-               /* Load raw decoders, if they aren't already */
                if (!raw_init) {
-                       IR_dprintk(1, "Loading raw decoders\n");
-                       ir_raw_init();
+                       request_module_nowait("ir-lirc-codec");
                        raw_init = true;
                }
                /* calls ir_register_device so unlock mutex here*/
This page took 0.026596 seconds and 5 git commands to generate.