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]
Message-ID: <YL3mBPDLK5PNG8cm@kuha.fi.intel.com>
Date:   Mon, 7 Jun 2021 12:25:24 +0300
From:   Heikki Krogerus <heikki.krogerus@...ux.intel.com>
To:     Andy Shevchenko <andy.shevchenko@...il.com>
Cc:     Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        linux-usb@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v1 2/3] usb: typec: intel_pmc_mux: Add missed error check
 for devm_ioremap_resource()

On Sun, Jun 06, 2021 at 11:09:10PM +0300, Andy Shevchenko wrote:
> devm_ioremap_resource() can return an error, add missed check for it.
> 
> Fixes: 43d596e32276 ("usb: typec: intel_pmc_mux: Check the port status before connect")
> Cc: Heikki Krogerus <heikki.krogerus@...ux.intel.com>
> Signed-off-by: Andy Shevchenko <andy.shevchenko@...il.com>

Reviewed-by: Heikki Krogerus <heikki.krogerus@...ux.intel.com>

> ---
>  drivers/usb/typec/mux/intel_pmc_mux.c | 5 +++++
>  1 file changed, 5 insertions(+)
> 
> diff --git a/drivers/usb/typec/mux/intel_pmc_mux.c b/drivers/usb/typec/mux/intel_pmc_mux.c
> index 134325444e6a..de40276cc18b 100644
> --- a/drivers/usb/typec/mux/intel_pmc_mux.c
> +++ b/drivers/usb/typec/mux/intel_pmc_mux.c
> @@ -586,6 +586,11 @@ static int pmc_usb_probe_iom(struct pmc_usb *pmc)
>  		return -ENOMEM;
>  	}
>  
> +	if (IS_ERR(pmc->iom_base)) {
> +		put_device(&adev->dev);
> +		return PTR_ERR(pmc->iom_base);
> +	}
> +
>  	pmc->iom_adev = adev;
>  
>  	return 0;
> -- 
> 2.31.1

-- 
heikki

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ