diff --git a/sys/dev/qlxgbe/ql_hw.c b/sys/dev/qlxgbe/ql_hw.c index e2e45bce7b26..8a8494ce5e72 100644 --- a/sys/dev/qlxgbe/ql_hw.c +++ b/sys/dev/qlxgbe/ql_hw.c @@ -2498,6 +2498,9 @@ ql_init_hw_if(qla_host_t *ha) if (qla_hw_add_all_mcast(ha)) return (-1); + if (ql_set_max_mtu(ha, ha->max_frame_size, ha->hw.rcv_cntxt_id)) + return (-1); + if (qla_config_rss(ha, ha->hw.rcv_cntxt_id)) return (-1); diff --git a/sys/dev/qlxgbe/ql_os.c b/sys/dev/qlxgbe/ql_os.c index 5bcc41f3c3e4..b9b53ecd90a1 100644 --- a/sys/dev/qlxgbe/ql_os.c +++ b/sys/dev/qlxgbe/ql_os.c @@ -980,8 +980,7 @@ qla_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data) ifp->if_mtu + ETHER_HDR_LEN + ETHER_CRC_LEN; if ((ifp->if_drv_flags & IFF_DRV_RUNNING)) { - ret = ql_set_max_mtu(ha, ha->max_frame_size, - ha->hw.rcv_cntxt_id); + qla_init_locked(ha); } if (ifp->if_mtu > ETHERMTU) @@ -1014,11 +1013,9 @@ qla_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data) ret = ql_set_allmulti(ha); } } else { - qla_init_locked(ha); ha->max_frame_size = ifp->if_mtu + ETHER_HDR_LEN + ETHER_CRC_LEN; - ret = ql_set_max_mtu(ha, ha->max_frame_size, - ha->hw.rcv_cntxt_id); + qla_init_locked(ha); } } else { if (ifp->if_drv_flags & IFF_DRV_RUNNING)