Re: [PATCH] Input: Add a driver to support for Wacom I2C Stylus Device

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Wanlong,

Thank you for your review.
But, I'm not sure about driver-core-next; is this in linux-input somewhere?
or should I update my git branch ?

Also, I'm checking with your commit which was made yesterday and
it looks like  "module_i2c_driver" converges both init and exit into
one statement;
is my understanding correct?

If my questions above are clear, I'll be able to correctly rewrite the code.
So, please help to answer.

Thanks,

Tats

On Tue, Dec 20, 2011 at 3:05 PM, Wanlong Gao <gaowanlong@xxxxxxxxxxxxxx> wrote:
> On 12/20/2011 01:46 PM, Tatsunosuke Tobita wrote:
>
>> From: Tatsunosuke Tobita <tobita.tatsunosuke@xxxxxxxxxxx>
>>
>> This driver supports for Wacom Stylus Device with I2C interface.
>>
>> Signed-off-by: Tatsunosuke Tobita <tobita.tatsunosuke@xxxxxxxxxxx>
>> ---
>>  drivers/input/touchscreen/wacom_i2c.c |  250 +++++++++++++++++++++++++++++++++
>>  drivers/input/touchscreen/wacom_i2c.h |   55 +++++++
>>  2 files changed, 305 insertions(+), 0 deletions(-)
>>  create mode 100644 drivers/input/touchscreen/wacom_i2c.c
>>  create mode 100644 drivers/input/touchscreen/wacom_i2c.h
>>
>> diff --git a/drivers/input/touchscreen/wacom_i2c.c b/drivers/input/touchscreen/wacom_i2c.c
>> new file mode 100644
>> index 0000000..157bcc5
>> --- /dev/null
>> +++ b/drivers/input/touchscreen/wacom_i2c.c
>
>> +
>> +static struct i2c_driver wacom_i2c_driver = {
>> +     .driver = {
>> +             .name = "wacom_i2c",
>> +             .owner = THIS_MODULE,
>> +             .pm = &wacom_i2c_pm,
>> +     },
>> +
>> +     .probe = wacom_i2c_probe,
>> +     .remove = __devexit_p(wacom_i2c_remove),
>> +     .id_table = wacom_i2c_id,
>> +};
>> +
>> +static int __init wacom_i2c_init(void)
>> +{
>> +     return i2c_add_driver(&wacom_i2c_driver);
>> +}
>> +
>> +static void __exit wacom_i2c_exit(void)
>> +{
>> +     i2c_del_driver(&wacom_i2c_driver);
>> +}
>> +
>> +module_init(wacom_i2c_init);
>> +module_exit(wacom_i2c_exit);
>
>
> You can use module_i2c_driver(wacom_i2c_driver) instead of module_init{exit},
> it has been queued to driver-core-next already.
>
>
> Thanks
> -Wanlong Gao
>
--
To unsubscribe from this list: send the line "unsubscribe linux-input" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Media Devel]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Linux Wireless Networking]     [Linux Omap]

  Powered by Linux