]> Git Repo - linux.git/commitdiff
[media] hdpvr-video: Use the proper check for I2C support
authorMauro Carvalho Chehab <[email protected]>
Thu, 21 Mar 2013 18:46:18 +0000 (15:46 -0300)
committerMauro Carvalho Chehab <[email protected]>
Sat, 23 Mar 2013 04:06:35 +0000 (01:06 -0300)
As reported by Geert Uytterhoeven <[email protected]>:
drivers/media/usb/hdpvr/hdpvr-video.c: warning: "CONFIG_I2C_MODULE" is not defined [-Wundef]

Reported-by: Geert Uytterhoeven <[email protected]>
Thanks-to: Randy Dunlap <[email protected]>
Signed-off-by: Mauro Carvalho Chehab <[email protected]>
drivers/media/usb/hdpvr/hdpvr-video.c

index da6b77912222421dffd5d808c4885c27d5647246..6a15405360dcd51af1fef2fb89e5f000d3f3334f 100644 (file)
@@ -10,6 +10,7 @@
  */
 
 #include <linux/kernel.h>
+#include <linux/kconfig.h>
 #include <linux/errno.h>
 #include <linux/init.h>
 #include <linux/slab.h>
@@ -1238,7 +1239,7 @@ static void hdpvr_device_release(struct video_device *vdev)
        v4l2_device_unregister(&dev->v4l2_dev);
 
        /* deregister I2C adapter */
-#if defined(CONFIG_I2C) || (CONFIG_I2C_MODULE)
+#if IS_ENABLED(CONFIG_I2C)
        mutex_lock(&dev->i2c_mutex);
        i2c_del_adapter(&dev->i2c_adapter);
        mutex_unlock(&dev->i2c_mutex);
This page took 0.057053 seconds and 4 git commands to generate.