xref: /linux/drivers/net/dsa/microchip/lan937x.h (revision 8f420456792308639fcbc15462050c521fbd127d)
155ab6ffaSArun Ramadoss /* SPDX-License-Identifier: GPL-2.0 */
255ab6ffaSArun Ramadoss /* Microchip lan937x dev ops headers
355ab6ffaSArun Ramadoss  * Copyright (C) 2019-2022 Microchip Technology Inc.
455ab6ffaSArun Ramadoss  */
555ab6ffaSArun Ramadoss 
655ab6ffaSArun Ramadoss #ifndef __LAN937X_CFG_H
755ab6ffaSArun Ramadoss #define __LAN937X_CFG_H
855ab6ffaSArun Ramadoss 
955ab6ffaSArun Ramadoss int lan937x_reset_switch(struct ksz_device *dev);
1055ab6ffaSArun Ramadoss int lan937x_setup(struct dsa_switch *ds);
1155ab6ffaSArun Ramadoss void lan937x_port_setup(struct ksz_device *dev, int port, bool cpu_port);
1255ab6ffaSArun Ramadoss void lan937x_config_cpu_port(struct dsa_switch *ds);
1355ab6ffaSArun Ramadoss int lan937x_switch_init(struct ksz_device *dev);
1455ab6ffaSArun Ramadoss void lan937x_switch_exit(struct ksz_device *dev);
15*8f420456SOleksij Rempel int lan937x_r_phy(struct ksz_device *dev, u16 addr, u16 reg, u16 *data);
16*8f420456SOleksij Rempel int lan937x_w_phy(struct ksz_device *dev, u16 addr, u16 reg, u16 val);
17ab882368SArun Ramadoss int lan937x_change_mtu(struct ksz_device *dev, int port, int new_mtu);
18c14e878dSArun Ramadoss void lan937x_phylink_get_caps(struct ksz_device *dev, int port,
19c14e878dSArun Ramadoss 			      struct phylink_config *config);
20b19ac41fSArun Ramadoss void lan937x_setup_rgmii_delay(struct ksz_device *dev, int port);
2155ab6ffaSArun Ramadoss #endif
22