@@ -4526,6 +4526,8 @@ static const struct mv88e6xxx_ops mv88e6172_ops = {
.gpio_ops = &mv88e6352_gpio_ops,
.phylink_get_caps = mv88e6352_phylink_get_caps,
.pcs_ops = &mv88e6352_pcs_ops,
+ .led_brightness_set = mv88e6352_port_led_brightness_set,
+ .led_blink_set = mv88e6352_port_led_blink_set,
};
static const struct mv88e6xxx_ops mv88e6175_ops = {
@@ -4628,6 +4630,8 @@ static const struct mv88e6xxx_ops mv88e6176_ops = {
.gpio_ops = &mv88e6352_gpio_ops,
.phylink_get_caps = mv88e6352_phylink_get_caps,
.pcs_ops = &mv88e6352_pcs_ops,
+ .led_brightness_set = mv88e6352_port_led_brightness_set,
+ .led_blink_set = mv88e6352_port_led_blink_set,
};
static const struct mv88e6xxx_ops mv88e6185_ops = {
@@ -4897,6 +4901,8 @@ static const struct mv88e6xxx_ops mv88e6240_ops = {
.ptp_ops = &mv88e6352_ptp_ops,
.phylink_get_caps = mv88e6352_phylink_get_caps,
.pcs_ops = &mv88e6352_pcs_ops,
+ .led_brightness_set = mv88e6352_port_led_brightness_set,
+ .led_blink_set = mv88e6352_port_led_blink_set,
};
static const struct mv88e6xxx_ops mv88e6250_ops = {
@@ -5310,6 +5316,8 @@ static const struct mv88e6xxx_ops mv88e6352_ops = {
.serdes_set_tx_amplitude = mv88e6352_serdes_set_tx_amplitude,
.phylink_get_caps = mv88e6352_phylink_get_caps,
.pcs_ops = &mv88e6352_pcs_ops,
+ .led_brightness_set = mv88e6352_port_led_brightness_set,
+ .led_blink_set = mv88e6352_port_led_blink_set,
};
static const struct mv88e6xxx_ops mv88e6390_ops = {
@@ -661,6 +661,13 @@ struct mv88e6xxx_ops {
/* Max Frame Size */
int (*set_max_frame_size)(struct mv88e6xxx_chip *chip, int mtu);
+
+ /* LEDs */
+ int (*led_brightness_set)(struct mv88e6xxx_chip *chip, int port,
+ u8 led, enum led_brightness value);
+ int (*led_blink_set)(struct mv88e6xxx_chip *chip, int port, u8 led,
+ unsigned long *delay_on,
+ unsigned long *delay_off);
};
struct mv88e6xxx_irq_ops {
Make the LED brightness and blink helpers available for the 6352 family via their ops structure. Signed-off-by: Andrew Lunn <andrew@lunn.ch> --- drivers/net/dsa/mv88e6xxx/chip.c | 8 ++++++++ drivers/net/dsa/mv88e6xxx/chip.h | 7 +++++++ 2 files changed, 15 insertions(+)