summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorSteven Toth <stoth@linuxtv.org>2008-09-26 00:29:49 -0300
committerMauro Carvalho Chehab <mchehab@redhat.com>2008-10-12 09:37:11 -0200
commiteacf8d8d6bc6798f6870a2cf2c159bfcde3759ac (patch)
treeb3c7d3d709a8754f22b6385c70b6ac4bfb4d4f88 /drivers
parentd48cb402a1ba48c4ad4a36c3c561386027318459 (diff)
downloadblackbird-op-linux-eacf8d8d6bc6798f6870a2cf2c159bfcde3759ac.tar.gz
blackbird-op-linux-eacf8d8d6bc6798f6870a2cf2c159bfcde3759ac.zip
V4L/DVB (9072): S2API: Add DTV_API_VERSION command
This allows application developers to query the dvb-core API version dynamically, helping developers understand whether certain features will be available. Signed-off-by: Steven Toth <stoth@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/media/dvb/dvb-core/dvb_frontend.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/media/dvb/dvb-core/dvb_frontend.c b/drivers/media/dvb/dvb-core/dvb_frontend.c
index 0ef9c2a2af87..4c3f0d7e355c 100644
--- a/drivers/media/dvb/dvb-core/dvb_frontend.c
+++ b/drivers/media/dvb/dvb-core/dvb_frontend.c
@@ -40,6 +40,7 @@
#include "dvb_frontend.h"
#include "dvbdev.h"
+#include <linux/dvb/version.h>
static int dvb_frontend_debug;
static int dvb_shutdown_timeout;
@@ -836,6 +837,11 @@ struct dtv_cmds_h dtv_cmds[] = {
.set = 0,
.buffer = 1,
},
+ [DTV_API_VERSION] = {
+ .name = "DTV_API_VERSION",
+ .cmd = DTV_API_VERSION,
+ .set = 0,
+ },
};
void dtv_property_dump(struct dtv_property *tvp)
@@ -1104,6 +1110,9 @@ int dtv_property_process_get(struct dvb_frontend *fe, struct dtv_property *tvp,
case DTV_TONE:
tvp->u.data = fe->dtv_property_cache.sectone;
break;
+ case DTV_API_VERSION:
+ tvp->u.data = (DVB_API_VERSION << 8) | DVB_API_VERSION_MINOR;
+ break;
default:
r = -1;
}
OpenPOWER on IntegriCloud