aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/dvb-core/dvbdev.h
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@osg.samsung.com>2015-12-29 11:52:23 -0200
committerMauro Carvalho Chehab <mchehab@osg.samsung.com>2016-01-11 12:19:25 -0200
commit0230d60e4661d9ced6fb0b9a30f182ebdafbba7a (patch)
tree7d9d8e71ba103473fe276b1c49040bfb72230f44 /drivers/media/dvb-core/dvbdev.h
parent[media] dvbdev: remove two dead functions if !CONFIG_MEDIA_CONTROLLER_DVB (diff)
downloadlinux-dev-0230d60e4661d9ced6fb0b9a30f182ebdafbba7a.tar.xz
linux-dev-0230d60e4661d9ced6fb0b9a30f182ebdafbba7a.zip
[media] dvbdev: Add RF connector if needed
Several pure digital TV devices have a frontend with the tuner integrated on it. Add the RF connector when dvb_create_media_graph() is called on such devices. Tested with siano and dvb_usb_mxl111sf drivers. Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Diffstat (limited to 'drivers/media/dvb-core/dvbdev.h')
-rw-r--r--drivers/media/dvb-core/dvbdev.h20
1 files changed, 18 insertions, 2 deletions
diff --git a/drivers/media/dvb-core/dvbdev.h b/drivers/media/dvb-core/dvbdev.h
index abee18a402e1..b622d6a3b95e 100644
--- a/drivers/media/dvb-core/dvbdev.h
+++ b/drivers/media/dvb-core/dvbdev.h
@@ -75,6 +75,9 @@ struct dvb_frontend;
* used.
* @mdev: pointer to struct media_device, used when the media
* controller is used.
+ * @conn: RF connector. Used only if the device has no separate
+ * tuner.
+ * @conn_pads: pointer to struct media_pad associated with @conn;
*/
struct dvb_adapter {
int num;
@@ -94,6 +97,8 @@ struct dvb_adapter {
#if defined(CONFIG_MEDIA_CONTROLLER_DVB)
struct media_device *mdev;
+ struct media_entity *conn;
+ struct media_pad *conn_pads;
#endif
};
@@ -214,7 +219,16 @@ int dvb_register_device(struct dvb_adapter *adap,
void dvb_unregister_device(struct dvb_device *dvbdev);
#ifdef CONFIG_MEDIA_CONTROLLER_DVB
-__must_check int dvb_create_media_graph(struct dvb_adapter *adap);
+/**
+ * dvb_create_media_graph - Creates media graph for the Digital TV part of the
+ * device.
+ *
+ * @adap: pointer to struct dvb_adapter
+ * @create_rf_connector: if true, it creates the RF connector too
+ */
+__must_check int dvb_create_media_graph(struct dvb_adapter *adap,
+ bool create_rf_connector);
+
static inline void dvb_register_media_controller(struct dvb_adapter *adap,
struct media_device *mdev)
{
@@ -222,7 +236,9 @@ static inline void dvb_register_media_controller(struct dvb_adapter *adap,
}
#else
-static inline int dvb_create_media_graph(struct dvb_adapter *adap)
+static inline
+int dvb_create_media_graph(struct dvb_adapter *adap,
+ bool create_rf_connector)
{
return 0;
};