]> bbs.cooldavid.org Git - net-next-2.6.git/blobdiff - drivers/media/video/bt8xx/bttv-i2c.c
V4L/DVB: bttv: Move I2C IR initialization
[net-next-2.6.git] / drivers / media / video / bt8xx / bttv-i2c.c
index 63aa31a041e848846998515f1b1dc825ebc62c5a..407fa61e4cdab12269358063b562157b1c6c0a31 100644 (file)
@@ -388,7 +388,12 @@ int __devinit init_bttv_i2c(struct bttv *btv)
        if (0 == btv->i2c_rc && i2c_scan)
                do_i2c_scan(btv->c.v4l2_dev.name, &btv->i2c_client);
 
-       /* Instantiate the IR receiver device, if present */
+       return btv->i2c_rc;
+}
+
+/* Instantiate the I2C IR receiver device, if present */
+void __devinit init_bttv_i2c_ir(struct bttv *btv)
+{
        if (0 == btv->i2c_rc) {
                struct i2c_board_info info;
                /* The external IR receiver is at i2c address 0x34 (0x35 for
@@ -408,7 +413,6 @@ int __devinit init_bttv_i2c(struct bttv *btv)
                strlcpy(info.type, "ir_video", I2C_NAME_SIZE);
                i2c_new_probed_device(&btv->c.i2c_adap, &info, addr_list);
        }
-       return btv->i2c_rc;
 }
 
 int __devexit fini_bttv_i2c(struct bttv *btv)