38a39
> /* $FreeBSD: head/sys/dev/oce/oce_mbox.c 257007 2013-10-23 18:58:38Z delphij $ */
40,43d40
<
< /* $FreeBSD: head/sys/dev/oce/oce_mbox.c 252869 2013-07-06 08:30:45Z delphij $ */
<
<
284,285c281,284
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, ret);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, ret,
> fwcmd->hdr.u0.rsp.additional_status);
441,442c440,443
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, ret);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, ret,
> fwcmd->hdr.u0.rsp.additional_status);
484,485c485,488
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, ret);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, ret,
> fwcmd->hdr.u0.rsp.additional_status);
491,495c494,498
< sc->config_number = fwcmd->params.rsp.config_number;
< sc->asic_revision = fwcmd->params.rsp.asic_revision;
< sc->port_id = fwcmd->params.rsp.port_id;
< sc->function_mode = fwcmd->params.rsp.function_mode;
< sc->function_caps = fwcmd->params.rsp.function_caps;
---
> sc->config_number = HOST_32(fwcmd->params.rsp.config_number);
> sc->asic_revision = HOST_32(fwcmd->params.rsp.asic_revision);
> sc->port_id = HOST_32(fwcmd->params.rsp.port_id);
> sc->function_mode = HOST_32(fwcmd->params.rsp.function_mode);
> sc->function_caps = HOST_32(fwcmd->params.rsp.function_caps);
498,499c501,502
< sc->max_tx_rings = fwcmd->params.rsp.ulp[0].nic_wq_tot;
< sc->max_rx_rings = fwcmd->params.rsp.ulp[0].lro_rqid_tot;
---
> sc->max_tx_rings = HOST_32(fwcmd->params.rsp.ulp[0].nic_wq_tot);
> sc->max_rx_rings = HOST_32(fwcmd->params.rsp.ulp[0].lro_rqid_tot);
501,502c504,505
< sc->max_tx_rings = fwcmd->params.rsp.ulp[1].nic_wq_tot;
< sc->max_rx_rings = fwcmd->params.rsp.ulp[1].lro_rqid_tot;
---
> sc->max_tx_rings = HOST_32(fwcmd->params.rsp.ulp[1].nic_wq_tot);
> sc->max_rx_rings = HOST_32(fwcmd->params.rsp.ulp[1].lro_rqid_tot);
564,565c567,570
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
569c574
< *if_id = LE_32(fwcmd->params.rsp.if_id);
---
> *if_id = HOST_32(fwcmd->params.rsp.if_id);
572c577
< sc->pmac_id = LE_32(fwcmd->params.rsp.pmac_id);
---
> sc->pmac_id = HOST_32(fwcmd->params.rsp.pmac_id);
610,611c615,618
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
633c640
< int rc;
---
> int rc = 0;
634a642,644
> if (sc->vlans_added > sc->max_vlans)
> goto vlan_promisc;
>
662,664c672,675
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
< return 0;
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
665a677,685
> goto done;
>
> vlan_promisc:
> /* Enable Vlan Promis */
> oce_rxf_set_promiscuous(sc, (1 << 1));
> device_printf(sc->dev,"Enabling Vlan Promisc Mode\n");
> done:
> return rc;
>
705,706c725,728
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
805,806c827,830
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
821c845
< oce_rxf_set_promiscuous(POCE_SOFTC sc, uint32_t enable)
---
> oce_rxf_set_promiscuous(POCE_SOFTC sc, uint8_t enable)
839,842c863,869
< if (enable) {
< req->iface_flags = MBX_RX_IFACE_FLAGS_PROMISCUOUS |
< MBX_RX_IFACE_FLAGS_VLAN_PROMISCUOUS;
< }
---
> /* Bit 0 Mac promisc, Bit 1 Vlan promisc */
> if (enable & 0x01)
> req->iface_flags = MBX_RX_IFACE_FLAGS_PROMISCUOUS;
>
> if (enable & 0x02)
> req->iface_flags = MBX_RX_IFACE_FLAGS_VLAN_PROMISCUOUS;
>
889,891c916,920
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
< return 0;
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
> return rc;
928,929c957,960
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
934,935c965,966
< link->logical_link_status = LE_32(link->logical_link_status);
< link->qos_link_speed = LE_16(link->qos_link_speed);
---
> link->logical_link_status = HOST_32(link->logical_link_status);
> link->qos_link_speed = HOST_16(link->qos_link_speed);
981,982c1012,1015
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1031,1032c1064,1067
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1083,1084c1118,1121
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1136,1137c1173,1176
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1181,1182c1220,1223
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> req->hdr.u0.rsp.additional_status);
1246,1247c1287,1290
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1284,1285c1327,1330
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1321,1322c1366,1369
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1325c1372
< sc->be3_native = fwcmd->params.rsp.capability_flags
---
> sc->be3_native = HOST_32(fwcmd->params.rsp.capability_flags)
1366,1367c1413,1416
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1409,1410c1458,1461
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1436,1438c1487,1489
< fwcmd->flash_op_type = optype;
< fwcmd->flash_op_code = opcode;
< fwcmd->data_buffer_size = num_bytes;
---
> fwcmd->flash_op_type = LE_32(optype);
> fwcmd->flash_op_code = LE_32(opcode);
> fwcmd->data_buffer_size = LE_32(num_bytes);
1454,1455c1505,1508
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1500,1501c1553,1556
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1535,1536c1590,1593
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1539c1596
< phy_info->phy_type = fwcmd->params.rsp.phy_info.phy_type;
---
> phy_info->phy_type = HOST_16(fwcmd->params.rsp.phy_info.phy_type);
1541c1598
< fwcmd->params.rsp.phy_info.interface_type;
---
> HOST_16(fwcmd->params.rsp.phy_info.interface_type);
1543c1600
< fwcmd->params.rsp.phy_info.auto_speeds_supported;
---
> HOST_16(fwcmd->params.rsp.phy_info.auto_speeds_supported);
1545,1546c1602,1603
< fwcmd->params.rsp.phy_info.fixed_speeds_supported;
< phy_info->misc_params =fwcmd->params.rsp.phy_info.misc_params;
---
> HOST_16(fwcmd->params.rsp.phy_info.fixed_speeds_supported);
> phy_info->misc_params = HOST_32(fwcmd->params.rsp.phy_info.misc_params);
1596,1597c1653,1656
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->params.rsp.additional_status);
1600c1659
< *written_data = fwcmd->params.rsp.actual_write_length;
---
> *written_data = HOST_32(fwcmd->params.rsp.actual_write_length);
1652,1653c1711,1714
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1656c1717
< rq->rq_id = fwcmd->params.rsp.rq_id;
---
> rq->rq_id = HOST_16(fwcmd->params.rsp.rq_id);
1676c1737
< if (IS_XE201(sc)) {
---
> if (IS_XE201(sc))
1678,1679c1739
< fwcmd->params.req.if_id = sc->if_id;
< } else if(IS_BE(sc))
---
> else if(IS_BE(sc))
1684a1745,1747
> if (version > OCE_MBX_VER_V0)
> fwcmd->params.req.if_id = sc->if_id;
>
1706,1707c1769,1772
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1710c1775
< wq->wq_id = LE_16(fwcmd->params.rsp.wq_id);
---
> wq->wq_id = HOST_16(fwcmd->params.rsp.wq_id);
1712c1777
< wq->db_offset = LE_32(fwcmd->params.rsp.db_offset);
---
> wq->db_offset = HOST_32(fwcmd->params.rsp.db_offset);
1757,1758c1822,1825
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1761c1828
< eq->eq_id = LE_16(fwcmd->params.rsp.eq_id);
---
> eq->eq_id = HOST_16(fwcmd->params.rsp.eq_id);
1835,1836c1902,1905
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1839c1908
< cq->cq_id = LE_16(fwcmd->params.rsp.cq_id);
---
> cq->cq_id = HOST_16(fwcmd->params.rsp.cq_id);
1888,1889c1957,1960
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1950,1951c2021,2024
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
2009,2010c2082,2085
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
2029a2105
> sc->max_vlans = nic_desc->vlan_count;
2099,2100c2175,2178
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
2119a2198
> sc->max_vlans = nic_desc->vlan_count;
> /* $FreeBSD: head/sys/dev/oce/oce_mbox.c 257007 2013-10-23 18:58:38Z delphij $ */
40,43d40
<
< /* $FreeBSD: head/sys/dev/oce/oce_mbox.c 252869 2013-07-06 08:30:45Z delphij $ */
<
<
284,285c281,284
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, ret);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, ret,
> fwcmd->hdr.u0.rsp.additional_status);
441,442c440,443
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, ret);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, ret,
> fwcmd->hdr.u0.rsp.additional_status);
484,485c485,488
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, ret);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, ret,
> fwcmd->hdr.u0.rsp.additional_status);
491,495c494,498
< sc->config_number = fwcmd->params.rsp.config_number;
< sc->asic_revision = fwcmd->params.rsp.asic_revision;
< sc->port_id = fwcmd->params.rsp.port_id;
< sc->function_mode = fwcmd->params.rsp.function_mode;
< sc->function_caps = fwcmd->params.rsp.function_caps;
---
> sc->config_number = HOST_32(fwcmd->params.rsp.config_number);
> sc->asic_revision = HOST_32(fwcmd->params.rsp.asic_revision);
> sc->port_id = HOST_32(fwcmd->params.rsp.port_id);
> sc->function_mode = HOST_32(fwcmd->params.rsp.function_mode);
> sc->function_caps = HOST_32(fwcmd->params.rsp.function_caps);
498,499c501,502
< sc->max_tx_rings = fwcmd->params.rsp.ulp[0].nic_wq_tot;
< sc->max_rx_rings = fwcmd->params.rsp.ulp[0].lro_rqid_tot;
---
> sc->max_tx_rings = HOST_32(fwcmd->params.rsp.ulp[0].nic_wq_tot);
> sc->max_rx_rings = HOST_32(fwcmd->params.rsp.ulp[0].lro_rqid_tot);
501,502c504,505
< sc->max_tx_rings = fwcmd->params.rsp.ulp[1].nic_wq_tot;
< sc->max_rx_rings = fwcmd->params.rsp.ulp[1].lro_rqid_tot;
---
> sc->max_tx_rings = HOST_32(fwcmd->params.rsp.ulp[1].nic_wq_tot);
> sc->max_rx_rings = HOST_32(fwcmd->params.rsp.ulp[1].lro_rqid_tot);
564,565c567,570
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
569c574
< *if_id = LE_32(fwcmd->params.rsp.if_id);
---
> *if_id = HOST_32(fwcmd->params.rsp.if_id);
572c577
< sc->pmac_id = LE_32(fwcmd->params.rsp.pmac_id);
---
> sc->pmac_id = HOST_32(fwcmd->params.rsp.pmac_id);
610,611c615,618
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
633c640
< int rc;
---
> int rc = 0;
634a642,644
> if (sc->vlans_added > sc->max_vlans)
> goto vlan_promisc;
>
662,664c672,675
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
< return 0;
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
665a677,685
> goto done;
>
> vlan_promisc:
> /* Enable Vlan Promis */
> oce_rxf_set_promiscuous(sc, (1 << 1));
> device_printf(sc->dev,"Enabling Vlan Promisc Mode\n");
> done:
> return rc;
>
705,706c725,728
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
805,806c827,830
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
821c845
< oce_rxf_set_promiscuous(POCE_SOFTC sc, uint32_t enable)
---
> oce_rxf_set_promiscuous(POCE_SOFTC sc, uint8_t enable)
839,842c863,869
< if (enable) {
< req->iface_flags = MBX_RX_IFACE_FLAGS_PROMISCUOUS |
< MBX_RX_IFACE_FLAGS_VLAN_PROMISCUOUS;
< }
---
> /* Bit 0 Mac promisc, Bit 1 Vlan promisc */
> if (enable & 0x01)
> req->iface_flags = MBX_RX_IFACE_FLAGS_PROMISCUOUS;
>
> if (enable & 0x02)
> req->iface_flags = MBX_RX_IFACE_FLAGS_VLAN_PROMISCUOUS;
>
889,891c916,920
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
< return 0;
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
> return rc;
928,929c957,960
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
934,935c965,966
< link->logical_link_status = LE_32(link->logical_link_status);
< link->qos_link_speed = LE_16(link->qos_link_speed);
---
> link->logical_link_status = HOST_32(link->logical_link_status);
> link->qos_link_speed = HOST_16(link->qos_link_speed);
981,982c1012,1015
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1031,1032c1064,1067
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1083,1084c1118,1121
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1136,1137c1173,1176
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1181,1182c1220,1223
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> req->hdr.u0.rsp.additional_status);
1246,1247c1287,1290
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1284,1285c1327,1330
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1321,1322c1366,1369
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1325c1372
< sc->be3_native = fwcmd->params.rsp.capability_flags
---
> sc->be3_native = HOST_32(fwcmd->params.rsp.capability_flags)
1366,1367c1413,1416
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1409,1410c1458,1461
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1436,1438c1487,1489
< fwcmd->flash_op_type = optype;
< fwcmd->flash_op_code = opcode;
< fwcmd->data_buffer_size = num_bytes;
---
> fwcmd->flash_op_type = LE_32(optype);
> fwcmd->flash_op_code = LE_32(opcode);
> fwcmd->data_buffer_size = LE_32(num_bytes);
1454,1455c1505,1508
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1500,1501c1553,1556
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1535,1536c1590,1593
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1539c1596
< phy_info->phy_type = fwcmd->params.rsp.phy_info.phy_type;
---
> phy_info->phy_type = HOST_16(fwcmd->params.rsp.phy_info.phy_type);
1541c1598
< fwcmd->params.rsp.phy_info.interface_type;
---
> HOST_16(fwcmd->params.rsp.phy_info.interface_type);
1543c1600
< fwcmd->params.rsp.phy_info.auto_speeds_supported;
---
> HOST_16(fwcmd->params.rsp.phy_info.auto_speeds_supported);
1545,1546c1602,1603
< fwcmd->params.rsp.phy_info.fixed_speeds_supported;
< phy_info->misc_params =fwcmd->params.rsp.phy_info.misc_params;
---
> HOST_16(fwcmd->params.rsp.phy_info.fixed_speeds_supported);
> phy_info->misc_params = HOST_32(fwcmd->params.rsp.phy_info.misc_params);
1596,1597c1653,1656
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->params.rsp.additional_status);
1600c1659
< *written_data = fwcmd->params.rsp.actual_write_length;
---
> *written_data = HOST_32(fwcmd->params.rsp.actual_write_length);
1652,1653c1711,1714
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1656c1717
< rq->rq_id = fwcmd->params.rsp.rq_id;
---
> rq->rq_id = HOST_16(fwcmd->params.rsp.rq_id);
1676c1737
< if (IS_XE201(sc)) {
---
> if (IS_XE201(sc))
1678,1679c1739
< fwcmd->params.req.if_id = sc->if_id;
< } else if(IS_BE(sc))
---
> else if(IS_BE(sc))
1684a1745,1747
> if (version > OCE_MBX_VER_V0)
> fwcmd->params.req.if_id = sc->if_id;
>
1706,1707c1769,1772
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1710c1775
< wq->wq_id = LE_16(fwcmd->params.rsp.wq_id);
---
> wq->wq_id = HOST_16(fwcmd->params.rsp.wq_id);
1712c1777
< wq->db_offset = LE_32(fwcmd->params.rsp.db_offset);
---
> wq->db_offset = HOST_32(fwcmd->params.rsp.db_offset);
1757,1758c1822,1825
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1761c1828
< eq->eq_id = LE_16(fwcmd->params.rsp.eq_id);
---
> eq->eq_id = HOST_16(fwcmd->params.rsp.eq_id);
1835,1836c1902,1905
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1839c1908
< cq->cq_id = LE_16(fwcmd->params.rsp.cq_id);
---
> cq->cq_id = HOST_16(fwcmd->params.rsp.cq_id);
1888,1889c1957,1960
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
1950,1951c2021,2024
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
2009,2010c2082,2085
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
2029a2105
> sc->max_vlans = nic_desc->vlan_count;
2099,2100c2175,2178
< device_printf(sc->dev,"%s failed - cmd status: %d\n",
< __FUNCTION__, rc);
---
> device_printf(sc->dev,
> "%s failed - cmd status: %d addi status: %d\n",
> __FUNCTION__, rc,
> fwcmd->hdr.u0.rsp.additional_status);
2119a2198
> sc->max_vlans = nic_desc->vlan_count;