lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20201005153143.GB2372768@kroah.com>
Date:   Mon, 5 Oct 2020 17:31:43 +0200
From:   Greg KH <gregkh@...uxfoundation.org>
To:     pierre kuo <vichy.kuo@...il.com>
Cc:     rafael@...nel.org,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 2/2] driver core: platform: provide
 devm_platform_iounremap_resource

On Mon, Oct 05, 2020 at 11:23:18PM +0800, pierre kuo wrote:
> hi Greg:
> > Why are you adding new functions but not actually calling them anywhere?
> 
> Below patch introduce a single helper, devm_platform_ioremap_resource,
> which combines
> platform_get_resource() and devm_ioremap_resource(). But there is no
> single helper to release
> those resources in driver removing stage.
> 
> https://lore.kernel.org/lkml/20190215152507.31066-2-brgl@bgdev.pl/
> 
> That means driver owner still need to call below (*) and (**) for
> releasing resource.
> Therefore, this patch adds a single release helper that can be paired with
> devm_platform_ioremap_resource.
> 
> Appreciate ur kind help,
> 
> foo_probe(pdev)
> {
>     iomem = devm_platform_ioremap_resource(pdev, 0);
>     ....
> }
> 
> 
> foo_remove(pdev)
> {
>     devm_iounmap(iomem);   (*)
>     devm_release_mem_region(dev, res->start, size); (**)
>    ........................
> }

I don't understand this at all, sorry.  Please submit your patch series,
with some drivers converted to use the new functions.  Otherwise we can
not properly review it.

thanks,

greg k-h

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ