Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

of: mdio: preserve phy dev_flags in of_phy_connect()

Replace assignment "=" with OR "|=" for "phy->dev_flags" so "dev_flags"
configured in phy probe() function can be preserved.

The idea is similar to commit e7312efbd5de ("net: phy: modify assignment
to OR for dev_flags in phy_attach_direct").

Signed-off-by: Tao Ren <rentao.bupt@gmail.com>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Tao Ren and committed by
David S. Miller
902053f1 78e57f15

+1 -1
+1 -1
drivers/of/of_mdio.c
··· 380 380 if (!phy) 381 381 return NULL; 382 382 383 - phy->dev_flags = flags; 383 + phy->dev_flags |= flags; 384 384 385 385 ret = phy_connect_direct(dev, phy, hndlr, iface); 386 386