OSDN Git Service

[media] tuner-core: fix compilation if the media controller is not defined
authorMauro Carvalho Chehab <mchehab@osg.samsung.com>
Wed, 18 Feb 2015 15:04:05 +0000 (12:04 -0300)
committerMauro Carvalho Chehab <mchehab@osg.samsung.com>
Thu, 26 Feb 2015 11:44:04 +0000 (08:44 -0300)
drivers/media/v4l2-core/tuner-core.c:440:7: error: 'struct v4l2_subdev' has no member named 'entity'
     t->sd.entity.name = t->name;

Reported-by: kbuild test robot <fengguang.wu@intel.com>
Acked-by: Lad, Prabhakar <prabhakar.csengg@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
drivers/media/v4l2-core/tuner-core.c

index 9a83b27..abdcffa 100644 (file)
@@ -437,7 +437,9 @@ static void set_type(struct i2c_client *c, unsigned int type,
                t->name = analog_ops->info.name;
        }
 
+#ifdef CONFIG_MEDIA_CONTROLLER
        t->sd.entity.name = t->name;
+#endif
 
        tuner_dbg("type set to %s\n", t->name);