OSDN Git Service

net: phy: restore mdio regs in the iproc mdio driver
authorArun Parameswaran <arun.parameswaran@broadcom.com>
Fri, 14 Feb 2020 21:47:46 +0000 (13:47 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 5 Mar 2020 15:42:16 +0000 (16:42 +0100)
commit8ff02134901d54e125b5304dd6e4d2449cfaed69
tree704b59dfd9c29c2b5c0710e17e986c19c88a7ff8
parent41269509bbd2da66a9e127a5ae4b719f07f9b50f
net: phy: restore mdio regs in the iproc mdio driver

commit 6f08e98d62799e53c89dbf2c9a49d77e20ca648c upstream.

The mii management register in iproc mdio block
does not have a retention register so it is lost on suspend.
Save and restore value of register while resuming from suspend.

Fixes: bb1a619735b4 ("net: phy: Initialize mdio clock at probe function")
Signed-off-by: Arun Parameswaran <arun.parameswaran@broadcom.com>
Signed-off-by: Scott Branden <scott.branden@broadcom.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/phy/mdio-bcm-iproc.c