Commit 15f03ffe authored by Fabio Estevam's avatar Fabio Estevam Committed by Jakub Kicinski
Browse files

net: phy: micrel: Pass .probe for KS8737



Since commit f1131b9c ("net: phy: micrel: use
kszphy_suspend()/kszphy_resume for irq aware devices") the kszphy_suspend/
resume hooks are used.

These functions require the probe function to be called so that
priv can be allocated.

Otherwise, a NULL pointer dereference happens inside
kszphy_config_reset().

Cc: stable@vger.kernel.org
Fixes: f1131b9c ("net: phy: micrel: use kszphy_suspend()/kszphy_resume for irq aware devices")
Reported-by: default avatarAndrew Lunn <andrew@lunn.ch>
Signed-off-by: default avatarFabio Estevam <festevam@denx.de>
Reviewed-by: default avatarAndrew Lunn <andrew@lunn.ch>
Link: https://lore.kernel.org/r/20220504143104.1286960-2-festevam@gmail.com


Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
parent e333eed6
Loading
Loading
Loading
Loading
+1 −0
Original line number Original line Diff line number Diff line
@@ -2657,6 +2657,7 @@ static struct phy_driver ksphy_driver[] = {
	.name		= "Micrel KS8737",
	.name		= "Micrel KS8737",
	/* PHY_BASIC_FEATURES */
	/* PHY_BASIC_FEATURES */
	.driver_data	= &ks8737_type,
	.driver_data	= &ks8737_type,
	.probe		= kszphy_probe,
	.config_init	= kszphy_config_init,
	.config_init	= kszphy_config_init,
	.config_intr	= kszphy_config_intr,
	.config_intr	= kszphy_config_intr,
	.handle_interrupt = kszphy_handle_interrupt,
	.handle_interrupt = kszphy_handle_interrupt,