* [PATCH] staging: ste_rmi4: use module_i2c_driver to simplify the code
@ 2012-10-08 14:15 Wei Yongjun
2012-10-09 12:07 ` Linus Walleij
0 siblings, 1 reply; 3+ messages in thread
From: Wei Yongjun @ 2012-10-08 14:15 UTC (permalink / raw)
To: gregkh, rydberg; +Cc: yongjun_wei, devel, linux-input
From: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Use the module_i2c_driver() macro to make the code smaller
and a bit simpler.
dpatch engine is used to auto generate this patch.
(https://github.com/weiyj/dpatch)
Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
---
drivers/staging/ste_rmi4/synaptics_i2c_rmi4.c | 24 +-----------------------
1 file changed, 1 insertion(+), 23 deletions(-)
diff --git a/drivers/staging/ste_rmi4/synaptics_i2c_rmi4.c b/drivers/staging/ste_rmi4/synaptics_i2c_rmi4.c
index 277491a..37d19c6 100644
--- a/drivers/staging/ste_rmi4/synaptics_i2c_rmi4.c
+++ b/drivers/staging/ste_rmi4/synaptics_i2c_rmi4.c
@@ -1143,30 +1143,8 @@ static struct i2c_driver synaptics_rmi4_driver = {
.remove = __devexit_p(synaptics_rmi4_remove),
.id_table = synaptics_rmi4_id_table,
};
-/**
- * synaptics_rmi4_init() - Initialize the touchscreen driver
- *
- * This function uses to initializes the synaptics
- * touchscreen driver and returns integer.
- */
-static int __init synaptics_rmi4_init(void)
-{
- return i2c_add_driver(&synaptics_rmi4_driver);
-}
-/**
- * synaptics_rmi4_exit() - De-initialize the touchscreen driver
- *
- * This function uses to de-initialize the synaptics
- * touchscreen driver and returns none.
- */
-static void __exit synaptics_rmi4_exit(void)
-{
- i2c_del_driver(&synaptics_rmi4_driver);
-}
-
-module_init(synaptics_rmi4_init);
-module_exit(synaptics_rmi4_exit);
+module_i2c_driver(synaptics_rmi4_driver);
MODULE_LICENSE("GPL v2");
MODULE_AUTHOR("naveen.gaddipati@stericsson.com, js.ha@stericsson.com");
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] staging: ste_rmi4: use module_i2c_driver to simplify the code
2012-10-08 14:15 [PATCH] staging: ste_rmi4: use module_i2c_driver to simplify the code Wei Yongjun
@ 2012-10-09 12:07 ` Linus Walleij
2012-10-10 17:08 ` Henrik Rydberg
0 siblings, 1 reply; 3+ messages in thread
From: Linus Walleij @ 2012-10-09 12:07 UTC (permalink / raw)
To: Wei Yongjun; +Cc: gregkh, rydberg, yongjun_wei, devel, linux-input
On Mon, Oct 8, 2012 at 4:15 PM, Wei Yongjun <weiyj.lk@gmail.com> wrote:
> From: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
>
> Use the module_i2c_driver() macro to make the code smaller
> and a bit simpler.
>
> dpatch engine is used to auto generate this patch.
> (https://github.com/weiyj/dpatch)
>
> Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Why not?
Acked-by: Linus Walleij <linus.walleij@linaro.org>
Yours,
Linus Walleij
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] staging: ste_rmi4: use module_i2c_driver to simplify the code
2012-10-09 12:07 ` Linus Walleij
@ 2012-10-10 17:08 ` Henrik Rydberg
0 siblings, 0 replies; 3+ messages in thread
From: Henrik Rydberg @ 2012-10-10 17:08 UTC (permalink / raw)
To: Linus Walleij; +Cc: Wei Yongjun, gregkh, yongjun_wei, devel, linux-input
On Tue, Oct 09, 2012 at 02:07:59PM +0200, Linus Walleij wrote:
> On Mon, Oct 8, 2012 at 4:15 PM, Wei Yongjun <weiyj.lk@gmail.com> wrote:
>
> > From: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
> >
> > Use the module_i2c_driver() macro to make the code smaller
> > and a bit simpler.
> >
> > dpatch engine is used to auto generate this patch.
> > (https://github.com/weiyj/dpatch)
> >
> > Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
>
> Why not?
> Acked-by: Linus Walleij <linus.walleij@linaro.org>
Yep, why not :-)
Acked-by: Henrik Rydberg <rydberg@euromail.se>
Thanks,
Henrik
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2012-10-10 17:05 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-10-08 14:15 [PATCH] staging: ste_rmi4: use module_i2c_driver to simplify the code Wei Yongjun
2012-10-09 12:07 ` Linus Walleij
2012-10-10 17:08 ` Henrik Rydberg
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.