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:   Sat, 22 Jan 2022 14:02:36 -0500
From:   Sasha Levin <sashal@...nel.org>
To:     Vladimir Oltean <vladimir.oltean@....com>
Cc:     "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "stable@...r.kernel.org" <stable@...r.kernel.org>,
        Colin Foster <colin.foster@...advantage.com>,
        Florian Fainelli <f.fainelli@...il.com>,
        Jakub Kicinski <kuba@...nel.org>,
        Claudiu Manoil <claudiu.manoil@....com>,
        "alexandre.belloni@...tlin.com" <alexandre.belloni@...tlin.com>,
        "UNGLinuxDriver@...rochip.com" <UNGLinuxDriver@...rochip.com>,
        "andrew@...n.ch" <andrew@...n.ch>,
        "vivien.didelot@...il.com" <vivien.didelot@...il.com>,
        "davem@...emloft.net" <davem@...emloft.net>,
        "linux@...linux.org.uk" <linux@...linux.org.uk>,
        "netdev@...r.kernel.org" <netdev@...r.kernel.org>
Subject: Re: [PATCH AUTOSEL 5.16 108/217] net: dsa: ocelot: felix: Remove
 requirement for PCS in felix devices

On Tue, Jan 18, 2022 at 12:23:17PM +0000, Vladimir Oltean wrote:
>Hello Sasha,
>
>On Mon, Jan 17, 2022 at 09:17:51PM -0500, Sasha Levin wrote:
>> From: Colin Foster <colin.foster@...advantage.com>
>>
>> [ Upstream commit 49af6a7620c53b779572abfbfd7778e113154330 ]
>>
>> Existing felix devices all have an initialized pcs array. Future devices
>> might not, so running a NULL check on the array before dereferencing it
>> will allow those future drivers to not crash at this point
>>
>> Signed-off-by: Colin Foster <colin.foster@...advantage.com>
>> Reviewed-by: Vladimir Oltean <vladimir.oltean@....com>
>> Reviewed-by: Florian Fainelli <f.fainelli@...il.com>
>> Signed-off-by: Jakub Kicinski <kuba@...nel.org>
>> Signed-off-by: Sasha Levin <sashal@...nel.org>
>> ---
>>  drivers/net/dsa/ocelot/felix.c | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/drivers/net/dsa/ocelot/felix.c b/drivers/net/dsa/ocelot/felix.c
>> index f1a05e7dc8181..221440a61e17e 100644
>> --- a/drivers/net/dsa/ocelot/felix.c
>> +++ b/drivers/net/dsa/ocelot/felix.c
>> @@ -823,7 +823,7 @@ static void felix_phylink_mac_config(struct dsa_switch *ds, int port,
>>  	struct felix *felix = ocelot_to_felix(ocelot);
>>  	struct dsa_port *dp = dsa_to_port(ds, port);
>>
>> -	if (felix->pcs[port])
>> +	if (felix->pcs && felix->pcs[port])
>>  		phylink_set_pcs(dp->pl, &felix->pcs[port]->pcs);
>>  }
>>
>> --
>> 2.34.1
>>
>
>Please drop this patch from all stable branches (5.16, 5.15, 5.10).

Dropped, thanks!

-- 
Thanks,
Sasha

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ