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]

 



On 12/20/2011 02:32 PM, Tatsunosuke Tobita wrote:

> 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 ?


No, it means Greg's driver-core tree. He queued the changes to next, and will
be merged to linus' tree through next merge window, and input-next is the same, too.

You can do like this:
git remote add driver-core git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core.git
git remote update
git checkout -b driver-core-next driver-core/driver-core-next

Then you can see these module_*_driver changes in this branch,
but, you are doing input drivers, so, you must cook patches against Dmitry's input-next tree,
not Greg's driver-core-next branch.

I hope you can understand what I'm trying to say.

> 
> 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?


Yeah, you are right.

> 
> If my questions above are clear, I'll be able to correctly rewrite the code.


IMO, please do.

But, Dmitry, what do you think?


Thanks
-Wanlong Gao

> 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
> 


--
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