/* RETURN: 0 - Successfull reset. -1 - Timeout.  */
static int mv88e1xxx_reset(struct cphy *cphy, int wait)
/* RETURN: 0 - Successfull reset. -1 - Timeout.  */
static int mv88e1xxx_reset(struct cphy *cphy, int wait)
{
	u32 ctl;
	int time_out = 1000;
	mdio_set_bit(cphy, MII_BMCR, BMCR_RESET);
	do {
		(void) simple_mdio_read(cphy, MII_BMCR, &ctl);
		ctl &= BMCR_RESET;
		if (ctl)
			udelay(1);
	} while (ctl && --time_out);
	return ctl ? -1 : 0;
}