mdio: Move allocation of interrupts into core

Have mdio_alloc() create the array of interrupt numbers, and
initialize it to POLLING. This is what most MDIO drivers want, so
allowing code to be removed from the drivers.

Signed-off-by: Andrew Lunn <andrew@lunn.ch>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Andrew Lunn 2016-01-06 20:11:15 +01:00 committed by David S. Miller
parent 35d2aeac98
commit e7f4dc3536
54 changed files with 48 additions and 396 deletions

View file

@ -189,10 +189,10 @@ struct mii_bus {
u32 phy_ignore_ta_mask;
/*
* Pointer to an array of interrupts, each PHY's
* interrupt at the index matching its address
* An array of interrupts, each PHY's interrupt at the index
* matching its address
*/
int *irq;
int irq[PHY_MAX_ADDR];
};
#define to_mii_bus(d) container_of(d, struct mii_bus, dev)