Path: csiph.com!1.us.feeder.erje.net!2.us.feeder.erje.net!feeder.erje.net!1.eu.feeder.erje.net!weretis.net!feeder4.news.weretis.net!news.unit0.net!news.panservice.it!bofh.it!news.nic.it!robomod From: Alexandre Belloni Newsgroups: linux.kernel Subject: Re: [PATCH 0/5] Convert to use devm_*() for amba attached modules Date: Sun, 26 Mar 2017 17:30:02 +0200 Message-ID: References: X-Original-To: Leo Yan MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: NeoMutt/20170113 (1.7.2) Sender: robomod@news.nic.it List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Approved: robomod@news.nic.it Lines: 24 Organization: linux.* mail to news gateway X-Original-Cc: Russell King , Dmitry Torokhov , Alessandro Zummo , Linus Walleij , Baptiste Reynal , Alex Williamson , Jaroslav Kysela , Takashi Iwai , linux-input@vger.kernel.org, linux-kernel@vger.kernel.org, rtc-linux@googlegroups.com, linux-arm-kernel@lists.infradead.org, kvm@vger.kernel.org, alsa-devel@alsa-project.org X-Original-Date: Sun, 26 Mar 2017 17:20:50 +0200 X-Original-Message-ID: <20170326152050.v47z36eud6xvrcpt@piout.net> X-Original-References: <1490539314-9681-1-git-send-email-leo.yan@linaro.org> X-Original-Sender: linux-kernel-owner@vger.kernel.org Xref: csiph.com linux.kernel:1609342 On 26/03/2017 at 22:41:49 +0800, Leo Yan wrote: > When review device driver modules which attach to amba bus, found > several modules are not using devm_*() apis to manage resource. As > result, some drivers have memory leakage or missing iomem unmapping > when rmmod module. And the code has many "goto" tags to handle > different failures. > > So this patch series is to convert to use devm_*() for moudules which > are attached to amba bus to manage resource and get more robust and > neat code. > > Patch 0003 "drivers/rtc/rtc-pl031.c: Convert to use devm_*()" has been > verified on 96boards Hikey. Other patches can pass building but have > not really tested on hardware. > If your plan is to actually remove usage of amba_request_regions() and amba_release_regions(), you should do so in its own patch sets instead of hiding that in a useless cleanup series. -- Alexandre Belloni, Free Electrons Embedded Linux and Kernel engineering http://free-electrons.com