Am 06.07.2018 um 00:59 schrieb Mauro Carvalho Chehab: Hi Mauro, I have one comment below. > Right now, satellite frontend drivers specify frequencies in kHz, > while terrestrial/cable ones specify in Hz. That's confusing > for developers. > > However, the main problem is that universal frontends capable > of handling both satellite and non-satelite delivery systems > are appearing. We end by needing to hack the drivers in > order to support such hybrid frontends. > > So, convert everything to specify frontend frequencies in Hz. > > Tested-by: Katsuhiro Suzuki <suzuki.katsuhiro@xxxxxxxxxxxxx> > Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@xxxxxxxxxx> > --- > diff --git a/drivers/media/dvb-core/dvb_frontend.c b/drivers/media/dvb-core/dvb_frontend.c > index 75e95b56f8b3..3b9dca7d7d02 100644 > --- a/drivers/media/dvb-core/dvb_frontend.c > +++ b/drivers/media/dvb-core/dvb_frontend.c [...] > @@ -2391,9 +2417,19 @@ static int dvb_frontend_handle_ioctl(struct file *file, > > case FE_GET_INFO: { > struct dvb_frontend_info *info = parg; > + memset(info, 0, sizeof(*info)); > > - memcpy(info, &fe->ops.info, sizeof(struct dvb_frontend_info)); > - dvb_frontend_get_frequency_limits(fe, &info->frequency_min, &info->frequency_max); > + strcpy(info->name, fe->ops.info.name); > + info->frequency_stepsize = fe->ops.info.frequency_stepsize_hz; > + info->frequency_tolerance = fe->ops.info.frequency_tolerance_hz; The variables frequency_stepsize and frequency_tolerance are assigned again some lines below. > + info->symbol_rate_min = fe->ops.info.symbol_rate_min; > + info->symbol_rate_max = fe->ops.info.symbol_rate_max; > + info->symbol_rate_tolerance = fe->ops.info.symbol_rate_tolerance; > + info->caps = fe->ops.info.caps; > + info->frequency_stepsize = dvb_frontend_get_stepsize(fe); > + dvb_frontend_get_frequency_limits(fe, &info->frequency_min, > + &info->frequency_max, > + &info->frequency_tolerance); > > /* > * Associate the 4 delivery systems supported by DVBv3 Matthias