[media] rtl28xxu: attach SDR extension module
With that extension module it supports SDR. Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
This commit is contained in:
Родитель
e8b4668937
Коммит
bcf4339357
|
@ -41,3 +41,4 @@ ccflags-y += -I$(srctree)/drivers/media/dvb-core
|
||||||
ccflags-y += -I$(srctree)/drivers/media/dvb-frontends
|
ccflags-y += -I$(srctree)/drivers/media/dvb-frontends
|
||||||
ccflags-y += -I$(srctree)/drivers/media/tuners
|
ccflags-y += -I$(srctree)/drivers/media/tuners
|
||||||
ccflags-y += -I$(srctree)/drivers/media/common
|
ccflags-y += -I$(srctree)/drivers/media/common
|
||||||
|
ccflags-y += -I$(srctree)/drivers/staging/media/rtl2832u_sdr
|
||||||
|
|
|
@ -24,6 +24,7 @@
|
||||||
|
|
||||||
#include "rtl2830.h"
|
#include "rtl2830.h"
|
||||||
#include "rtl2832.h"
|
#include "rtl2832.h"
|
||||||
|
#include "rtl2832_sdr.h"
|
||||||
|
|
||||||
#include "qt1010.h"
|
#include "qt1010.h"
|
||||||
#include "mt2060.h"
|
#include "mt2060.h"
|
||||||
|
@ -902,6 +903,10 @@ static int rtl2832u_tuner_attach(struct dvb_usb_adapter *adap)
|
||||||
* that to the tuner driver */
|
* that to the tuner driver */
|
||||||
adap->fe[0]->ops.read_signal_strength =
|
adap->fe[0]->ops.read_signal_strength =
|
||||||
adap->fe[0]->ops.tuner_ops.get_rf_strength;
|
adap->fe[0]->ops.tuner_ops.get_rf_strength;
|
||||||
|
|
||||||
|
/* attach SDR */
|
||||||
|
dvb_attach(rtl2832_sdr_attach, adap->fe[0], &d->i2c_adap,
|
||||||
|
&rtl28xxu_rtl2832_fc0012_config, NULL);
|
||||||
return 0;
|
return 0;
|
||||||
break;
|
break;
|
||||||
case TUNER_RTL2832_FC0013:
|
case TUNER_RTL2832_FC0013:
|
||||||
|
@ -911,8 +916,13 @@ static int rtl2832u_tuner_attach(struct dvb_usb_adapter *adap)
|
||||||
/* fc0013 also supports signal strength reading */
|
/* fc0013 also supports signal strength reading */
|
||||||
adap->fe[0]->ops.read_signal_strength =
|
adap->fe[0]->ops.read_signal_strength =
|
||||||
adap->fe[0]->ops.tuner_ops.get_rf_strength;
|
adap->fe[0]->ops.tuner_ops.get_rf_strength;
|
||||||
|
|
||||||
|
/* attach SDR */
|
||||||
|
dvb_attach(rtl2832_sdr_attach, adap->fe[0], &d->i2c_adap,
|
||||||
|
&rtl28xxu_rtl2832_fc0013_config, NULL);
|
||||||
return 0;
|
return 0;
|
||||||
case TUNER_RTL2832_E4000: {
|
case TUNER_RTL2832_E4000: {
|
||||||
|
struct v4l2_subdev *sd;
|
||||||
struct e4000_config e4000_config = {
|
struct e4000_config e4000_config = {
|
||||||
.fe = adap->fe[0],
|
.fe = adap->fe[0],
|
||||||
.clock = 28800000,
|
.clock = 28800000,
|
||||||
|
@ -933,6 +943,12 @@ static int rtl2832u_tuner_attach(struct dvb_usb_adapter *adap)
|
||||||
}
|
}
|
||||||
|
|
||||||
priv->client = client;
|
priv->client = client;
|
||||||
|
sd = i2c_get_clientdata(client);
|
||||||
|
|
||||||
|
/* attach SDR */
|
||||||
|
dvb_attach(rtl2832_sdr_attach, adap->fe[0],
|
||||||
|
&d->i2c_adap,
|
||||||
|
&rtl28xxu_rtl2832_e4000_config, sd);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case TUNER_RTL2832_FC2580:
|
case TUNER_RTL2832_FC2580:
|
||||||
|
@ -959,6 +975,10 @@ static int rtl2832u_tuner_attach(struct dvb_usb_adapter *adap)
|
||||||
/* Use tuner to get the signal strength */
|
/* Use tuner to get the signal strength */
|
||||||
adap->fe[0]->ops.read_signal_strength =
|
adap->fe[0]->ops.read_signal_strength =
|
||||||
adap->fe[0]->ops.tuner_ops.get_rf_strength;
|
adap->fe[0]->ops.tuner_ops.get_rf_strength;
|
||||||
|
|
||||||
|
/* attach SDR */
|
||||||
|
dvb_attach(rtl2832_sdr_attach, adap->fe[0], &d->i2c_adap,
|
||||||
|
&rtl28xxu_rtl2832_r820t_config, NULL);
|
||||||
break;
|
break;
|
||||||
case TUNER_RTL2832_R828D:
|
case TUNER_RTL2832_R828D:
|
||||||
/* power off mn88472 demod on GPIO0 */
|
/* power off mn88472 demod on GPIO0 */
|
||||||
|
|
Загрузка…
Ссылка в новой задаче