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] [thread-next>] [day] [month] [year] [list]
Date:   Tue, 5 Jul 2022 16:38:53 +0200
From:   "Rafael J. Wysocki" <rafael.j.wysocki@...el.com>
To:     Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
        <linux-kernel@...r.kernel.org>
CC:     <john.garry@...wei.com>
Subject: Re: [PATCH v1 2/4] bus: hisi_lpc: Use devm_platform_ioremap_resource

On 7/5/2022 1:43 PM, Andy Shevchenko wrote:
> The struct resource is not used for anything else, so we can simplify
> the code a bit by using the helper function.
>
> Signed-off-by: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>

Reviewed-by: Rafael J. Wysocki <rafael.j.wysocki@...el.com>


> ---
>   drivers/bus/hisi_lpc.c | 4 +---
>   1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/drivers/bus/hisi_lpc.c b/drivers/bus/hisi_lpc.c
> index 6d432a07cbba..03d4d96ff794 100644
> --- a/drivers/bus/hisi_lpc.c
> +++ b/drivers/bus/hisi_lpc.c
> @@ -618,7 +618,6 @@ static int hisi_lpc_probe(struct platform_device *pdev)
>   	struct logic_pio_hwaddr *range;
>   	struct hisi_lpc_dev *lpcdev;
>   	resource_size_t io_end;
> -	struct resource *res;
>   	int ret;
>   
>   	lpcdev = devm_kzalloc(dev, sizeof(*lpcdev), GFP_KERNEL);
> @@ -627,8 +626,7 @@ static int hisi_lpc_probe(struct platform_device *pdev)
>   
>   	spin_lock_init(&lpcdev->cycle_lock);
>   
> -	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
> -	lpcdev->membase = devm_ioremap_resource(dev, res);
> +	lpcdev->membase = devm_platform_ioremap_resource(pdev, 0);
>   	if (IS_ERR(lpcdev->membase))
>   		return PTR_ERR(lpcdev->membase);
>   


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ