Gitweb: http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=9af596ebc7ad3afb0df520b4becad915dd5a5584 Commit: 9af596ebc7ad3afb0df520b4becad915dd5a5584 Parent: 7fd8b263678ab8430b49c99976ade681f8a78439 Author: Michael Krufky <[EMAIL PROTECTED]> AuthorDate: Wed Jun 6 16:15:48 2007 -0300 Committer: Mauro Carvalho Chehab <[EMAIL PROTECTED]> CommitDate: Wed Jul 18 14:24:04 2007 -0300
V4L/DVB (5756): Tda9887: store tuning operations in tuner_operations structure Create static struct tuner_operations tda9887_tuner_ops for tda9887 tuning function callback pointers Signed-off-by: Michael Krufky <[EMAIL PROTECTED]> Signed-off-by: Mauro Carvalho Chehab <[EMAIL PROTECTED]> --- drivers/media/video/tda9887.c | 16 ++++++++++------ 1 files changed, 10 insertions(+), 6 deletions(-) diff --git a/drivers/media/video/tda9887.c b/drivers/media/video/tda9887.c index 5bb7d19..caca109 100644 --- a/drivers/media/video/tda9887.c +++ b/drivers/media/video/tda9887.c @@ -599,6 +599,15 @@ static void tda9887_release(struct i2c_client *c) t->priv = NULL; } +static struct tuner_operations tda9887_tuner_ops = { + .set_tv_freq = tda9887_set_freq, + .set_radio_freq = tda9887_set_freq, + .standby = tda9887_standby, + .tuner_status = tda9887_tuner_status, + .get_afc = tda9887_get_afc, + .release = tda9887_release, +}; + int tda9887_tuner_init(struct i2c_client *c) { struct tda9887_priv *priv = NULL; @@ -614,12 +623,7 @@ int tda9887_tuner_init(struct i2c_client *c) tda9887_info("tda988[5/6/7] found @ 0x%x (%s)\n", t->i2c.addr, t->i2c.driver->driver.name); - t->ops.set_tv_freq = tda9887_set_freq; - t->ops.set_radio_freq = tda9887_set_freq; - t->ops.standby = tda9887_standby; - t->ops.tuner_status = tda9887_tuner_status; - t->ops.get_afc = tda9887_get_afc; - t->ops.release = tda9887_release; + memcpy(&t->ops, &tda9887_tuner_ops, sizeof(struct tuner_operations)); return 0; } - To unsubscribe from this list: send the line "unsubscribe git-commits-head" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html