Back to home page

OSCL-LXR

 
 

    


0001 /* SPDX-License-Identifier: GPL-2.0-only */
0002 /****************************************************************************
0003  * Driver for Solarflare network controllers and boards
0004  * Copyright 2007-2010 Solarflare Communications Inc.
0005  */
0006 
0007 #ifndef EF4_PHY_H
0008 #define EF4_PHY_H
0009 
0010 /****************************************************************************
0011  * 10Xpress (SFX7101) PHY
0012  */
0013 extern const struct ef4_phy_operations falcon_sfx7101_phy_ops;
0014 
0015 void tenxpress_set_id_led(struct ef4_nic *efx, enum ef4_led_mode mode);
0016 
0017 /****************************************************************************
0018  * AMCC/Quake QT202x PHYs
0019  */
0020 extern const struct ef4_phy_operations falcon_qt202x_phy_ops;
0021 
0022 /* These PHYs provide various H/W control states for LEDs */
0023 #define QUAKE_LED_LINK_INVAL    (0)
0024 #define QUAKE_LED_LINK_STAT (1)
0025 #define QUAKE_LED_LINK_ACT  (2)
0026 #define QUAKE_LED_LINK_ACTSTAT  (3)
0027 #define QUAKE_LED_OFF       (4)
0028 #define QUAKE_LED_ON        (5)
0029 #define QUAKE_LED_LINK_INPUT    (6) /* Pin is an input. */
0030 /* What link the LED tracks */
0031 #define QUAKE_LED_TXLINK    (0)
0032 #define QUAKE_LED_RXLINK    (8)
0033 
0034 void falcon_qt202x_set_led(struct ef4_nic *p, int led, int state);
0035 
0036 /****************************************************************************
0037 * Transwitch CX4 retimer
0038 */
0039 extern const struct ef4_phy_operations falcon_txc_phy_ops;
0040 
0041 #define TXC_GPIO_DIR_INPUT  0
0042 #define TXC_GPIO_DIR_OUTPUT 1
0043 
0044 void falcon_txc_set_gpio_dir(struct ef4_nic *efx, int pin, int dir);
0045 void falcon_txc_set_gpio_val(struct ef4_nic *efx, int pin, int val);
0046 
0047 #endif