net: phy: micrel: add support for KSZ8795

This is adds support for the PHYs in the KSZ8795 5port managed switch.

It will allow to detect the link between the switch and the soc
and uses the same read_status functions as the KSZ8873MLL switch.

Signed-off-by: Sean Nyekjaer <sean.nyekjaer@prevas.dk>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by Sean Nyekjaer and committed by David S. Miller 9d162ed6 95120ebf

+16
+14
drivers/net/phy/micrel.c
··· 1008 .get_stats = kszphy_get_stats, 1009 .suspend = genphy_suspend, 1010 .resume = genphy_resume, 1011 } }; 1012 1013 module_phy_driver(ksphy_driver);
··· 1008 .get_stats = kszphy_get_stats, 1009 .suspend = genphy_suspend, 1010 .resume = genphy_resume, 1011 + }, { 1012 + .phy_id = PHY_ID_KSZ8795, 1013 + .phy_id_mask = MICREL_PHY_ID_MASK, 1014 + .name = "Micrel KSZ8795", 1015 + .features = (SUPPORTED_Pause | SUPPORTED_Asym_Pause), 1016 + .flags = PHY_HAS_MAGICANEG | PHY_HAS_INTERRUPT, 1017 + .config_init = kszphy_config_init, 1018 + .config_aneg = ksz8873mll_config_aneg, 1019 + .read_status = ksz8873mll_read_status, 1020 + .get_sset_count = kszphy_get_sset_count, 1021 + .get_strings = kszphy_get_strings, 1022 + .get_stats = kszphy_get_stats, 1023 + .suspend = genphy_suspend, 1024 + .resume = genphy_resume, 1025 } }; 1026 1027 module_phy_driver(ksphy_driver);
+2
include/linux/micrel_phy.h
··· 35 #define PHY_ID_KSZ886X 0x00221430 36 #define PHY_ID_KSZ8863 0x00221435 37 38 /* struct phy_device dev_flags definitions */ 39 #define MICREL_PHY_50MHZ_CLK 0x00000001 40 #define MICREL_PHY_FXEN 0x00000002
··· 35 #define PHY_ID_KSZ886X 0x00221430 36 #define PHY_ID_KSZ8863 0x00221435 37 38 + #define PHY_ID_KSZ8795 0x00221550 39 + 40 /* struct phy_device dev_flags definitions */ 41 #define MICREL_PHY_50MHZ_CLK 0x00000001 42 #define MICREL_PHY_FXEN 0x00000002