aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSteven Toth <stoth@linuxtv.org>2008-10-06 21:01:47 -0400
committerMauro Carvalho Chehab <mchehab@redhat.com>2008-10-13 10:28:12 -0400
commitef526f4246f566370218bb6e639f7549244ca5a2 (patch)
treef9f4fd541cbfdfdafccc9f9e6197f1b0bb33e1ba
parentb87625f0ccbbc67efba356e73502fa9bbb784b1c (diff)
V4L/DVB (9182): S2API: Added support for DTV_HIERARCHY
A user tuning DVB-T via the S2API reports that this was not implemented, and his tuning was failing. Signed-off-by: Steven Toth <stoth@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
-rw-r--r--drivers/media/dvb/dvb-core/dvb_frontend.c16
-rw-r--r--include/linux/dvb/frontend.h3
2 files changed, 18 insertions, 1 deletions
diff --git a/drivers/media/dvb/dvb-core/dvb_frontend.c b/drivers/media/dvb/dvb-core/dvb_frontend.c
index 0ddc2f4ecd4a..bd59c9514ab5 100644
--- a/drivers/media/dvb/dvb-core/dvb_frontend.c
+++ b/drivers/media/dvb/dvb-core/dvb_frontend.c
@@ -830,6 +830,11 @@ struct dtv_cmds_h dtv_cmds[] = {
830 .cmd = DTV_DELIVERY_SYSTEM, 830 .cmd = DTV_DELIVERY_SYSTEM,
831 .set = 1, 831 .set = 1,
832 }, 832 },
833 [DTV_HIERARCHY] = {
834 .name = "DTV_HIERARCHY",
835 .cmd = DTV_HIERARCHY,
836 .set = 1,
837 },
833 [DTV_CODE_RATE_HP] = { 838 [DTV_CODE_RATE_HP] = {
834 .name = "DTV_CODE_RATE_HP", 839 .name = "DTV_CODE_RATE_HP",
835 .cmd = DTV_CODE_RATE_HP, 840 .cmd = DTV_CODE_RATE_HP,
@@ -882,6 +887,11 @@ struct dtv_cmds_h dtv_cmds[] = {
882 .cmd = DTV_TRANSMISSION_MODE, 887 .cmd = DTV_TRANSMISSION_MODE,
883 .set = 0, 888 .set = 0,
884 }, 889 },
890 [DTV_HIERARCHY] = {
891 .name = "DTV_HIERARCHY",
892 .cmd = DTV_HIERARCHY,
893 .set = 0,
894 },
885}; 895};
886 896
887void dtv_property_dump(struct dtv_property *tvp) 897void dtv_property_dump(struct dtv_property *tvp)
@@ -1173,6 +1183,9 @@ int dtv_property_process_get(struct dvb_frontend *fe, struct dtv_property *tvp,
1173 case DTV_TRANSMISSION_MODE: 1183 case DTV_TRANSMISSION_MODE:
1174 tvp->u.data = fe->dtv_property_cache.transmission_mode; 1184 tvp->u.data = fe->dtv_property_cache.transmission_mode;
1175 break; 1185 break;
1186 case DTV_HIERARCHY:
1187 tvp->u.data = fe->dtv_property_cache.hierarchy;
1188 break;
1176 default: 1189 default:
1177 r = -1; 1190 r = -1;
1178 } 1191 }
@@ -1266,6 +1279,9 @@ int dtv_property_process_set(struct dvb_frontend *fe, struct dtv_property *tvp,
1266 case DTV_TRANSMISSION_MODE: 1279 case DTV_TRANSMISSION_MODE:
1267 fe->dtv_property_cache.transmission_mode = tvp->u.data; 1280 fe->dtv_property_cache.transmission_mode = tvp->u.data;
1268 break; 1281 break;
1282 case DTV_HIERARCHY:
1283 fe->dtv_property_cache.hierarchy = tvp->u.data;
1284 break;
1269 default: 1285 default:
1270 r = -1; 1286 r = -1;
1271 } 1287 }
diff --git a/include/linux/dvb/frontend.h b/include/linux/dvb/frontend.h
index 5578fba208f4..e185627219e3 100644
--- a/include/linux/dvb/frontend.h
+++ b/include/linux/dvb/frontend.h
@@ -273,8 +273,9 @@ struct dvb_frontend_event {
273#define DTV_CODE_RATE_LP 37 273#define DTV_CODE_RATE_LP 37
274#define DTV_GUARD_INTERVAL 38 274#define DTV_GUARD_INTERVAL 38
275#define DTV_TRANSMISSION_MODE 39 275#define DTV_TRANSMISSION_MODE 39
276#define DTV_HIERARCHY 40
276 277
277#define DTV_MAX_COMMAND DTV_TRANSMISSION_MODE 278#define DTV_MAX_COMMAND DTV_HIERARCHY
278 279
279typedef enum fe_pilot { 280typedef enum fe_pilot {
280 PILOT_ON, 281 PILOT_ON,