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: <7a18452c-8c9c-df7d-b175-529ab690623f@ti.com>
Date:   Mon, 16 Nov 2020 11:31:58 -0600
From:   Suman Anna <s-anna@...com>
To:     Grzegorz Jaszczyk <grzegorz.jaszczyk@...aro.org>,
        <ssantosh@...nel.org>
CC:     <santosh.shilimkar@...cle.com>, <lee.jones@...aro.org>,
        <linux-kernel@...r.kernel.org>, <linux-omap@...r.kernel.org>,
        <linux-arm-kernel@...ts.infradead.org>, <praneeth@...com>,
        <tony@...mide.com>, Wei Yongjun <weiyongjun1@...wei.com>
Subject: Re: [PATCH v2] soc: ti: pruss: Fix wrong check against
 *get_match_data return value

Hi Santosh,

On 11/16/20 11:22 AM, Grzegorz Jaszczyk wrote:
> Since the of_device_get_match_data() doesn't return error code, remove
> wrong IS_ERR test. Proper check against NULL pointer is already done
> later before usage: if (data && data->...).
> 
> Additionally, proceeding with empty device data is valid (e.g. in case
> of "ti,am3356-pruss").
> 
> Fixes: ba59c9b43c86 ("soc: ti: pruss: support CORECLK_MUX and IEPCLK_MUX")
> Reported-by: Wei Yongjun <weiyongjun1@...wei.com>
> Signed-off-by: Grzegorz Jaszczyk <grzegorz.jaszczyk@...aro.org>
> Acked-by: Suman Anna <s-anna@...com>

Can you please pick this up for 5.10-rc's?

Thanks,
Suman

> ---
> v1->v2:
> - Add the appropriate Fixes: tag.
> - %s/Remove/Fix/ in patch title.
> - Add Suman's Acked-by.
> ---
>  drivers/soc/ti/pruss.c | 6 ------
>  1 file changed, 6 deletions(-)
> 
> diff --git a/drivers/soc/ti/pruss.c b/drivers/soc/ti/pruss.c
> index cc0b4ad7a3d3..5d6e7132a5c4 100644
> --- a/drivers/soc/ti/pruss.c
> +++ b/drivers/soc/ti/pruss.c
> @@ -126,8 +126,6 @@ static int pruss_clk_init(struct pruss *pruss, struct device_node *cfg_node)
>  	int ret = 0;
>  
>  	data = of_device_get_match_data(dev);
> -	if (IS_ERR(data))
> -		return -ENODEV;
>  
>  	clks_np = of_get_child_by_name(cfg_node, "clocks");
>  	if (!clks_np) {
> @@ -175,10 +173,6 @@ static int pruss_probe(struct platform_device *pdev)
>  	const char *mem_names[PRUSS_MEM_MAX] = { "dram0", "dram1", "shrdram2" };
>  
>  	data = of_device_get_match_data(&pdev->dev);
> -	if (IS_ERR(data)) {
> -		dev_err(dev, "missing private data\n");
> -		return -ENODEV;
> -	}
>  
>  	ret = dma_set_coherent_mask(dev, DMA_BIT_MASK(32));
>  	if (ret) {
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ