net: dsa: mv88e6xxx: Add watchdog interrupt handler
The switch contains a watchdog looking for issues with the internal gubbins of the switch. Hook the interrupt the watchdog triggers and log the value of the control register indicating why the watchdog fired. The watchdog can only be cleared with a switch reset, which will destroy the current configuration. Rather than doing this, just disable the interrupt. The mv88e6390 family has different watchdog registers. So use an ops structure, so support for the mv88e6390 family can be added later. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net>
Este cometimento está contido em:

cometido por
David S. Miller

ascendente
3b03cc0783
cometimento
fcd25166d9
@@ -46,6 +46,8 @@ int mv88e6xxx_g2_irq_setup(struct mv88e6xxx_chip *chip);
|
||||
void mv88e6xxx_g2_irq_free(struct mv88e6xxx_chip *chip);
|
||||
int mv88e6095_g2_mgmt_rsvd2cpu(struct mv88e6xxx_chip *chip);
|
||||
|
||||
extern const struct mv88e6xxx_irq_ops mv88e6097_watchdog_ops;
|
||||
|
||||
#else /* !CONFIG_NET_DSA_MV88E6XXX_GLOBAL2 */
|
||||
|
||||
static inline int mv88e6xxx_g2_require(struct mv88e6xxx_chip *chip)
|
||||
@@ -125,6 +127,8 @@ static inline int mv88e6095_g2_mgmt_rsvd2cpu(struct mv88e6xxx_chip *chip)
|
||||
return -EOPNOTSUPP;
|
||||
}
|
||||
|
||||
static const struct mv88e6xxx_irq_ops mv88e6097_watchdog_ops = {};
|
||||
|
||||
#endif /* CONFIG_NET_DSA_MV88E6XXX_GLOBAL2 */
|
||||
|
||||
#endif /* _MV88E6XXX_GLOBAL2_H */
|
||||
|
Criar uma nova questão referindo esta
Bloquear um utilizador