net: phy: bcm7xxx: Plug in support for reading PHY error counters
authorFlorian Fainelli <f.fainelli@gmail.com>
Tue, 29 Nov 2016 17:57:18 +0000 (09:57 -0800)
committerDavid S. Miller <davem@davemloft.net>
Wed, 30 Nov 2016 15:22:27 +0000 (10:22 -0500)
commitb23ce9e8b3d6e862ad2f7f818802ae4958550a51
treeb5df367d6fa9b47d49e635a8e23dc85b136dbff3
parent820ee17b8d3b2a57b1ea20b247cc6a1dddaf8b8d
net: phy: bcm7xxx: Plug in support for reading PHY error counters

Broadcom BCM7xxx internal PHYs can leverage the Broadcom PHY library
module PHY error counters helper functions, just implement the
appropriate PHY driver function calls to do so. We need to allocate some
storage space for our PHY statistics, and provide it to the Broadcom PHY
library, so do this in a specific probe function, and slightly wrap the
get_stats function call.

Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/phy/bcm7xxx.c