diff options
author | Mauro Carvalho Chehab <mchehab@redhat.com> | 2012-10-11 14:07:19 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2012-10-11 14:07:19 -0400 |
commit | bf3b202b41999f88f091632f13842b7234bd58b7 (patch) | |
tree | e2861fcca522cc299e6106fa6c78d85a4a6eedeb /drivers/media/dvb-core | |
parent | 782cd9ee985b1523f1ddad57657a24d7855d9e4d (diff) | |
parent | 1fdead8ad31d3aa833bc37739273fcde89ace93c (diff) |
Merge branch 'staging/for_v3.7' into v4l_for_linus
Applied on the top of changeset 782cd9e, as some of those patches
depend on some fixes that went via -arm tree.
* staging/for_v3.7: (109 commits)
[media] m5mols: Add missing #include <linux/sizes.h>
[media] stk1160: Add support for S-Video input
Revert "[media] omap3isp: Replace cpu_is_omap3630() with ISP revision check"
[media] dvb: LNA implementation changes
[media] v4l2-ioctl: fix W=1 warnings
[media] v4l2-ioctl: add blocks check for VIDIOC_SUBDEV_G/S_EDID
[media] omap3isp: Fix compilation error in ispreg.h
[media] rc-msi-digivox-ii: Add full scan keycodes
[media] cx25821: testing the wrong variable
[media] tda18271-common: hold the I2C adapter during write transfers
[media] ds3000: add module parameter to force firmware upload
[media] drivers/media: Remove unnecessary semicolon
[media] winbond: remove space from driver name
[media] iguanair: cannot send data from the stack
[media] omap3isp: Replace cpu_is_omap3630() with ISP revision check
[media] dvb-usb: print small buffers via %*ph
[media] uvc: Add return code check at vb2_queue_init()
[media] em28xx: Replace memcpy with struct assignment
[media] bt8xx: Add video4linux control V4L2_CID_COLOR_KILLER
[media] mem2mem_testdev: Use devm_kzalloc() in probe
...
Diffstat (limited to 'drivers/media/dvb-core')
-rw-r--r-- | drivers/media/dvb-core/dvb_frontend.c | 20 | ||||
-rw-r--r-- | drivers/media/dvb-core/dvb_frontend.h | 4 |
2 files changed, 18 insertions, 6 deletions
diff --git a/drivers/media/dvb-core/dvb_frontend.c b/drivers/media/dvb-core/dvb_frontend.c index 8f58f241c10d..7e92793260f0 100644 --- a/drivers/media/dvb-core/dvb_frontend.c +++ b/drivers/media/dvb-core/dvb_frontend.c | |||
@@ -966,6 +966,8 @@ static int dvb_frontend_clear_cache(struct dvb_frontend *fe) | |||
966 | break; | 966 | break; |
967 | } | 967 | } |
968 | 968 | ||
969 | c->lna = LNA_AUTO; | ||
970 | |||
969 | return 0; | 971 | return 0; |
970 | } | 972 | } |
971 | 973 | ||
@@ -1054,6 +1056,8 @@ static struct dtv_cmds_h dtv_cmds[DTV_MAX_COMMAND + 1] = { | |||
1054 | _DTV_CMD(DTV_ATSCMH_SCCC_CODE_MODE_B, 0, 0), | 1056 | _DTV_CMD(DTV_ATSCMH_SCCC_CODE_MODE_B, 0, 0), |
1055 | _DTV_CMD(DTV_ATSCMH_SCCC_CODE_MODE_C, 0, 0), | 1057 | _DTV_CMD(DTV_ATSCMH_SCCC_CODE_MODE_C, 0, 0), |
1056 | _DTV_CMD(DTV_ATSCMH_SCCC_CODE_MODE_D, 0, 0), | 1058 | _DTV_CMD(DTV_ATSCMH_SCCC_CODE_MODE_D, 0, 0), |
1059 | |||
1060 | _DTV_CMD(DTV_LNA, 0, 0), | ||
1057 | }; | 1061 | }; |
1058 | 1062 | ||
1059 | static void dtv_property_dump(struct dvb_frontend *fe, struct dtv_property *tvp) | 1063 | static void dtv_property_dump(struct dvb_frontend *fe, struct dtv_property *tvp) |
@@ -1440,6 +1444,10 @@ static int dtv_property_process_get(struct dvb_frontend *fe, | |||
1440 | tvp->u.data = fe->dtv_property_cache.atscmh_sccc_code_mode_d; | 1444 | tvp->u.data = fe->dtv_property_cache.atscmh_sccc_code_mode_d; |
1441 | break; | 1445 | break; |
1442 | 1446 | ||
1447 | case DTV_LNA: | ||
1448 | tvp->u.data = c->lna; | ||
1449 | break; | ||
1450 | |||
1443 | default: | 1451 | default: |
1444 | return -EINVAL; | 1452 | return -EINVAL; |
1445 | } | 1453 | } |
@@ -1731,10 +1739,6 @@ static int dtv_property_process_set(struct dvb_frontend *fe, | |||
1731 | case DTV_INTERLEAVING: | 1739 | case DTV_INTERLEAVING: |
1732 | c->interleaving = tvp->u.data; | 1740 | c->interleaving = tvp->u.data; |
1733 | break; | 1741 | break; |
1734 | case DTV_LNA: | ||
1735 | if (fe->ops.set_lna) | ||
1736 | r = fe->ops.set_lna(fe, tvp->u.data); | ||
1737 | break; | ||
1738 | 1742 | ||
1739 | /* ISDB-T Support here */ | 1743 | /* ISDB-T Support here */ |
1740 | case DTV_ISDBT_PARTIAL_RECEPTION: | 1744 | case DTV_ISDBT_PARTIAL_RECEPTION: |
@@ -1806,6 +1810,12 @@ static int dtv_property_process_set(struct dvb_frontend *fe, | |||
1806 | fe->dtv_property_cache.atscmh_rs_frame_ensemble = tvp->u.data; | 1810 | fe->dtv_property_cache.atscmh_rs_frame_ensemble = tvp->u.data; |
1807 | break; | 1811 | break; |
1808 | 1812 | ||
1813 | case DTV_LNA: | ||
1814 | c->lna = tvp->u.data; | ||
1815 | if (fe->ops.set_lna) | ||
1816 | r = fe->ops.set_lna(fe); | ||
1817 | break; | ||
1818 | |||
1809 | default: | 1819 | default: |
1810 | return -EINVAL; | 1820 | return -EINVAL; |
1811 | } | 1821 | } |
@@ -2309,7 +2319,7 @@ static int dvb_frontend_ioctl_legacy(struct file *file, | |||
2309 | fepriv->tune_mode_flags = (unsigned long) parg; | 2319 | fepriv->tune_mode_flags = (unsigned long) parg; |
2310 | err = 0; | 2320 | err = 0; |
2311 | break; | 2321 | break; |
2312 | }; | 2322 | } |
2313 | 2323 | ||
2314 | return err; | 2324 | return err; |
2315 | } | 2325 | } |
diff --git a/drivers/media/dvb-core/dvb_frontend.h b/drivers/media/dvb-core/dvb_frontend.h index 44a445cee74f..97112cd88a17 100644 --- a/drivers/media/dvb-core/dvb_frontend.h +++ b/drivers/media/dvb-core/dvb_frontend.h | |||
@@ -303,7 +303,7 @@ struct dvb_frontend_ops { | |||
303 | int (*dishnetwork_send_legacy_command)(struct dvb_frontend* fe, unsigned long cmd); | 303 | int (*dishnetwork_send_legacy_command)(struct dvb_frontend* fe, unsigned long cmd); |
304 | int (*i2c_gate_ctrl)(struct dvb_frontend* fe, int enable); | 304 | int (*i2c_gate_ctrl)(struct dvb_frontend* fe, int enable); |
305 | int (*ts_bus_ctrl)(struct dvb_frontend* fe, int acquire); | 305 | int (*ts_bus_ctrl)(struct dvb_frontend* fe, int acquire); |
306 | int (*set_lna)(struct dvb_frontend *, int); | 306 | int (*set_lna)(struct dvb_frontend *); |
307 | 307 | ||
308 | /* These callbacks are for devices that implement their own | 308 | /* These callbacks are for devices that implement their own |
309 | * tuning algorithms, rather than a simple swzigzag | 309 | * tuning algorithms, rather than a simple swzigzag |
@@ -391,6 +391,8 @@ struct dtv_frontend_properties { | |||
391 | u8 atscmh_sccc_code_mode_b; | 391 | u8 atscmh_sccc_code_mode_b; |
392 | u8 atscmh_sccc_code_mode_c; | 392 | u8 atscmh_sccc_code_mode_c; |
393 | u8 atscmh_sccc_code_mode_d; | 393 | u8 atscmh_sccc_code_mode_d; |
394 | |||
395 | u32 lna; | ||
394 | }; | 396 | }; |
395 | 397 | ||
396 | struct dvb_frontend { | 398 | struct dvb_frontend { |