Commit 56ce5ac4 authored by Andreas Oberritter's avatar Andreas Oberritter Committed by Mauro Carvalho Chehab

[media] DVB: dvb_frontend: fix stale parameters on initial frontend event

  Modify it to use the data given by the user.
Signed-off-by: default avatarAndreas Oberritter <obi@linuxtv.org>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent f00fd919
...@@ -1827,6 +1827,13 @@ static int dvb_frontend_ioctl_legacy(struct file *file, ...@@ -1827,6 +1827,13 @@ static int dvb_frontend_ioctl_legacy(struct file *file,
dtv_property_cache_sync(fe, c, &fepriv->parameters_in); dtv_property_cache_sync(fe, c, &fepriv->parameters_in);
} }
/*
* Initialize output parameters to match the values given by
* the user. FE_SET_FRONTEND triggers an initial frontend event
* with status = 0, which copies output parameters to userspace.
*/
fepriv->parameters_out = fepriv->parameters_in;
memset(&fetunesettings, 0, sizeof(struct dvb_frontend_tune_settings)); memset(&fetunesettings, 0, sizeof(struct dvb_frontend_tune_settings));
memcpy(&fetunesettings.parameters, parg, memcpy(&fetunesettings.parameters, parg,
sizeof (struct dvb_frontend_parameters)); sizeof (struct dvb_frontend_parameters));
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment