mirror of
https://github.com/edk2-porting/linux-next.git
synced 2025-01-09 14:14:00 +08:00
cxgb4: Decode the firmware port and module type a bit more for ethtool
Signed-off-by: Hariprasad Shenai <hariprasad@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
163cd4e817
commit
3e00a50935
@ -2252,12 +2252,19 @@ static int get_settings(struct net_device *dev, struct ethtool_cmd *cmd)
|
||||
else if (p->port_type == FW_PORT_TYPE_FIBER_XFI ||
|
||||
p->port_type == FW_PORT_TYPE_FIBER_XAUI)
|
||||
cmd->port = PORT_FIBRE;
|
||||
else if (p->port_type == FW_PORT_TYPE_SFP) {
|
||||
if (p->mod_type == FW_PORT_MOD_TYPE_TWINAX_PASSIVE ||
|
||||
p->mod_type == FW_PORT_MOD_TYPE_TWINAX_ACTIVE)
|
||||
else if (p->port_type == FW_PORT_TYPE_SFP ||
|
||||
p->port_type == FW_PORT_TYPE_QSFP_10G ||
|
||||
p->port_type == FW_PORT_TYPE_QSFP) {
|
||||
if (p->mod_type == FW_PORT_MOD_TYPE_LR ||
|
||||
p->mod_type == FW_PORT_MOD_TYPE_SR ||
|
||||
p->mod_type == FW_PORT_MOD_TYPE_ER ||
|
||||
p->mod_type == FW_PORT_MOD_TYPE_LRM)
|
||||
cmd->port = PORT_FIBRE;
|
||||
else if (p->mod_type == FW_PORT_MOD_TYPE_TWINAX_PASSIVE ||
|
||||
p->mod_type == FW_PORT_MOD_TYPE_TWINAX_ACTIVE)
|
||||
cmd->port = PORT_DA;
|
||||
else
|
||||
cmd->port = PORT_FIBRE;
|
||||
cmd->port = PORT_OTHER;
|
||||
} else
|
||||
cmd->port = PORT_OTHER;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user