Re: [PATCH 1/1] rtc: rtc-ds1307: use devm_*() functions

From: devendra.aaru
Date: Mon May 27 2013 - 00:22:00 EST


On Mon, May 27, 2013 at 6:32 AM, Jingoo Han <jg1.han@xxxxxxxxxxx> wrote:
> On Saturday, May 25, 2013 10:51 AM, Devendra Naga wrote:
>> On Sat, May 25, 2013 at 10:41 AM, Nikolay Balandin wrote:
>> > From: Nikolay Balandin <nbalandin@xxxxxxxxxxxxx>
>
> [.....]
>
>> >
>> > - ds1307->rtc = rtc_device_register(client->name, &client->dev,
>> > + ds1307->rtc = devm_rtc_device_register(&client->dev, client->name,
>> > &ds13xx_rtc_ops, THIS_MODULE);
>
> Hi Nikolay Baladin, Devendra Naga,
>
> Here, "devm"_rtc_device_register() is used.
> Thus, rtc_device_unregister() will be called after remove() or
> on probe failure.
>

You are correct, I am not aware of the new API that is added by you
in c100a5e0255.

Very sorry Nikolay Baladin, I would really have seen and commented on the patch.

Thanks for letting me know. :)


>
>> > if (IS_ERR(ds1307->rtc)) {
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/