Lines Matching defs:temp

757 	int temp;
764 temp = phy_read(phydev, MII_M1111_PHY_EXT_SR);
765 if (temp < 0)
766 return temp;
768 temp &= ~(MII_M1111_HWCFG_MODE_MASK);
770 if (temp & MII_M1111_HWCFG_FIBER_COPPER_RES)
771 temp |= MII_M1111_HWCFG_MODE_FIBER_RGMII;
773 temp |= MII_M1111_HWCFG_MODE_COPPER_RGMII;
775 return phy_write(phydev, MII_M1111_PHY_EXT_SR, temp);
2144 static int m88e1121_get_temp(struct phy_device *phydev, long *temp)
2150 *temp = 0;
2181 *temp = ((val & MII_88E1121_MISC_TEST_TEMP_MASK) - 5) * 5000;
2189 u32 attr, int channel, long *temp)
2196 err = m88e1121_get_temp(phydev, temp);
2256 static int m88e1510_get_temp(struct phy_device *phydev, long *temp)
2260 *temp = 0;
2267 *temp = ((ret & MII_88E1510_TEMP_SENSOR_MASK) - 25) * 1000;
2272 static int m88e1510_get_temp_critical(struct phy_device *phydev, long *temp)
2276 *temp = 0;
2283 *temp = (((ret & MII_88E1510_MISC_TEST_TEMP_THRESHOLD_MASK) >>
2286 *temp *= 1000;
2291 static int m88e1510_set_temp_critical(struct phy_device *phydev, long temp)
2293 temp = temp / 1000;
2294 temp = clamp_val(DIV_ROUND_CLOSEST(temp, 5) + 5, 0, 0x1f);
2299 temp << MII_88E1510_MISC_TEST_TEMP_THRESHOLD_SHIFT);
2320 u32 attr, int channel, long *temp)
2327 err = m88e1510_get_temp(phydev, temp);
2330 err = m88e1510_get_temp_critical(phydev, temp);
2333 err = m88e1510_get_temp_alarm(phydev, temp);
2344 u32 attr, int channel, long temp)
2351 err = m88e1510_set_temp_critical(phydev, temp);
2404 static int m88e6390_get_temp(struct phy_device *phydev, long *temp)
2411 *temp = 0;
2444 *temp = (sum - 75) * 1000;
2464 u32 attr, int channel, long *temp)
2471 err = m88e6390_get_temp(phydev, temp);