Lines Matching refs:wrb
397 static inline void *embedded_payload(struct be_mcc_wrb *wrb) in embedded_payload() argument
399 return wrb->payload.embedded_payload; in embedded_payload()
402 static inline struct be_sge *nonembedded_sgl(struct be_mcc_wrb *wrb) in nonembedded_sgl() argument
404 return &wrb->payload.sgl[0]; in nonembedded_sgl()
408 static void be_wrb_hdr_prepare(struct be_mcc_wrb *wrb, int payload_len, in be_wrb_hdr_prepare() argument
412 wrb->embedded |= MCC_WRB_EMBEDDED_MASK; in be_wrb_hdr_prepare()
414 wrb->embedded |= (sge_cnt & MCC_WRB_SGE_CNT_MASK) << in be_wrb_hdr_prepare()
416 wrb->payload_length = payload_len; in be_wrb_hdr_prepare()
417 wrb->tag0 = opcode; in be_wrb_hdr_prepare()
418 be_dws_cpu_to_le(wrb, 8); in be_wrb_hdr_prepare()
472 struct be_mcc_wrb *wrb in wrb_from_mbox() local
473 = &((struct be_mcc_mailbox *)(mbox_mem->va))->wrb; in wrb_from_mbox()
474 memset(wrb, 0, sizeof(*wrb)); in wrb_from_mbox()
475 return wrb; in wrb_from_mbox()
481 struct be_mcc_wrb *wrb; in wrb_from_mccq() local
488 wrb = queue_head_node(mccq); in wrb_from_mccq()
491 memset(wrb, 0, sizeof(*wrb)); in wrb_from_mccq()
492 return wrb; in wrb_from_mccq()
500 u8 *wrb; in be_cmd_fw_init() local
506 wrb = (u8 *)wrb_from_mbox(adapter); in be_cmd_fw_init()
507 *wrb++ = 0xFF; in be_cmd_fw_init()
508 *wrb++ = 0x12; in be_cmd_fw_init()
509 *wrb++ = 0x34; in be_cmd_fw_init()
510 *wrb++ = 0xFF; in be_cmd_fw_init()
511 *wrb++ = 0xFF; in be_cmd_fw_init()
512 *wrb++ = 0x56; in be_cmd_fw_init()
513 *wrb++ = 0x78; in be_cmd_fw_init()
514 *wrb = 0xFF; in be_cmd_fw_init()
527 u8 *wrb; in be_cmd_fw_clean() local
536 wrb = (u8 *)wrb_from_mbox(adapter); in be_cmd_fw_clean()
537 *wrb++ = 0xFF; in be_cmd_fw_clean()
538 *wrb++ = 0xAA; in be_cmd_fw_clean()
539 *wrb++ = 0xBB; in be_cmd_fw_clean()
540 *wrb++ = 0xFF; in be_cmd_fw_clean()
541 *wrb++ = 0xFF; in be_cmd_fw_clean()
542 *wrb++ = 0xCC; in be_cmd_fw_clean()
543 *wrb++ = 0xDD; in be_cmd_fw_clean()
544 *wrb = 0xFF; in be_cmd_fw_clean()
554 struct be_mcc_wrb *wrb; in be_cmd_eq_create() local
562 wrb = wrb_from_mbox(adapter); in be_cmd_eq_create()
563 req = embedded_payload(wrb); in be_cmd_eq_create()
565 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, OPCODE_COMMON_EQ_CREATE); in be_cmd_eq_create()
585 struct be_cmd_resp_eq_create *resp = embedded_payload(wrb); in be_cmd_eq_create()
598 struct be_mcc_wrb *wrb; in be_cmd_mac_addr_query() local
605 wrb = wrb_from_mbox(adapter); in be_cmd_mac_addr_query()
606 req = embedded_payload(wrb); in be_cmd_mac_addr_query()
608 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_mac_addr_query()
624 struct be_cmd_resp_mac_query *resp = embedded_payload(wrb); in be_cmd_mac_addr_query()
636 struct be_mcc_wrb *wrb; in be_cmd_pmac_add() local
642 wrb = wrb_from_mccq(adapter); in be_cmd_pmac_add()
643 if (!wrb) { in be_cmd_pmac_add()
647 req = embedded_payload(wrb); in be_cmd_pmac_add()
649 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_pmac_add()
661 struct be_cmd_resp_pmac_add *resp = embedded_payload(wrb); in be_cmd_pmac_add()
673 struct be_mcc_wrb *wrb; in be_cmd_pmac_del() local
679 wrb = wrb_from_mccq(adapter); in be_cmd_pmac_del()
680 if (!wrb) { in be_cmd_pmac_del()
684 req = embedded_payload(wrb); in be_cmd_pmac_del()
686 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_pmac_del()
708 struct be_mcc_wrb *wrb; in be_cmd_cq_create() local
717 wrb = wrb_from_mbox(adapter); in be_cmd_cq_create()
718 req = embedded_payload(wrb); in be_cmd_cq_create()
721 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_cq_create()
764 struct be_cmd_resp_cq_create *resp = embedded_payload(wrb); in be_cmd_cq_create()
786 struct be_mcc_wrb *wrb; in be_cmd_mccq_create() local
795 wrb = wrb_from_mbox(adapter); in be_cmd_mccq_create()
796 req = embedded_payload(wrb); in be_cmd_mccq_create()
799 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_mccq_create()
833 struct be_cmd_resp_mcc_create *resp = embedded_payload(wrb); in be_cmd_mccq_create()
846 struct be_mcc_wrb *wrb; in be_cmd_txq_create() local
855 wrb = wrb_from_mbox(adapter); in be_cmd_txq_create()
856 req = embedded_payload(wrb); in be_cmd_txq_create()
859 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_txq_create()
886 struct be_cmd_resp_eth_tx_create *resp = embedded_payload(wrb); in be_cmd_txq_create()
901 struct be_mcc_wrb *wrb; in be_cmd_rxq_create() local
909 wrb = wrb_from_mbox(adapter); in be_cmd_rxq_create()
910 req = embedded_payload(wrb); in be_cmd_rxq_create()
912 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_rxq_create()
928 struct be_cmd_resp_eth_rx_create *resp = embedded_payload(wrb); in be_cmd_rxq_create()
945 struct be_mcc_wrb *wrb; in be_cmd_q_destroy() local
956 wrb = wrb_from_mbox(adapter); in be_cmd_q_destroy()
957 req = embedded_payload(wrb); in be_cmd_q_destroy()
984 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, opcode); in be_cmd_q_destroy()
1003 struct be_mcc_wrb *wrb; in be_cmd_if_create() local
1010 wrb = wrb_from_mbox(adapter); in be_cmd_if_create()
1011 req = embedded_payload(wrb); in be_cmd_if_create()
1013 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_if_create()
1028 struct be_cmd_resp_if_create *resp = embedded_payload(wrb); in be_cmd_if_create()
1041 struct be_mcc_wrb *wrb; in be_cmd_if_destroy() local
1051 wrb = wrb_from_mbox(adapter); in be_cmd_if_destroy()
1052 req = embedded_payload(wrb); in be_cmd_if_destroy()
1054 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_if_destroy()
1076 struct be_mcc_wrb *wrb; in be_cmd_get_stats() local
1086 wrb = wrb_from_mccq(adapter); in be_cmd_get_stats()
1087 if (!wrb) { in be_cmd_get_stats()
1092 sge = nonembedded_sgl(wrb); in be_cmd_get_stats()
1094 be_wrb_hdr_prepare(wrb, sizeof(*req), false, 1, in be_cmd_get_stats()
1115 struct be_mcc_wrb *wrb; in be_cmd_link_status_query() local
1121 wrb = wrb_from_mccq(adapter); in be_cmd_link_status_query()
1122 if (!wrb) { in be_cmd_link_status_query()
1126 req = embedded_payload(wrb); in be_cmd_link_status_query()
1130 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_link_status_query()
1138 struct be_cmd_resp_link_status *resp = embedded_payload(wrb); in be_cmd_link_status_query()
1154 struct be_mcc_wrb *wrb; in be_cmd_get_die_temperature() local
1160 wrb = wrb_from_mccq(adapter); in be_cmd_get_die_temperature()
1161 if (!wrb) { in be_cmd_get_die_temperature()
1165 req = embedded_payload(wrb); in be_cmd_get_die_temperature()
1167 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_get_die_temperature()
1176 embedded_payload(wrb); in be_cmd_get_die_temperature()
1192 struct be_mcc_wrb *wrb; in be_cmd_get_fw_ver() local
1199 wrb = wrb_from_mbox(adapter); in be_cmd_get_fw_ver()
1200 req = embedded_payload(wrb); in be_cmd_get_fw_ver()
1202 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_get_fw_ver()
1210 struct be_cmd_resp_get_fw_version *resp = embedded_payload(wrb); in be_cmd_get_fw_ver()
1223 struct be_mcc_wrb *wrb; in be_cmd_modify_eqd() local
1229 wrb = wrb_from_mccq(adapter); in be_cmd_modify_eqd()
1230 if (!wrb) { in be_cmd_modify_eqd()
1234 req = embedded_payload(wrb); in be_cmd_modify_eqd()
1236 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_modify_eqd()
1258 struct be_mcc_wrb *wrb; in be_cmd_vlan_config() local
1264 wrb = wrb_from_mccq(adapter); in be_cmd_vlan_config()
1265 if (!wrb) { in be_cmd_vlan_config()
1269 req = embedded_payload(wrb); in be_cmd_vlan_config()
1271 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_vlan_config()
1298 struct be_mcc_wrb *wrb; in be_cmd_promiscuous_config() local
1304 wrb = wrb_from_mccq(adapter); in be_cmd_promiscuous_config()
1305 if (!wrb) { in be_cmd_promiscuous_config()
1309 req = embedded_payload(wrb); in be_cmd_promiscuous_config()
1311 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, OPCODE_ETH_PROMISCUOUS); in be_cmd_promiscuous_config()
1339 struct be_mcc_wrb *wrb; in be_cmd_multicast_set() local
1346 wrb = wrb_from_mccq(adapter); in be_cmd_multicast_set()
1347 if (!wrb) { in be_cmd_multicast_set()
1351 sge = nonembedded_sgl(wrb); in be_cmd_multicast_set()
1354 be_wrb_hdr_prepare(wrb, sizeof(*req), false, 1, in be_cmd_multicast_set()
1387 struct be_mcc_wrb *wrb; in be_cmd_set_flow_control() local
1393 wrb = wrb_from_mccq(adapter); in be_cmd_set_flow_control()
1394 if (!wrb) { in be_cmd_set_flow_control()
1398 req = embedded_payload(wrb); in be_cmd_set_flow_control()
1400 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_set_flow_control()
1419 struct be_mcc_wrb *wrb; in be_cmd_get_flow_control() local
1425 wrb = wrb_from_mccq(adapter); in be_cmd_get_flow_control()
1426 if (!wrb) { in be_cmd_get_flow_control()
1430 req = embedded_payload(wrb); in be_cmd_get_flow_control()
1432 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_get_flow_control()
1441 embedded_payload(wrb); in be_cmd_get_flow_control()
1455 struct be_mcc_wrb *wrb; in be_cmd_query_fw_cfg() local
1462 wrb = wrb_from_mbox(adapter); in be_cmd_query_fw_cfg()
1463 req = embedded_payload(wrb); in be_cmd_query_fw_cfg()
1465 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_query_fw_cfg()
1473 struct be_cmd_resp_query_fw_cfg *resp = embedded_payload(wrb); in be_cmd_query_fw_cfg()
1486 struct be_mcc_wrb *wrb; in be_cmd_reset_function() local
1493 wrb = wrb_from_mbox(adapter); in be_cmd_reset_function()
1494 req = embedded_payload(wrb); in be_cmd_reset_function()
1496 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_reset_function()
1510 struct be_mcc_wrb *wrb; in be_cmd_rss_config() local
1518 wrb = wrb_from_mbox(adapter); in be_cmd_rss_config()
1519 req = embedded_payload(wrb); in be_cmd_rss_config()
1521 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_rss_config()
1544 struct be_mcc_wrb *wrb; in be_cmd_set_beacon_state() local
1550 wrb = wrb_from_mccq(adapter); in be_cmd_set_beacon_state()
1551 if (!wrb) { in be_cmd_set_beacon_state()
1555 req = embedded_payload(wrb); in be_cmd_set_beacon_state()
1557 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_set_beacon_state()
1578 struct be_mcc_wrb *wrb; in be_cmd_get_beacon_state() local
1584 wrb = wrb_from_mccq(adapter); in be_cmd_get_beacon_state()
1585 if (!wrb) { in be_cmd_get_beacon_state()
1589 req = embedded_payload(wrb); in be_cmd_get_beacon_state()
1591 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_get_beacon_state()
1602 embedded_payload(wrb); in be_cmd_get_beacon_state()
1614 struct be_mcc_wrb *wrb; in be_cmd_write_flashrom() local
1622 wrb = wrb_from_mccq(adapter); in be_cmd_write_flashrom()
1623 if (!wrb) { in be_cmd_write_flashrom()
1628 sge = nonembedded_sgl(wrb); in be_cmd_write_flashrom()
1630 be_wrb_hdr_prepare(wrb, cmd->size, false, 1, in be_cmd_write_flashrom()
1632 wrb->tag1 = CMD_SUBSYSTEM_COMMON; in be_cmd_write_flashrom()
1663 struct be_mcc_wrb *wrb; in be_cmd_get_flash_crc() local
1669 wrb = wrb_from_mccq(adapter); in be_cmd_get_flash_crc()
1670 if (!wrb) { in be_cmd_get_flash_crc()
1674 req = embedded_payload(wrb); in be_cmd_get_flash_crc()
1676 be_wrb_hdr_prepare(wrb, sizeof(*req)+4, true, 0, in be_cmd_get_flash_crc()
1699 struct be_mcc_wrb *wrb; in be_cmd_enable_magic_wol() local
1706 wrb = wrb_from_mccq(adapter); in be_cmd_enable_magic_wol()
1707 if (!wrb) { in be_cmd_enable_magic_wol()
1712 sge = nonembedded_sgl(wrb); in be_cmd_enable_magic_wol()
1714 be_wrb_hdr_prepare(wrb, sizeof(*req), false, 1, in be_cmd_enable_magic_wol()
1735 struct be_mcc_wrb *wrb; in be_cmd_set_loopback() local
1741 wrb = wrb_from_mccq(adapter); in be_cmd_set_loopback()
1742 if (!wrb) { in be_cmd_set_loopback()
1747 req = embedded_payload(wrb); in be_cmd_set_loopback()
1749 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_set_loopback()
1770 struct be_mcc_wrb *wrb; in be_cmd_loopback_test() local
1776 wrb = wrb_from_mccq(adapter); in be_cmd_loopback_test()
1777 if (!wrb) { in be_cmd_loopback_test()
1782 req = embedded_payload(wrb); in be_cmd_loopback_test()
1784 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_loopback_test()
1800 struct be_cmd_resp_loopback_test *resp = embedded_payload(wrb); in be_cmd_loopback_test()
1812 struct be_mcc_wrb *wrb; in be_cmd_ddr_dma_test() local
1820 wrb = wrb_from_mccq(adapter); in be_cmd_ddr_dma_test()
1821 if (!wrb) { in be_cmd_ddr_dma_test()
1826 sge = nonembedded_sgl(wrb); in be_cmd_ddr_dma_test()
1827 be_wrb_hdr_prepare(wrb, cmd->size, false, 1, in be_cmd_ddr_dma_test()
1864 struct be_mcc_wrb *wrb; in be_cmd_get_seeprom_data() local
1871 wrb = wrb_from_mccq(adapter); in be_cmd_get_seeprom_data()
1872 if (!wrb) { in be_cmd_get_seeprom_data()
1877 sge = nonembedded_sgl(wrb); in be_cmd_get_seeprom_data()
1879 be_wrb_hdr_prepare(wrb, sizeof(*req), false, 1, in be_cmd_get_seeprom_data()
1898 struct be_mcc_wrb *wrb; in be_cmd_get_phy_info() local
1905 wrb = wrb_from_mccq(adapter); in be_cmd_get_phy_info()
1906 if (!wrb) { in be_cmd_get_phy_info()
1912 sge = nonembedded_sgl(wrb); in be_cmd_get_phy_info()
1914 be_wrb_hdr_prepare(wrb, sizeof(*req), false, 1, in be_cmd_get_phy_info()
1933 struct be_mcc_wrb *wrb; in be_cmd_set_qos() local
1939 wrb = wrb_from_mccq(adapter); in be_cmd_set_qos()
1940 if (!wrb) { in be_cmd_set_qos()
1945 req = embedded_payload(wrb); in be_cmd_set_qos()
1947 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_set_qos()
1966 struct be_mcc_wrb *wrb; in be_cmd_get_cntl_attributes() local
1988 wrb = wrb_from_mbox(adapter); in be_cmd_get_cntl_attributes()
1989 if (!wrb) { in be_cmd_get_cntl_attributes()
1994 sge = nonembedded_sgl(wrb); in be_cmd_get_cntl_attributes()
1996 be_wrb_hdr_prepare(wrb, payload_len, false, 1, in be_cmd_get_cntl_attributes()
2021 struct be_mcc_wrb *wrb; in be_cmd_check_native_mode() local
2028 wrb = wrb_from_mbox(adapter); in be_cmd_check_native_mode()
2029 if (!wrb) { in be_cmd_check_native_mode()
2034 req = embedded_payload(wrb); in be_cmd_check_native_mode()
2036 be_wrb_hdr_prepare(wrb, sizeof(*req), true, 0, in be_cmd_check_native_mode()
2048 struct be_cmd_resp_set_func_cap *resp = embedded_payload(wrb); in be_cmd_check_native_mode()