Author: slavash
Date: Wed Dec  5 13:49:11 2018
New Revision: 341571
URL: https://svnweb.freebsd.org/changeset/base/341571

Log:
  mlx5ib: Set default active width and speed when querying port.
  
  Make sure the active width and speed is set in case the
  translate_eth_proto_oper() function doesn't recognize the
  current port operation mask.
  
  Linux commit:
  7672ed33c4c15dbe9d56880683baaba4227cf940
  
  Submitted by:   hselasky@
  Approved by:    hselasky (mentor)
  MFC after:      1 week
  Sponsored by:   Mellanox Technologies

Modified:
  head/sys/dev/mlx5/mlx5_ib/mlx5_ib_main.c

Modified: head/sys/dev/mlx5/mlx5_ib/mlx5_ib_main.c
==============================================================================
--- head/sys/dev/mlx5/mlx5_ib/mlx5_ib_main.c    Wed Dec  5 13:48:39 2018        
(r341570)
+++ head/sys/dev/mlx5/mlx5_ib/mlx5_ib_main.c    Wed Dec  5 13:49:11 2018        
(r341571)
@@ -219,6 +219,8 @@ static int translate_eth_proto_oper(u32 eth_proto_oper
                *active_speed = IB_SPEED_EDR;
                break;
        default:
+               *active_width = IB_WIDTH_4X;
+               *active_speed = IB_SPEED_QDR;
                return -EINVAL;
        }
 
_______________________________________________
[email protected] mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "[email protected]"

Reply via email to