From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2992705AbcBTEQx (ORCPT ); Fri, 19 Feb 2016 23:16:53 -0500 Received: from hqemgate16.nvidia.com ([216.228.121.65]:3176 "EHLO hqemgate16.nvidia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1424427AbcBTEQv (ORCPT ); Fri, 19 Feb 2016 23:16:51 -0500 X-PGP-Universal: processed; by hqnvupgp07.nvidia.com on Fri, 19 Feb 2016 20:15:51 -0800 Message-ID: <56C7E5DE.30505@nvidia.com> Date: Sat, 20 Feb 2016 09:34:46 +0530 From: Laxman Dewangan User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.4.0 MIME-Version: 1.0 To: Linus Walleij CC: Alexandre Courbot , "linux-gpio@vger.kernel.org" , "linux-kernel@vger.kernel.org" Subject: Re: [PATCH 1/1] gpio: add devm_ apis for gpio_chip_add and remove References: <1455542246-16761-1-git-send-email-ldewangan@nvidia.com> In-Reply-To: X-Originating-IP: [10.19.65.30] X-ClientProxiedBy: DRUKMAIL102.nvidia.com (10.25.59.20) To bgmail102.nvidia.com (10.25.59.11) Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tuesday 16 February 2016 08:33 PM, Linus Walleij wrote: > On Mon, Feb 15, 2016 at 2:17 PM, Laxman Dewangan wrote: > >> Add device managed APIs devm_gpiochip_add_data() and >> devm_gpiochip_remove() for the APIs gpiochip_add_data() >> and gpiochip_remove(). >> >> This helps in reducing code in error path and sometimes >> removal of .remove callback for driver unbind. >> >> Signed-off-by: Laxman Dewangan > I like the looks of this. > > One comment: you must also patch > Documentation/driver-model/devres.txt Sure, > > Will you also follow up with a massive patch set making use of > this new API? I feel bad about merging an API if it's not used. > > Thanks for only supporting this for the new _data() function. > > Yes, I have planned for this to use this new API. This is just for getting review whether fine or not to have devm_* APIs so that I can make changes on rest of driver to use this new APIs.