* [PATCH 1/5] media: stv0288: get rid of set_property boilerplate
@ 2017-09-15 9:10 Mauro Carvalho Chehab
2017-09-15 9:10 ` [PATCH 2/5] media: stv6110: get rid of a srate dead code Mauro Carvalho Chehab
` (3 more replies)
0 siblings, 4 replies; 8+ messages in thread
From: Mauro Carvalho Chehab @ 2017-09-15 9:10 UTC (permalink / raw)
To: Linux Media Mailing List
Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Max Kellermann
This driver doesn't implement support for set_property(). Yet,
it implements a boilerplate for it. Get rid of it.
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
drivers/media/dvb-frontends/stv0288.c | 7 -------
1 file changed, 7 deletions(-)
diff --git a/drivers/media/dvb-frontends/stv0288.c b/drivers/media/dvb-frontends/stv0288.c
index 45cbc898ad25..67f91814b9f7 100644
--- a/drivers/media/dvb-frontends/stv0288.c
+++ b/drivers/media/dvb-frontends/stv0288.c
@@ -447,12 +447,6 @@ static int stv0288_read_ucblocks(struct dvb_frontend *fe, u32 *ucblocks)
return 0;
}
-static int stv0288_set_property(struct dvb_frontend *fe, struct dtv_property *p)
-{
- dprintk("%s(..)\n", __func__);
- return 0;
-}
-
static int stv0288_set_frontend(struct dvb_frontend *fe)
{
struct stv0288_state *state = fe->demodulator_priv;
@@ -567,7 +561,6 @@ static const struct dvb_frontend_ops stv0288_ops = {
.set_tone = stv0288_set_tone,
.set_voltage = stv0288_set_voltage,
- .set_property = stv0288_set_property,
.set_frontend = stv0288_set_frontend,
};
--
2.13.5
^ permalink raw reply related [flat|nested] 8+ messages in thread
* [PATCH 2/5] media: stv6110: get rid of a srate dead code
2017-09-15 9:10 [PATCH 1/5] media: stv0288: get rid of set_property boilerplate Mauro Carvalho Chehab
@ 2017-09-15 9:10 ` Mauro Carvalho Chehab
2017-09-15 9:30 ` Honza Petrouš
2017-09-15 9:10 ` [PATCH 3/5] media: friio-fe: get rid of set_property() Mauro Carvalho Chehab
` (2 subsequent siblings)
3 siblings, 1 reply; 8+ messages in thread
From: Mauro Carvalho Chehab @ 2017-09-15 9:10 UTC (permalink / raw)
To: Linux Media Mailing List
Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Sakari Ailus,
Julia Lawall, Hans Verkuil, Max Kellermann
The stv6110 has a weird code that checks if get_property
and set_property ioctls are defined. If they're, it initializes
a "srate" var from properties cache. Otherwise, it sets to
15MBaud, with won't make any sense.
Thankfully, it seems that someone already noticed, as the
"srate" is not used anywhere!
So, get rid of that really weird dead code logic.
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
drivers/media/dvb-frontends/stv6110.c | 8 --------
1 file changed, 8 deletions(-)
diff --git a/drivers/media/dvb-frontends/stv6110.c b/drivers/media/dvb-frontends/stv6110.c
index e4fd9c1b0560..2821f6da6764 100644
--- a/drivers/media/dvb-frontends/stv6110.c
+++ b/drivers/media/dvb-frontends/stv6110.c
@@ -262,7 +262,6 @@ static int stv6110_set_frequency(struct dvb_frontend *fe, u32 frequency)
u8 ret = 0x04;
u32 divider, ref, p, presc, i, result_freq, vco_freq;
s32 p_calc, p_calc_opt = 1000, r_div, r_div_opt = 0, p_val;
- s32 srate;
dprintk("%s, freq=%d kHz, mclk=%d Hz\n", __func__,
frequency, priv->mclk);
@@ -273,13 +272,6 @@ static int stv6110_set_frequency(struct dvb_frontend *fe, u32 frequency)
((((priv->mclk / 1000000) - 16) & 0x1f) << 3);
/* BB_GAIN = db/2 */
- if (fe->ops.set_property && fe->ops.get_property) {
- srate = c->symbol_rate;
- dprintk("%s: Get Frontend parameters: srate=%d\n",
- __func__, srate);
- } else
- srate = 15000000;
-
priv->regs[RSTV6110_CTRL2] &= ~0x0f;
priv->regs[RSTV6110_CTRL2] |= (priv->gain & 0x0f);
--
2.13.5
^ permalink raw reply related [flat|nested] 8+ messages in thread
* [PATCH 3/5] media: friio-fe: get rid of set_property()
2017-09-15 9:10 [PATCH 1/5] media: stv0288: get rid of set_property boilerplate Mauro Carvalho Chehab
2017-09-15 9:10 ` [PATCH 2/5] media: stv6110: get rid of a srate dead code Mauro Carvalho Chehab
@ 2017-09-15 9:10 ` Mauro Carvalho Chehab
2017-09-15 9:11 ` [PATCH 4/5] media: dvb_frontend: get rid of get_property() callback Mauro Carvalho Chehab
2017-09-15 9:11 ` [PATCH 5/5] media: dvb_frontend: get rid of set_property() callback Mauro Carvalho Chehab
3 siblings, 0 replies; 8+ messages in thread
From: Mauro Carvalho Chehab @ 2017-09-15 9:10 UTC (permalink / raw)
To: Linux Media Mailing List
Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Max Kellermann
This callback is not actually doing anything but making it to
return an error depending on the DTV frontend command. Well,
that could break userspace for no good reason, and, if needed,
should be implemented, instead, at set_frontend() callback.
So, get rid of it.
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
drivers/media/usb/dvb-usb/friio-fe.c | 24 ------------------------
1 file changed, 24 deletions(-)
diff --git a/drivers/media/usb/dvb-usb/friio-fe.c b/drivers/media/usb/dvb-usb/friio-fe.c
index 0251a4e91d47..41261317bd5c 100644
--- a/drivers/media/usb/dvb-usb/friio-fe.c
+++ b/drivers/media/usb/dvb-usb/friio-fe.c
@@ -261,28 +261,6 @@ static int jdvbt90502_read_signal_strength(struct dvb_frontend *fe,
return 0;
}
-
-/* filter out un-supported properties to notify users */
-static int jdvbt90502_set_property(struct dvb_frontend *fe,
- struct dtv_property *tvp)
-{
- int r = 0;
-
- switch (tvp->cmd) {
- case DTV_DELIVERY_SYSTEM:
- if (tvp->u.data != SYS_ISDBT)
- r = -EINVAL;
- break;
- case DTV_CLEAR:
- case DTV_TUNE:
- case DTV_FREQUENCY:
- break;
- default:
- r = -EINVAL;
- }
- return r;
-}
-
static int jdvbt90502_set_frontend(struct dvb_frontend *fe)
{
struct dtv_frontend_properties *p = &fe->dtv_property_cache;
@@ -457,8 +435,6 @@ static const struct dvb_frontend_ops jdvbt90502_ops = {
.init = jdvbt90502_init,
.write = _jdvbt90502_write,
- .set_property = jdvbt90502_set_property,
-
.set_frontend = jdvbt90502_set_frontend,
.read_status = jdvbt90502_read_status,
--
2.13.5
^ permalink raw reply related [flat|nested] 8+ messages in thread
* [PATCH 4/5] media: dvb_frontend: get rid of get_property() callback
2017-09-15 9:10 [PATCH 1/5] media: stv0288: get rid of set_property boilerplate Mauro Carvalho Chehab
2017-09-15 9:10 ` [PATCH 2/5] media: stv6110: get rid of a srate dead code Mauro Carvalho Chehab
2017-09-15 9:10 ` [PATCH 3/5] media: friio-fe: get rid of set_property() Mauro Carvalho Chehab
@ 2017-09-15 9:11 ` Mauro Carvalho Chehab
2017-09-15 9:11 ` [PATCH 5/5] media: dvb_frontend: get rid of set_property() callback Mauro Carvalho Chehab
3 siblings, 0 replies; 8+ messages in thread
From: Mauro Carvalho Chehab @ 2017-09-15 9:11 UTC (permalink / raw)
To: Linux Media Mailing List
Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Michael Krufky,
Max Kellermann, Shuah Khan, Colin Ian King, Ingo Molnar,
Masahiro Yamada, Sakari Ailus
Only lg2160 implement gets_property, but there's no need for that,
as no other driver calls this callback, as get_frontend() does the
same, and set_frontend() also calls lg2160 get_frontend().
So, get rid of it.
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Reviewed-by: Michael Ira Krufky <mkrufky@linuxtv.org>
---
drivers/media/dvb-core/dvb_frontend.c | 9 +--------
drivers/media/dvb-core/dvb_frontend.h | 3 ---
drivers/media/dvb-frontends/lg2160.c | 14 --------------
3 files changed, 1 insertion(+), 25 deletions(-)
diff --git a/drivers/media/dvb-core/dvb_frontend.c b/drivers/media/dvb-core/dvb_frontend.c
index 9139d01ba7ed..5d00e46d9432 100644
--- a/drivers/media/dvb-core/dvb_frontend.c
+++ b/drivers/media/dvb-core/dvb_frontend.c
@@ -1325,7 +1325,7 @@ static int dtv_property_process_get(struct dvb_frontend *fe,
struct dtv_property *tvp,
struct file *file)
{
- int r, ncaps;
+ int ncaps;
switch(tvp->cmd) {
case DTV_ENUM_DELSYS:
@@ -1536,13 +1536,6 @@ static int dtv_property_process_get(struct dvb_frontend *fe,
return -EINVAL;
}
- /* Allow the frontend to override outgoing properties */
- if (fe->ops.get_property) {
- r = fe->ops.get_property(fe, tvp);
- if (r < 0)
- return r;
- }
-
dtv_property_dump(fe, false, tvp);
return 0;
diff --git a/drivers/media/dvb-core/dvb_frontend.h b/drivers/media/dvb-core/dvb_frontend.h
index 907a05bde162..4d05846f2c1c 100644
--- a/drivers/media/dvb-core/dvb_frontend.h
+++ b/drivers/media/dvb-core/dvb_frontend.h
@@ -403,8 +403,6 @@ struct dtv_frontend_properties;
* @analog_ops: pointer to struct analog_demod_ops
* @set_property: callback function to allow the frontend to validade
* incoming properties. Should not be used on new drivers.
- * @get_property: callback function to allow the frontend to override
- * outcoming properties. Should not be used on new drivers.
*/
struct dvb_frontend_ops {
@@ -468,7 +466,6 @@ struct dvb_frontend_ops {
struct analog_demod_ops analog_ops;
int (*set_property)(struct dvb_frontend* fe, struct dtv_property* tvp);
- int (*get_property)(struct dvb_frontend* fe, struct dtv_property* tvp);
};
#ifdef __DVB_CORE__
diff --git a/drivers/media/dvb-frontends/lg2160.c b/drivers/media/dvb-frontends/lg2160.c
index 5798079add10..9854096839ae 100644
--- a/drivers/media/dvb-frontends/lg2160.c
+++ b/drivers/media/dvb-frontends/lg2160.c
@@ -1048,16 +1048,6 @@ static int lg216x_get_frontend(struct dvb_frontend *fe,
return ret;
}
-static int lg216x_get_property(struct dvb_frontend *fe,
- struct dtv_property *tvp)
-{
- struct dtv_frontend_properties *c = &fe->dtv_property_cache;
-
- return (DTV_ATSCMH_FIC_VER == tvp->cmd) ?
- lg216x_get_frontend(fe, c) : 0;
-}
-
-
static int lg2160_set_frontend(struct dvb_frontend *fe)
{
struct lg216x_state *state = fe->demodulator_priv;
@@ -1368,8 +1358,6 @@ static const struct dvb_frontend_ops lg2160_ops = {
.init = lg216x_init,
.sleep = lg216x_sleep,
#endif
- .get_property = lg216x_get_property,
-
.set_frontend = lg2160_set_frontend,
.get_frontend = lg216x_get_frontend,
.get_tune_settings = lg216x_get_tune_settings,
@@ -1396,8 +1384,6 @@ static const struct dvb_frontend_ops lg2161_ops = {
.init = lg216x_init,
.sleep = lg216x_sleep,
#endif
- .get_property = lg216x_get_property,
-
.set_frontend = lg2160_set_frontend,
.get_frontend = lg216x_get_frontend,
.get_tune_settings = lg216x_get_tune_settings,
--
2.13.5
^ permalink raw reply related [flat|nested] 8+ messages in thread
* [PATCH 5/5] media: dvb_frontend: get rid of set_property() callback
2017-09-15 9:10 [PATCH 1/5] media: stv0288: get rid of set_property boilerplate Mauro Carvalho Chehab
` (2 preceding siblings ...)
2017-09-15 9:11 ` [PATCH 4/5] media: dvb_frontend: get rid of get_property() callback Mauro Carvalho Chehab
@ 2017-09-15 9:11 ` Mauro Carvalho Chehab
2017-09-15 10:05 ` Mauro Carvalho Chehab
3 siblings, 1 reply; 8+ messages in thread
From: Mauro Carvalho Chehab @ 2017-09-15 9:11 UTC (permalink / raw)
To: Linux Media Mailing List
Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Max Kellermann,
Shuah Khan, Colin Ian King, Sakari Ailus, Ingo Molnar,
Masahiro Yamada, Michael Ira Krufky
Now that all clients of set_property() were removed, get rid
of this callback.
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
---
drivers/media/dvb-core/dvb_frontend.c | 7 -------
drivers/media/dvb-core/dvb_frontend.h | 2 --
2 files changed, 9 deletions(-)
diff --git a/drivers/media/dvb-core/dvb_frontend.c b/drivers/media/dvb-core/dvb_frontend.c
index 5d00e46d9432..8abe4f541a36 100644
--- a/drivers/media/dvb-core/dvb_frontend.c
+++ b/drivers/media/dvb-core/dvb_frontend.c
@@ -1766,13 +1766,6 @@ static int dtv_property_process_set(struct dvb_frontend *fe,
int r = 0;
struct dtv_frontend_properties *c = &fe->dtv_property_cache;
- /* Allow the frontend to validate incoming properties */
- if (fe->ops.set_property) {
- r = fe->ops.set_property(fe, tvp);
- if (r < 0)
- return r;
- }
-
dtv_property_dump(fe, true, tvp);
switch(tvp->cmd) {
diff --git a/drivers/media/dvb-core/dvb_frontend.h b/drivers/media/dvb-core/dvb_frontend.h
index 4d05846f2c1c..a50f8216ab76 100644
--- a/drivers/media/dvb-core/dvb_frontend.h
+++ b/drivers/media/dvb-core/dvb_frontend.h
@@ -401,8 +401,6 @@ struct dtv_frontend_properties;
* @search: callback function used on some custom algo search algos.
* @tuner_ops: pointer to struct dvb_tuner_ops
* @analog_ops: pointer to struct analog_demod_ops
- * @set_property: callback function to allow the frontend to validade
- * incoming properties. Should not be used on new drivers.
*/
struct dvb_frontend_ops {
--
2.13.5
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [PATCH 2/5] media: stv6110: get rid of a srate dead code
2017-09-15 9:10 ` [PATCH 2/5] media: stv6110: get rid of a srate dead code Mauro Carvalho Chehab
@ 2017-09-15 9:30 ` Honza Petrouš
2017-09-15 9:46 ` Mauro Carvalho Chehab
0 siblings, 1 reply; 8+ messages in thread
From: Honza Petrouš @ 2017-09-15 9:30 UTC (permalink / raw)
To: Mauro Carvalho Chehab
Cc: Linux Media Mailing List, Mauro Carvalho Chehab, Sakari Ailus,
Julia Lawall, Hans Verkuil, Max Kellermann
Mauro, you are so speedy :)
2017-09-15 11:10 GMT+02:00 Mauro Carvalho Chehab <mchehab@s-opensource.com>:
> The stv6110 has a weird code that checks if get_property
> and set_property ioctls are defined. If they're, it initializes
> a "srate" var from properties cache. Otherwise, it sets to
> 15MBaud, with won't make any sense.
>
> Thankfully, it seems that someone already noticed, as the
> "srate" is not used anywhere!
Hehe! "Someone else" :)
>
> So, get rid of that really weird dead code logic.
>
> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Reported-by: Honza Petrous <jpetrous@gmail.com>
> ---
> drivers/media/dvb-frontends/stv6110.c | 8 --------
> 1 file changed, 8 deletions(-)
>
> diff --git a/drivers/media/dvb-frontends/stv6110.c b/drivers/media/dvb-frontends/stv6110.c
> index e4fd9c1b0560..2821f6da6764 100644
> --- a/drivers/media/dvb-frontends/stv6110.c
> +++ b/drivers/media/dvb-frontends/stv6110.c
> @@ -262,7 +262,6 @@ static int stv6110_set_frequency(struct dvb_frontend *fe, u32 frequency)
> u8 ret = 0x04;
> u32 divider, ref, p, presc, i, result_freq, vco_freq;
> s32 p_calc, p_calc_opt = 1000, r_div, r_div_opt = 0, p_val;
> - s32 srate;
>
> dprintk("%s, freq=%d kHz, mclk=%d Hz\n", __func__,
> frequency, priv->mclk);
> @@ -273,13 +272,6 @@ static int stv6110_set_frequency(struct dvb_frontend *fe, u32 frequency)
> ((((priv->mclk / 1000000) - 16) & 0x1f) << 3);
>
> /* BB_GAIN = db/2 */
> - if (fe->ops.set_property && fe->ops.get_property) {
> - srate = c->symbol_rate;
> - dprintk("%s: Get Frontend parameters: srate=%d\n",
> - __func__, srate);
> - } else
> - srate = 15000000;
> -
> priv->regs[RSTV6110_CTRL2] &= ~0x0f;
> priv->regs[RSTV6110_CTRL2] |= (priv->gain & 0x0f);
>
> --
> 2.13.5
>
Don't be offended, I simply smiled on the therm "someone else"
/Honza
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 2/5] media: stv6110: get rid of a srate dead code
2017-09-15 9:30 ` Honza Petrouš
@ 2017-09-15 9:46 ` Mauro Carvalho Chehab
0 siblings, 0 replies; 8+ messages in thread
From: Mauro Carvalho Chehab @ 2017-09-15 9:46 UTC (permalink / raw)
To: Honza Petrouš
Cc: Linux Media Mailing List, Mauro Carvalho Chehab, Sakari Ailus,
Julia Lawall, Hans Verkuil, Max Kellermann
Em Fri, 15 Sep 2017 11:30:11 +0200
Honza Petrouš <jpetrous@gmail.com> escreveu:
> Mauro, you are so speedy :)
>
> 2017-09-15 11:10 GMT+02:00 Mauro Carvalho Chehab <mchehab@s-opensource.com>:
> > The stv6110 has a weird code that checks if get_property
> > and set_property ioctls are defined. If they're, it initializes
> > a "srate" var from properties cache. Otherwise, it sets to
> > 15MBaud, with won't make any sense.
> >
> > Thankfully, it seems that someone already noticed, as the
> > "srate" is not used anywhere!
>
> Hehe! "Someone else" :)
Yeah, true!
Just to be clear, I meant to say above that probably someone
noticed it in the past, and got rid of the usage of srate upstream,
but forgot to remove the var :-)
I updated the text. See enclosed.
>
> >
> > So, get rid of that really weird dead code logic.
> >
> > Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
>
> Reported-by: Honza Petrous <jpetrous@gmail.com>
Thanks for reporting it!
Thanks,
Mauro
-
[PATCH] media: stv6110: get rid of a srate dead code
The stv6110 has a weird code that checks if get_property
and set_property ioctls are defined. If they're, it initializes
a "srate" var from properties cache. Otherwise, it sets to
15MBaud, with won't make any sense.
Thankfully, it seems that someone else discovered the issue in
the past, as "srate" is currently not used anywhere!
So, get rid of that really weird dead code logic.
Reported-by: Honza Petrous <jpetrous@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
diff --git a/drivers/media/dvb-frontends/stv6110.c b/drivers/media/dvb-frontends/stv6110.c
index e4fd9c1b0560..2821f6da6764 100644
--- a/drivers/media/dvb-frontends/stv6110.c
+++ b/drivers/media/dvb-frontends/stv6110.c
@@ -262,7 +262,6 @@ static int stv6110_set_frequency(struct dvb_frontend *fe, u32 frequency)
u8 ret = 0x04;
u32 divider, ref, p, presc, i, result_freq, vco_freq;
s32 p_calc, p_calc_opt = 1000, r_div, r_div_opt = 0, p_val;
- s32 srate;
dprintk("%s, freq=%d kHz, mclk=%d Hz\n", __func__,
frequency, priv->mclk);
@@ -273,13 +272,6 @@ static int stv6110_set_frequency(struct dvb_frontend *fe, u32 frequency)
((((priv->mclk / 1000000) - 16) & 0x1f) << 3);
/* BB_GAIN = db/2 */
- if (fe->ops.set_property && fe->ops.get_property) {
- srate = c->symbol_rate;
- dprintk("%s: Get Frontend parameters: srate=%d\n",
- __func__, srate);
- } else
- srate = 15000000;
-
priv->regs[RSTV6110_CTRL2] &= ~0x0f;
priv->regs[RSTV6110_CTRL2] |= (priv->gain & 0x0f);
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [PATCH 5/5] media: dvb_frontend: get rid of set_property() callback
2017-09-15 9:11 ` [PATCH 5/5] media: dvb_frontend: get rid of set_property() callback Mauro Carvalho Chehab
@ 2017-09-15 10:05 ` Mauro Carvalho Chehab
0 siblings, 0 replies; 8+ messages in thread
From: Mauro Carvalho Chehab @ 2017-09-15 10:05 UTC (permalink / raw)
To: Linux Media Mailing List
Cc: Mauro Carvalho Chehab, Max Kellermann, Shuah Khan, Colin Ian King,
Sakari Ailus, Ingo Molnar, Masahiro Yamada, Michael Ira Krufky
Em Fri, 15 Sep 2017 06:11:01 -0300
Mauro Carvalho Chehab <mchehab@s-opensource.com> escreveu:
> Now that all clients of set_property() were removed, get rid
> of this callback.
>
> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
> ---
> drivers/media/dvb-core/dvb_frontend.c | 7 -------
> drivers/media/dvb-core/dvb_frontend.h | 2 --
> 2 files changed, 9 deletions(-)
>
> diff --git a/drivers/media/dvb-core/dvb_frontend.c b/drivers/media/dvb-core/dvb_frontend.c
> index 5d00e46d9432..8abe4f541a36 100644
> --- a/drivers/media/dvb-core/dvb_frontend.c
> +++ b/drivers/media/dvb-core/dvb_frontend.c
> @@ -1766,13 +1766,6 @@ static int dtv_property_process_set(struct dvb_frontend *fe,
> int r = 0;
> struct dtv_frontend_properties *c = &fe->dtv_property_cache;
>
> - /* Allow the frontend to validate incoming properties */
> - if (fe->ops.set_property) {
> - r = fe->ops.set_property(fe, tvp);
> - if (r < 0)
> - return r;
> - }
> -
> dtv_property_dump(fe, true, tvp);
>
> switch(tvp->cmd) {
> diff --git a/drivers/media/dvb-core/dvb_frontend.h b/drivers/media/dvb-core/dvb_frontend.h
> index 4d05846f2c1c..a50f8216ab76 100644
> --- a/drivers/media/dvb-core/dvb_frontend.h
> +++ b/drivers/media/dvb-core/dvb_frontend.h
> @@ -401,8 +401,6 @@ struct dtv_frontend_properties;
> * @search: callback function used on some custom algo search algos.
> * @tuner_ops: pointer to struct dvb_tuner_ops
> * @analog_ops: pointer to struct analog_demod_ops
> - * @set_property: callback function to allow the frontend to validade
> - * incoming properties. Should not be used on new drivers.
> */
> struct dvb_frontend_ops {
Hmm... actually, the patch is missing the removal of set_property().
The enclosed one should fix it.
Regards,
Mauro
---
[PATCH] media: dvb_frontend: get rid of set_property() callback
Now that all clients of set_property() were removed, get rid
of this callback.
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
diff --git a/drivers/media/dvb-core/dvb_frontend.c b/drivers/media/dvb-core/dvb_frontend.c
index 5d00e46d9432..8abe4f541a36 100644
--- a/drivers/media/dvb-core/dvb_frontend.c
+++ b/drivers/media/dvb-core/dvb_frontend.c
@@ -1766,13 +1766,6 @@ static int dtv_property_process_set(struct dvb_frontend *fe,
int r = 0;
struct dtv_frontend_properties *c = &fe->dtv_property_cache;
- /* Allow the frontend to validate incoming properties */
- if (fe->ops.set_property) {
- r = fe->ops.set_property(fe, tvp);
- if (r < 0)
- return r;
- }
-
dtv_property_dump(fe, true, tvp);
switch(tvp->cmd) {
diff --git a/drivers/media/dvb-core/dvb_frontend.h b/drivers/media/dvb-core/dvb_frontend.h
index 4d05846f2c1c..852b91ba49d2 100644
--- a/drivers/media/dvb-core/dvb_frontend.h
+++ b/drivers/media/dvb-core/dvb_frontend.h
@@ -401,11 +401,8 @@ struct dtv_frontend_properties;
* @search: callback function used on some custom algo search algos.
* @tuner_ops: pointer to struct dvb_tuner_ops
* @analog_ops: pointer to struct analog_demod_ops
- * @set_property: callback function to allow the frontend to validade
- * incoming properties. Should not be used on new drivers.
*/
struct dvb_frontend_ops {
-
struct dvb_frontend_info info;
u8 delsys[MAX_DELSYS];
@@ -464,8 +461,6 @@ struct dvb_frontend_ops {
struct dvb_tuner_ops tuner_ops;
struct analog_demod_ops analog_ops;
-
- int (*set_property)(struct dvb_frontend* fe, struct dtv_property* tvp);
};
#ifdef __DVB_CORE__
^ permalink raw reply related [flat|nested] 8+ messages in thread
end of thread, other threads:[~2017-09-15 10:06 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-09-15 9:10 [PATCH 1/5] media: stv0288: get rid of set_property boilerplate Mauro Carvalho Chehab
2017-09-15 9:10 ` [PATCH 2/5] media: stv6110: get rid of a srate dead code Mauro Carvalho Chehab
2017-09-15 9:30 ` Honza Petrouš
2017-09-15 9:46 ` Mauro Carvalho Chehab
2017-09-15 9:10 ` [PATCH 3/5] media: friio-fe: get rid of set_property() Mauro Carvalho Chehab
2017-09-15 9:11 ` [PATCH 4/5] media: dvb_frontend: get rid of get_property() callback Mauro Carvalho Chehab
2017-09-15 9:11 ` [PATCH 5/5] media: dvb_frontend: get rid of set_property() callback Mauro Carvalho Chehab
2017-09-15 10:05 ` Mauro Carvalho Chehab
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.