1 /* SPDX-License-Identifier: GPL-2.0-or-later */
3 TDA8261 8PSK/QPSK tuner driver
4 Copyright (C) Manu Abraham (abraham.manu@gmail.com)
8 static int tda8261_get_frequency(struct dvb_frontend *fe, u32 *frequency)
10 struct dvb_frontend_ops *frontend_ops = &fe->ops;
11 struct dvb_tuner_ops *tuner_ops = &frontend_ops->tuner_ops;
14 if (tuner_ops->get_frequency) {
15 err = tuner_ops->get_frequency(fe, frequency);
17 pr_err("%s: Invalid parameter\n", __func__);
20 pr_debug("%s: Frequency=%d\n", __func__, *frequency);
25 static int tda8261_set_frequency(struct dvb_frontend *fe, u32 frequency)
27 struct dvb_frontend_ops *frontend_ops = &fe->ops;
28 struct dvb_tuner_ops *tuner_ops = &frontend_ops->tuner_ops;
29 struct dtv_frontend_properties *c = &fe->dtv_property_cache;
32 if (tuner_ops->set_params) {
33 err = tuner_ops->set_params(fe);
35 pr_err("%s: Invalid parameter\n", __func__);
39 pr_debug("%s: Frequency=%d\n", __func__, c->frequency);
43 static int tda8261_get_bandwidth(struct dvb_frontend *fe, u32 *bandwidth)
45 /* FIXME! need to calculate Bandwidth */
46 *bandwidth = 40000000;