| .. | .. |
|---|
| 11 | 11 | */ |
|---|
| 12 | 12 | |
|---|
| 13 | 13 | #define I40E_FW_API_VERSION_MAJOR 0x0001 |
|---|
| 14 | | -#define I40E_FW_API_VERSION_MINOR_X722 0x0005 |
|---|
| 15 | | -#define I40E_FW_API_VERSION_MINOR_X710 0x0007 |
|---|
| 14 | +#define I40E_FW_API_VERSION_MINOR_X722 0x0009 |
|---|
| 15 | +#define I40E_FW_API_VERSION_MINOR_X710 0x0009 |
|---|
| 16 | 16 | |
|---|
| 17 | 17 | #define I40E_FW_MINOR_VERSION(_h) ((_h)->mac.type == I40E_MAC_XL710 ? \ |
|---|
| 18 | 18 | I40E_FW_API_VERSION_MINOR_X710 : \ |
|---|
| .. | .. |
|---|
| 20 | 20 | |
|---|
| 21 | 21 | /* API version 1.7 implements additional link and PHY-specific APIs */ |
|---|
| 22 | 22 | #define I40E_MINOR_VER_GET_LINK_INFO_XL710 0x0007 |
|---|
| 23 | +/* API version 1.9 for X722 implements additional link and PHY-specific APIs */ |
|---|
| 24 | +#define I40E_MINOR_VER_GET_LINK_INFO_X722 0x0009 |
|---|
| 25 | +/* API version 1.6 for X722 devices adds ability to stop FW LLDP agent */ |
|---|
| 26 | +#define I40E_MINOR_VER_FW_LLDP_STOPPABLE_X722 0x0006 |
|---|
| 27 | +/* API version 1.10 for X722 devices adds ability to request FEC encoding */ |
|---|
| 28 | +#define I40E_MINOR_VER_FW_REQUEST_FEC_X722 0x000A |
|---|
| 23 | 29 | |
|---|
| 24 | 30 | struct i40e_aq_desc { |
|---|
| 25 | 31 | __le16 flags; |
|---|
| .. | .. |
|---|
| 51 | 57 | */ |
|---|
| 52 | 58 | |
|---|
| 53 | 59 | /* command flags and offsets*/ |
|---|
| 54 | | -#define I40E_AQ_FLAG_DD_SHIFT 0 |
|---|
| 55 | | -#define I40E_AQ_FLAG_CMP_SHIFT 1 |
|---|
| 56 | 60 | #define I40E_AQ_FLAG_ERR_SHIFT 2 |
|---|
| 57 | | -#define I40E_AQ_FLAG_VFE_SHIFT 3 |
|---|
| 58 | 61 | #define I40E_AQ_FLAG_LB_SHIFT 9 |
|---|
| 59 | 62 | #define I40E_AQ_FLAG_RD_SHIFT 10 |
|---|
| 60 | | -#define I40E_AQ_FLAG_VFC_SHIFT 11 |
|---|
| 61 | 63 | #define I40E_AQ_FLAG_BUF_SHIFT 12 |
|---|
| 62 | 64 | #define I40E_AQ_FLAG_SI_SHIFT 13 |
|---|
| 63 | | -#define I40E_AQ_FLAG_EI_SHIFT 14 |
|---|
| 64 | | -#define I40E_AQ_FLAG_FE_SHIFT 15 |
|---|
| 65 | 65 | |
|---|
| 66 | | -#define I40E_AQ_FLAG_DD BIT(I40E_AQ_FLAG_DD_SHIFT) /* 0x1 */ |
|---|
| 67 | | -#define I40E_AQ_FLAG_CMP BIT(I40E_AQ_FLAG_CMP_SHIFT) /* 0x2 */ |
|---|
| 68 | 66 | #define I40E_AQ_FLAG_ERR BIT(I40E_AQ_FLAG_ERR_SHIFT) /* 0x4 */ |
|---|
| 69 | | -#define I40E_AQ_FLAG_VFE BIT(I40E_AQ_FLAG_VFE_SHIFT) /* 0x8 */ |
|---|
| 70 | 67 | #define I40E_AQ_FLAG_LB BIT(I40E_AQ_FLAG_LB_SHIFT) /* 0x200 */ |
|---|
| 71 | 68 | #define I40E_AQ_FLAG_RD BIT(I40E_AQ_FLAG_RD_SHIFT) /* 0x400 */ |
|---|
| 72 | | -#define I40E_AQ_FLAG_VFC BIT(I40E_AQ_FLAG_VFC_SHIFT) /* 0x800 */ |
|---|
| 73 | 69 | #define I40E_AQ_FLAG_BUF BIT(I40E_AQ_FLAG_BUF_SHIFT) /* 0x1000 */ |
|---|
| 74 | 70 | #define I40E_AQ_FLAG_SI BIT(I40E_AQ_FLAG_SI_SHIFT) /* 0x2000 */ |
|---|
| 75 | | -#define I40E_AQ_FLAG_EI BIT(I40E_AQ_FLAG_EI_SHIFT) /* 0x4000 */ |
|---|
| 76 | | -#define I40E_AQ_FLAG_FE BIT(I40E_AQ_FLAG_FE_SHIFT) /* 0x8000 */ |
|---|
| 77 | 71 | |
|---|
| 78 | 72 | /* error codes */ |
|---|
| 79 | 73 | enum i40e_admin_queue_err { |
|---|
| .. | .. |
|---|
| 259 | 253 | i40e_aqc_opc_get_cee_dcb_cfg = 0x0A07, |
|---|
| 260 | 254 | i40e_aqc_opc_lldp_set_local_mib = 0x0A08, |
|---|
| 261 | 255 | i40e_aqc_opc_lldp_stop_start_spec_agent = 0x0A09, |
|---|
| 256 | + i40e_aqc_opc_lldp_restore = 0x0A0A, |
|---|
| 262 | 257 | |
|---|
| 263 | 258 | /* Tunnel commands */ |
|---|
| 264 | 259 | i40e_aqc_opc_add_udp_tunnel = 0x0B00, |
|---|
| .. | .. |
|---|
| 357 | 352 | /* Request resource ownership (direct 0x0008) |
|---|
| 358 | 353 | * Release resource ownership (direct 0x0009) |
|---|
| 359 | 354 | */ |
|---|
| 360 | | -#define I40E_AQ_RESOURCE_NVM 1 |
|---|
| 361 | | -#define I40E_AQ_RESOURCE_SDP 2 |
|---|
| 362 | | -#define I40E_AQ_RESOURCE_ACCESS_READ 1 |
|---|
| 363 | | -#define I40E_AQ_RESOURCE_ACCESS_WRITE 2 |
|---|
| 364 | | -#define I40E_AQ_RESOURCE_NVM_READ_TIMEOUT 3000 |
|---|
| 365 | | -#define I40E_AQ_RESOURCE_NVM_WRITE_TIMEOUT 180000 |
|---|
| 366 | | - |
|---|
| 367 | 355 | struct i40e_aqc_request_resource { |
|---|
| 368 | 356 | __le16 resource_id; |
|---|
| 369 | 357 | __le16 access_type; |
|---|
| .. | .. |
|---|
| 379 | 367 | */ |
|---|
| 380 | 368 | struct i40e_aqc_list_capabilites { |
|---|
| 381 | 369 | u8 command_flags; |
|---|
| 382 | | -#define I40E_AQ_LIST_CAP_PF_INDEX_EN 1 |
|---|
| 383 | 370 | u8 pf_index; |
|---|
| 384 | 371 | u8 reserved[2]; |
|---|
| 385 | 372 | __le32 count; |
|---|
| .. | .. |
|---|
| 406 | 393 | #define I40E_AQ_CAP_ID_NPAR_ACTIVE 0x0003 |
|---|
| 407 | 394 | #define I40E_AQ_CAP_ID_OS2BMC_CAP 0x0004 |
|---|
| 408 | 395 | #define I40E_AQ_CAP_ID_FUNCTIONS_VALID 0x0005 |
|---|
| 409 | | -#define I40E_AQ_CAP_ID_ALTERNATE_RAM 0x0006 |
|---|
| 410 | | -#define I40E_AQ_CAP_ID_WOL_AND_PROXY 0x0008 |
|---|
| 411 | 396 | #define I40E_AQ_CAP_ID_SRIOV 0x0012 |
|---|
| 412 | 397 | #define I40E_AQ_CAP_ID_VF 0x0013 |
|---|
| 413 | 398 | #define I40E_AQ_CAP_ID_VMDQ 0x0014 |
|---|
| .. | .. |
|---|
| 436 | 421 | /* Set CPPM Configuration (direct 0x0103) */ |
|---|
| 437 | 422 | struct i40e_aqc_cppm_configuration { |
|---|
| 438 | 423 | __le16 command_flags; |
|---|
| 439 | | -#define I40E_AQ_CPPM_EN_LTRC 0x0800 |
|---|
| 440 | | -#define I40E_AQ_CPPM_EN_DMCTH 0x1000 |
|---|
| 441 | | -#define I40E_AQ_CPPM_EN_DMCTLX 0x2000 |
|---|
| 442 | | -#define I40E_AQ_CPPM_EN_HPTC 0x4000 |
|---|
| 443 | | -#define I40E_AQ_CPPM_EN_DMARC 0x8000 |
|---|
| 444 | 424 | __le16 ttlx; |
|---|
| 445 | 425 | __le32 dmacr; |
|---|
| 446 | 426 | __le16 dmcth; |
|---|
| .. | .. |
|---|
| 454 | 434 | /* Set ARP Proxy command / response (indirect 0x0104) */ |
|---|
| 455 | 435 | struct i40e_aqc_arp_proxy_data { |
|---|
| 456 | 436 | __le16 command_flags; |
|---|
| 457 | | -#define I40E_AQ_ARP_INIT_IPV4 0x0800 |
|---|
| 458 | | -#define I40E_AQ_ARP_UNSUP_CTL 0x1000 |
|---|
| 459 | | -#define I40E_AQ_ARP_ENA 0x2000 |
|---|
| 460 | | -#define I40E_AQ_ARP_ADD_IPV4 0x4000 |
|---|
| 461 | | -#define I40E_AQ_ARP_DEL_IPV4 0x8000 |
|---|
| 462 | 437 | __le16 table_id; |
|---|
| 463 | 438 | __le32 enabled_offloads; |
|---|
| 464 | | -#define I40E_AQ_ARP_DIRECTED_OFFLOAD_ENABLE 0x00000020 |
|---|
| 465 | | -#define I40E_AQ_ARP_OFFLOAD_ENABLE 0x00000800 |
|---|
| 466 | 439 | __le32 ip_addr; |
|---|
| 467 | 440 | u8 mac_addr[6]; |
|---|
| 468 | 441 | u8 reserved[2]; |
|---|
| .. | .. |
|---|
| 477 | 450 | __le16 table_idx_ipv6_0; |
|---|
| 478 | 451 | __le16 table_idx_ipv6_1; |
|---|
| 479 | 452 | __le16 control; |
|---|
| 480 | | -#define I40E_AQ_NS_PROXY_ADD_0 0x0001 |
|---|
| 481 | | -#define I40E_AQ_NS_PROXY_DEL_0 0x0002 |
|---|
| 482 | | -#define I40E_AQ_NS_PROXY_ADD_1 0x0004 |
|---|
| 483 | | -#define I40E_AQ_NS_PROXY_DEL_1 0x0008 |
|---|
| 484 | | -#define I40E_AQ_NS_PROXY_ADD_IPV6_0 0x0010 |
|---|
| 485 | | -#define I40E_AQ_NS_PROXY_DEL_IPV6_0 0x0020 |
|---|
| 486 | | -#define I40E_AQ_NS_PROXY_ADD_IPV6_1 0x0040 |
|---|
| 487 | | -#define I40E_AQ_NS_PROXY_DEL_IPV6_1 0x0080 |
|---|
| 488 | | -#define I40E_AQ_NS_PROXY_COMMAND_SEQ 0x0100 |
|---|
| 489 | | -#define I40E_AQ_NS_PROXY_INIT_IPV6_TBL 0x0200 |
|---|
| 490 | | -#define I40E_AQ_NS_PROXY_INIT_MAC_TBL 0x0400 |
|---|
| 491 | | -#define I40E_AQ_NS_PROXY_OFFLOAD_ENABLE 0x0800 |
|---|
| 492 | | -#define I40E_AQ_NS_PROXY_DIRECTED_OFFLOAD_ENABLE 0x1000 |
|---|
| 493 | 453 | u8 mac_addr_0[6]; |
|---|
| 494 | 454 | u8 mac_addr_1[6]; |
|---|
| 495 | 455 | u8 local_mac_addr[6]; |
|---|
| .. | .. |
|---|
| 502 | 462 | /* Manage LAA Command (0x0106) - obsolete */ |
|---|
| 503 | 463 | struct i40e_aqc_mng_laa { |
|---|
| 504 | 464 | __le16 command_flags; |
|---|
| 505 | | -#define I40E_AQ_LAA_FLAG_WR 0x8000 |
|---|
| 506 | 465 | u8 reserved[2]; |
|---|
| 507 | 466 | __le32 sal; |
|---|
| 508 | 467 | __le16 sah; |
|---|
| .. | .. |
|---|
| 515 | 474 | struct i40e_aqc_mac_address_read { |
|---|
| 516 | 475 | __le16 command_flags; |
|---|
| 517 | 476 | #define I40E_AQC_LAN_ADDR_VALID 0x10 |
|---|
| 518 | | -#define I40E_AQC_SAN_ADDR_VALID 0x20 |
|---|
| 519 | 477 | #define I40E_AQC_PORT_ADDR_VALID 0x40 |
|---|
| 520 | | -#define I40E_AQC_WOL_ADDR_VALID 0x80 |
|---|
| 521 | | -#define I40E_AQC_MC_MAG_EN_VALID 0x100 |
|---|
| 522 | | -#define I40E_AQC_ADDR_VALID_MASK 0x3F0 |
|---|
| 523 | 478 | u8 reserved[6]; |
|---|
| 524 | 479 | __le32 addr_high; |
|---|
| 525 | 480 | __le32 addr_low; |
|---|
| .. | .. |
|---|
| 543 | 498 | #define I40E_AQC_WOL_PRESERVE_ON_PFR 0x0200 |
|---|
| 544 | 499 | #define I40E_AQC_WRITE_TYPE_LAA_ONLY 0x0000 |
|---|
| 545 | 500 | #define I40E_AQC_WRITE_TYPE_LAA_WOL 0x4000 |
|---|
| 546 | | -#define I40E_AQC_WRITE_TYPE_PORT 0x8000 |
|---|
| 547 | 501 | #define I40E_AQC_WRITE_TYPE_UPDATE_MC_MAG 0xC000 |
|---|
| 548 | | -#define I40E_AQC_WRITE_TYPE_MASK 0xC000 |
|---|
| 549 | 502 | |
|---|
| 550 | 503 | __le16 mac_sah; |
|---|
| 551 | 504 | __le32 mac_sal; |
|---|
| .. | .. |
|---|
| 568 | 521 | |
|---|
| 569 | 522 | struct i40e_aqc_set_wol_filter { |
|---|
| 570 | 523 | __le16 filter_index; |
|---|
| 571 | | -#define I40E_AQC_MAX_NUM_WOL_FILTERS 8 |
|---|
| 572 | | -#define I40E_AQC_SET_WOL_FILTER_TYPE_MAGIC_SHIFT 15 |
|---|
| 573 | | -#define I40E_AQC_SET_WOL_FILTER_TYPE_MAGIC_MASK (0x1 << \ |
|---|
| 574 | | - I40E_AQC_SET_WOL_FILTER_TYPE_MAGIC_SHIFT) |
|---|
| 575 | 524 | |
|---|
| 576 | | -#define I40E_AQC_SET_WOL_FILTER_INDEX_SHIFT 0 |
|---|
| 577 | | -#define I40E_AQC_SET_WOL_FILTER_INDEX_MASK (0x7 << \ |
|---|
| 578 | | - I40E_AQC_SET_WOL_FILTER_INDEX_SHIFT) |
|---|
| 579 | 525 | __le16 cmd_flags; |
|---|
| 580 | | -#define I40E_AQC_SET_WOL_FILTER 0x8000 |
|---|
| 581 | | -#define I40E_AQC_SET_WOL_FILTER_NO_TCO_WOL 0x4000 |
|---|
| 582 | | -#define I40E_AQC_SET_WOL_FILTER_ACTION_CLEAR 0 |
|---|
| 583 | | -#define I40E_AQC_SET_WOL_FILTER_ACTION_SET 1 |
|---|
| 584 | 526 | __le16 valid_flags; |
|---|
| 585 | | -#define I40E_AQC_SET_WOL_FILTER_ACTION_VALID 0x8000 |
|---|
| 586 | | -#define I40E_AQC_SET_WOL_FILTER_NO_TCO_ACTION_VALID 0x4000 |
|---|
| 587 | 527 | u8 reserved[2]; |
|---|
| 588 | 528 | __le32 address_high; |
|---|
| 589 | 529 | __le32 address_low; |
|---|
| .. | .. |
|---|
| 603 | 543 | struct i40e_aqc_get_wake_reason_completion { |
|---|
| 604 | 544 | u8 reserved_1[2]; |
|---|
| 605 | 545 | __le16 wake_reason; |
|---|
| 606 | | -#define I40E_AQC_GET_WAKE_UP_REASON_WOL_REASON_MATCHED_INDEX_SHIFT 0 |
|---|
| 607 | | -#define I40E_AQC_GET_WAKE_UP_REASON_WOL_REASON_MATCHED_INDEX_MASK (0xFF << \ |
|---|
| 608 | | - I40E_AQC_GET_WAKE_UP_REASON_WOL_REASON_MATCHED_INDEX_SHIFT) |
|---|
| 609 | | -#define I40E_AQC_GET_WAKE_UP_REASON_WOL_REASON_RESERVED_SHIFT 8 |
|---|
| 610 | | -#define I40E_AQC_GET_WAKE_UP_REASON_WOL_REASON_RESERVED_MASK (0xFF << \ |
|---|
| 611 | | - I40E_AQC_GET_WAKE_UP_REASON_WOL_REASON_RESERVED_SHIFT) |
|---|
| 612 | 546 | u8 reserved_2[12]; |
|---|
| 613 | 547 | }; |
|---|
| 614 | 548 | |
|---|
| .. | .. |
|---|
| 641 | 575 | |
|---|
| 642 | 576 | struct i40e_aqc_switch_config_element_resp { |
|---|
| 643 | 577 | u8 element_type; |
|---|
| 644 | | -#define I40E_AQ_SW_ELEM_TYPE_MAC 1 |
|---|
| 645 | | -#define I40E_AQ_SW_ELEM_TYPE_PF 2 |
|---|
| 646 | | -#define I40E_AQ_SW_ELEM_TYPE_VF 3 |
|---|
| 647 | | -#define I40E_AQ_SW_ELEM_TYPE_EMP 4 |
|---|
| 648 | | -#define I40E_AQ_SW_ELEM_TYPE_BMC 5 |
|---|
| 649 | | -#define I40E_AQ_SW_ELEM_TYPE_PV 16 |
|---|
| 650 | | -#define I40E_AQ_SW_ELEM_TYPE_VEB 17 |
|---|
| 651 | | -#define I40E_AQ_SW_ELEM_TYPE_PA 18 |
|---|
| 652 | | -#define I40E_AQ_SW_ELEM_TYPE_VSI 19 |
|---|
| 653 | 578 | u8 revision; |
|---|
| 654 | | -#define I40E_AQ_SW_ELEM_REV_1 1 |
|---|
| 655 | 579 | __le16 seid; |
|---|
| 656 | 580 | __le16 uplink_seid; |
|---|
| 657 | 581 | __le16 downlink_seid; |
|---|
| 658 | 582 | u8 reserved[3]; |
|---|
| 659 | 583 | u8 connection_type; |
|---|
| 660 | | -#define I40E_AQ_CONN_TYPE_REGULAR 0x1 |
|---|
| 661 | | -#define I40E_AQ_CONN_TYPE_DEFAULT 0x2 |
|---|
| 662 | | -#define I40E_AQ_CONN_TYPE_CASCADED 0x3 |
|---|
| 663 | 584 | __le16 scheduler_id; |
|---|
| 664 | 585 | __le16 element_info; |
|---|
| 665 | 586 | }; |
|---|
| .. | .. |
|---|
| 692 | 613 | /* Set Port Parameters command (direct 0x0203) */ |
|---|
| 693 | 614 | struct i40e_aqc_set_port_parameters { |
|---|
| 694 | 615 | __le16 command_flags; |
|---|
| 695 | | -#define I40E_AQ_SET_P_PARAMS_SAVE_BAD_PACKETS 1 |
|---|
| 696 | | -#define I40E_AQ_SET_P_PARAMS_PAD_SHORT_PACKETS 2 /* must set! */ |
|---|
| 697 | | -#define I40E_AQ_SET_P_PARAMS_DOUBLE_VLAN_ENA 4 |
|---|
| 698 | 616 | __le16 bad_frame_vsi; |
|---|
| 699 | | -#define I40E_AQ_SET_P_PARAMS_BFRAME_SEID_SHIFT 0x0 |
|---|
| 700 | | -#define I40E_AQ_SET_P_PARAMS_BFRAME_SEID_MASK 0x3FF |
|---|
| 701 | 617 | __le16 default_seid; /* reserved for command */ |
|---|
| 702 | 618 | u8 reserved[10]; |
|---|
| 703 | 619 | }; |
|---|
| .. | .. |
|---|
| 717 | 633 | /* expect an array of these structs in the response buffer */ |
|---|
| 718 | 634 | struct i40e_aqc_switch_resource_alloc_element_resp { |
|---|
| 719 | 635 | u8 resource_type; |
|---|
| 720 | | -#define I40E_AQ_RESOURCE_TYPE_VEB 0x0 |
|---|
| 721 | | -#define I40E_AQ_RESOURCE_TYPE_VSI 0x1 |
|---|
| 722 | | -#define I40E_AQ_RESOURCE_TYPE_MACADDR 0x2 |
|---|
| 723 | | -#define I40E_AQ_RESOURCE_TYPE_STAG 0x3 |
|---|
| 724 | | -#define I40E_AQ_RESOURCE_TYPE_ETAG 0x4 |
|---|
| 725 | | -#define I40E_AQ_RESOURCE_TYPE_MULTICAST_HASH 0x5 |
|---|
| 726 | | -#define I40E_AQ_RESOURCE_TYPE_UNICAST_HASH 0x6 |
|---|
| 727 | | -#define I40E_AQ_RESOURCE_TYPE_VLAN 0x7 |
|---|
| 728 | | -#define I40E_AQ_RESOURCE_TYPE_VSI_LIST_ENTRY 0x8 |
|---|
| 729 | | -#define I40E_AQ_RESOURCE_TYPE_ETAG_LIST_ENTRY 0x9 |
|---|
| 730 | | -#define I40E_AQ_RESOURCE_TYPE_VLAN_STAT_POOL 0xA |
|---|
| 731 | | -#define I40E_AQ_RESOURCE_TYPE_MIRROR_RULE 0xB |
|---|
| 732 | | -#define I40E_AQ_RESOURCE_TYPE_QUEUE_SETS 0xC |
|---|
| 733 | | -#define I40E_AQ_RESOURCE_TYPE_VLAN_FILTERS 0xD |
|---|
| 734 | | -#define I40E_AQ_RESOURCE_TYPE_INNER_MAC_FILTERS 0xF |
|---|
| 735 | | -#define I40E_AQ_RESOURCE_TYPE_IP_FILTERS 0x10 |
|---|
| 736 | | -#define I40E_AQ_RESOURCE_TYPE_GRE_VN_KEYS 0x11 |
|---|
| 737 | | -#define I40E_AQ_RESOURCE_TYPE_VN2_KEYS 0x12 |
|---|
| 738 | | -#define I40E_AQ_RESOURCE_TYPE_TUNNEL_PORTS 0x13 |
|---|
| 739 | 636 | u8 reserved1; |
|---|
| 740 | 637 | __le16 guaranteed; |
|---|
| 741 | 638 | __le16 total; |
|---|
| .. | .. |
|---|
| 751 | 648 | __le16 flags; |
|---|
| 752 | 649 | /* flags used for both fields below */ |
|---|
| 753 | 650 | #define I40E_AQ_SET_SWITCH_CFG_PROMISC 0x0001 |
|---|
| 754 | | -#define I40E_AQ_SET_SWITCH_CFG_L2_FILTER 0x0002 |
|---|
| 755 | 651 | __le16 valid_flags; |
|---|
| 756 | 652 | /* The ethertype in switch_tag is dropped on ingress and used |
|---|
| 757 | 653 | * internally by the switch. Set this to zero for the default |
|---|
| .. | .. |
|---|
| 784 | 680 | */ |
|---|
| 785 | 681 | #define I40E_AQ_SET_SWITCH_BIT7_VALID 0x80 |
|---|
| 786 | 682 | |
|---|
| 787 | | -#define I40E_AQ_SET_SWITCH_L4_SRC_PORT 0x40 |
|---|
| 788 | 683 | |
|---|
| 789 | | -#define I40E_AQ_SET_SWITCH_L4_TYPE_RSVD 0x00 |
|---|
| 790 | 684 | #define I40E_AQ_SET_SWITCH_L4_TYPE_TCP 0x10 |
|---|
| 791 | | -#define I40E_AQ_SET_SWITCH_L4_TYPE_UDP 0x20 |
|---|
| 792 | | -#define I40E_AQ_SET_SWITCH_L4_TYPE_BOTH 0x30 |
|---|
| 793 | 685 | |
|---|
| 794 | | -#define I40E_AQ_SET_SWITCH_MODE_DEFAULT 0x00 |
|---|
| 795 | | -#define I40E_AQ_SET_SWITCH_MODE_L4_PORT 0x01 |
|---|
| 796 | 686 | #define I40E_AQ_SET_SWITCH_MODE_NON_TUNNEL 0x02 |
|---|
| 797 | | -#define I40E_AQ_SET_SWITCH_MODE_TUNNEL 0x03 |
|---|
| 798 | 687 | u8 mode; |
|---|
| 799 | 688 | u8 rsvd5[5]; |
|---|
| 800 | 689 | }; |
|---|
| .. | .. |
|---|
| 829 | 718 | __le16 uplink_seid; |
|---|
| 830 | 719 | u8 connection_type; |
|---|
| 831 | 720 | #define I40E_AQ_VSI_CONN_TYPE_NORMAL 0x1 |
|---|
| 832 | | -#define I40E_AQ_VSI_CONN_TYPE_DEFAULT 0x2 |
|---|
| 833 | | -#define I40E_AQ_VSI_CONN_TYPE_CASCADED 0x3 |
|---|
| 834 | 721 | u8 reserved1; |
|---|
| 835 | 722 | u8 vf_id; |
|---|
| 836 | 723 | u8 reserved2; |
|---|
| 837 | 724 | __le16 vsi_flags; |
|---|
| 838 | | -#define I40E_AQ_VSI_TYPE_SHIFT 0x0 |
|---|
| 839 | | -#define I40E_AQ_VSI_TYPE_MASK (0x3 << I40E_AQ_VSI_TYPE_SHIFT) |
|---|
| 840 | 725 | #define I40E_AQ_VSI_TYPE_VF 0x0 |
|---|
| 841 | 726 | #define I40E_AQ_VSI_TYPE_VMDQ2 0x1 |
|---|
| 842 | 727 | #define I40E_AQ_VSI_TYPE_PF 0x2 |
|---|
| 843 | | -#define I40E_AQ_VSI_TYPE_EMP_MNG 0x3 |
|---|
| 844 | | -#define I40E_AQ_VSI_FLAG_CASCADED_PV 0x4 |
|---|
| 845 | 728 | __le32 addr_high; |
|---|
| 846 | 729 | __le32 addr_low; |
|---|
| 847 | 730 | }; |
|---|
| .. | .. |
|---|
| 865 | 748 | #define I40E_AQ_VSI_PROP_SWITCH_VALID 0x0001 |
|---|
| 866 | 749 | #define I40E_AQ_VSI_PROP_SECURITY_VALID 0x0002 |
|---|
| 867 | 750 | #define I40E_AQ_VSI_PROP_VLAN_VALID 0x0004 |
|---|
| 868 | | -#define I40E_AQ_VSI_PROP_CAS_PV_VALID 0x0008 |
|---|
| 869 | | -#define I40E_AQ_VSI_PROP_INGRESS_UP_VALID 0x0010 |
|---|
| 870 | | -#define I40E_AQ_VSI_PROP_EGRESS_UP_VALID 0x0020 |
|---|
| 871 | 751 | #define I40E_AQ_VSI_PROP_QUEUE_MAP_VALID 0x0040 |
|---|
| 872 | 752 | #define I40E_AQ_VSI_PROP_QUEUE_OPT_VALID 0x0080 |
|---|
| 873 | | -#define I40E_AQ_VSI_PROP_OUTER_UP_VALID 0x0100 |
|---|
| 874 | 753 | #define I40E_AQ_VSI_PROP_SCHED_VALID 0x0200 |
|---|
| 875 | 754 | /* switch section */ |
|---|
| 876 | 755 | __le16 switch_id; /* 12bit id combined with flags below */ |
|---|
| 877 | 756 | #define I40E_AQ_VSI_SW_ID_SHIFT 0x0000 |
|---|
| 878 | 757 | #define I40E_AQ_VSI_SW_ID_MASK (0xFFF << I40E_AQ_VSI_SW_ID_SHIFT) |
|---|
| 879 | | -#define I40E_AQ_VSI_SW_ID_FLAG_NOT_STAG 0x1000 |
|---|
| 880 | 758 | #define I40E_AQ_VSI_SW_ID_FLAG_ALLOW_LB 0x2000 |
|---|
| 881 | 759 | #define I40E_AQ_VSI_SW_ID_FLAG_LOCAL_LB 0x4000 |
|---|
| 882 | 760 | u8 sw_reserved[2]; |
|---|
| 883 | 761 | /* security section */ |
|---|
| 884 | 762 | u8 sec_flags; |
|---|
| 885 | | -#define I40E_AQ_VSI_SEC_FLAG_ALLOW_DEST_OVRD 0x01 |
|---|
| 886 | 763 | #define I40E_AQ_VSI_SEC_FLAG_ENABLE_VLAN_CHK 0x02 |
|---|
| 887 | 764 | #define I40E_AQ_VSI_SEC_FLAG_ENABLE_MAC_CHK 0x04 |
|---|
| 888 | 765 | u8 sec_reserved; |
|---|
| .. | .. |
|---|
| 894 | 771 | #define I40E_AQ_VSI_PVLAN_MODE_MASK (0x03 << \ |
|---|
| 895 | 772 | I40E_AQ_VSI_PVLAN_MODE_SHIFT) |
|---|
| 896 | 773 | #define I40E_AQ_VSI_PVLAN_MODE_TAGGED 0x01 |
|---|
| 897 | | -#define I40E_AQ_VSI_PVLAN_MODE_UNTAGGED 0x02 |
|---|
| 898 | 774 | #define I40E_AQ_VSI_PVLAN_MODE_ALL 0x03 |
|---|
| 899 | 775 | #define I40E_AQ_VSI_PVLAN_INSERT_PVID 0x04 |
|---|
| 900 | 776 | #define I40E_AQ_VSI_PVLAN_EMOD_SHIFT 0x03 |
|---|
| 901 | 777 | #define I40E_AQ_VSI_PVLAN_EMOD_MASK (0x3 << \ |
|---|
| 902 | 778 | I40E_AQ_VSI_PVLAN_EMOD_SHIFT) |
|---|
| 903 | 779 | #define I40E_AQ_VSI_PVLAN_EMOD_STR_BOTH 0x0 |
|---|
| 904 | | -#define I40E_AQ_VSI_PVLAN_EMOD_STR_UP 0x08 |
|---|
| 905 | 780 | #define I40E_AQ_VSI_PVLAN_EMOD_STR 0x10 |
|---|
| 906 | 781 | #define I40E_AQ_VSI_PVLAN_EMOD_NOTHING 0x18 |
|---|
| 907 | 782 | u8 pvlan_reserved[3]; |
|---|
| 908 | 783 | /* ingress egress up sections */ |
|---|
| 909 | 784 | __le32 ingress_table; /* bitmap, 3 bits per up */ |
|---|
| 910 | | -#define I40E_AQ_VSI_UP_TABLE_UP0_SHIFT 0 |
|---|
| 911 | | -#define I40E_AQ_VSI_UP_TABLE_UP0_MASK (0x7 << \ |
|---|
| 912 | | - I40E_AQ_VSI_UP_TABLE_UP0_SHIFT) |
|---|
| 913 | | -#define I40E_AQ_VSI_UP_TABLE_UP1_SHIFT 3 |
|---|
| 914 | | -#define I40E_AQ_VSI_UP_TABLE_UP1_MASK (0x7 << \ |
|---|
| 915 | | - I40E_AQ_VSI_UP_TABLE_UP1_SHIFT) |
|---|
| 916 | | -#define I40E_AQ_VSI_UP_TABLE_UP2_SHIFT 6 |
|---|
| 917 | | -#define I40E_AQ_VSI_UP_TABLE_UP2_MASK (0x7 << \ |
|---|
| 918 | | - I40E_AQ_VSI_UP_TABLE_UP2_SHIFT) |
|---|
| 919 | | -#define I40E_AQ_VSI_UP_TABLE_UP3_SHIFT 9 |
|---|
| 920 | | -#define I40E_AQ_VSI_UP_TABLE_UP3_MASK (0x7 << \ |
|---|
| 921 | | - I40E_AQ_VSI_UP_TABLE_UP3_SHIFT) |
|---|
| 922 | | -#define I40E_AQ_VSI_UP_TABLE_UP4_SHIFT 12 |
|---|
| 923 | | -#define I40E_AQ_VSI_UP_TABLE_UP4_MASK (0x7 << \ |
|---|
| 924 | | - I40E_AQ_VSI_UP_TABLE_UP4_SHIFT) |
|---|
| 925 | | -#define I40E_AQ_VSI_UP_TABLE_UP5_SHIFT 15 |
|---|
| 926 | | -#define I40E_AQ_VSI_UP_TABLE_UP5_MASK (0x7 << \ |
|---|
| 927 | | - I40E_AQ_VSI_UP_TABLE_UP5_SHIFT) |
|---|
| 928 | | -#define I40E_AQ_VSI_UP_TABLE_UP6_SHIFT 18 |
|---|
| 929 | | -#define I40E_AQ_VSI_UP_TABLE_UP6_MASK (0x7 << \ |
|---|
| 930 | | - I40E_AQ_VSI_UP_TABLE_UP6_SHIFT) |
|---|
| 931 | | -#define I40E_AQ_VSI_UP_TABLE_UP7_SHIFT 21 |
|---|
| 932 | | -#define I40E_AQ_VSI_UP_TABLE_UP7_MASK (0x7 << \ |
|---|
| 933 | | - I40E_AQ_VSI_UP_TABLE_UP7_SHIFT) |
|---|
| 934 | 785 | __le32 egress_table; /* same defines as for ingress table */ |
|---|
| 935 | 786 | /* cascaded PV section */ |
|---|
| 936 | 787 | __le16 cas_pv_tag; |
|---|
| 937 | 788 | u8 cas_pv_flags; |
|---|
| 938 | | -#define I40E_AQ_VSI_CAS_PV_TAGX_SHIFT 0x00 |
|---|
| 939 | | -#define I40E_AQ_VSI_CAS_PV_TAGX_MASK (0x03 << \ |
|---|
| 940 | | - I40E_AQ_VSI_CAS_PV_TAGX_SHIFT) |
|---|
| 941 | | -#define I40E_AQ_VSI_CAS_PV_TAGX_LEAVE 0x00 |
|---|
| 942 | | -#define I40E_AQ_VSI_CAS_PV_TAGX_REMOVE 0x01 |
|---|
| 943 | | -#define I40E_AQ_VSI_CAS_PV_TAGX_COPY 0x02 |
|---|
| 944 | | -#define I40E_AQ_VSI_CAS_PV_INSERT_TAG 0x10 |
|---|
| 945 | | -#define I40E_AQ_VSI_CAS_PV_ETAG_PRUNE 0x20 |
|---|
| 946 | | -#define I40E_AQ_VSI_CAS_PV_ACCEPT_HOST_TAG 0x40 |
|---|
| 947 | 789 | u8 cas_pv_reserved; |
|---|
| 948 | 790 | /* queue mapping section */ |
|---|
| 949 | 791 | __le16 mapping_flags; |
|---|
| 950 | 792 | #define I40E_AQ_VSI_QUE_MAP_CONTIG 0x0 |
|---|
| 951 | 793 | #define I40E_AQ_VSI_QUE_MAP_NONCONTIG 0x1 |
|---|
| 952 | 794 | __le16 queue_mapping[16]; |
|---|
| 953 | | -#define I40E_AQ_VSI_QUEUE_SHIFT 0x0 |
|---|
| 954 | | -#define I40E_AQ_VSI_QUEUE_MASK (0x7FF << I40E_AQ_VSI_QUEUE_SHIFT) |
|---|
| 955 | 795 | __le16 tc_mapping[8]; |
|---|
| 956 | 796 | #define I40E_AQ_VSI_TC_QUE_OFFSET_SHIFT 0 |
|---|
| 957 | | -#define I40E_AQ_VSI_TC_QUE_OFFSET_MASK (0x1FF << \ |
|---|
| 958 | | - I40E_AQ_VSI_TC_QUE_OFFSET_SHIFT) |
|---|
| 959 | 797 | #define I40E_AQ_VSI_TC_QUE_NUMBER_SHIFT 9 |
|---|
| 960 | | -#define I40E_AQ_VSI_TC_QUE_NUMBER_MASK (0x7 << \ |
|---|
| 961 | | - I40E_AQ_VSI_TC_QUE_NUMBER_SHIFT) |
|---|
| 962 | 798 | /* queueing option section */ |
|---|
| 963 | 799 | u8 queueing_opt_flags; |
|---|
| 964 | | -#define I40E_AQ_VSI_QUE_OPT_MULTICAST_UDP_ENA 0x04 |
|---|
| 965 | | -#define I40E_AQ_VSI_QUE_OPT_UNICAST_UDP_ENA 0x08 |
|---|
| 966 | 800 | #define I40E_AQ_VSI_QUE_OPT_TCP_ENA 0x10 |
|---|
| 967 | | -#define I40E_AQ_VSI_QUE_OPT_FCOE_ENA 0x20 |
|---|
| 968 | | -#define I40E_AQ_VSI_QUE_OPT_RSS_LUT_PF 0x00 |
|---|
| 969 | 801 | #define I40E_AQ_VSI_QUE_OPT_RSS_LUT_VSI 0x40 |
|---|
| 970 | 802 | u8 queueing_opt_reserved[3]; |
|---|
| 971 | 803 | /* scheduler section */ |
|---|
| .. | .. |
|---|
| 990 | 822 | */ |
|---|
| 991 | 823 | struct i40e_aqc_add_update_pv { |
|---|
| 992 | 824 | __le16 command_flags; |
|---|
| 993 | | -#define I40E_AQC_PV_FLAG_PV_TYPE 0x1 |
|---|
| 994 | | -#define I40E_AQC_PV_FLAG_FWD_UNKNOWN_STAG_EN 0x2 |
|---|
| 995 | | -#define I40E_AQC_PV_FLAG_FWD_UNKNOWN_ETAG_EN 0x4 |
|---|
| 996 | | -#define I40E_AQC_PV_FLAG_IS_CTRL_PORT 0x8 |
|---|
| 997 | 825 | __le16 uplink_seid; |
|---|
| 998 | 826 | __le16 connected_seid; |
|---|
| 999 | 827 | u8 reserved[10]; |
|---|
| .. | .. |
|---|
| 1004 | 832 | struct i40e_aqc_add_update_pv_completion { |
|---|
| 1005 | 833 | /* reserved for update; for add also encodes error if rc == ENOSPC */ |
|---|
| 1006 | 834 | __le16 pv_seid; |
|---|
| 1007 | | -#define I40E_AQC_PV_ERR_FLAG_NO_PV 0x1 |
|---|
| 1008 | | -#define I40E_AQC_PV_ERR_FLAG_NO_SCHED 0x2 |
|---|
| 1009 | | -#define I40E_AQC_PV_ERR_FLAG_NO_COUNTER 0x4 |
|---|
| 1010 | | -#define I40E_AQC_PV_ERR_FLAG_NO_ENTRY 0x8 |
|---|
| 1011 | 835 | u8 reserved[14]; |
|---|
| 1012 | 836 | }; |
|---|
| 1013 | 837 | |
|---|
| .. | .. |
|---|
| 1021 | 845 | __le16 seid; |
|---|
| 1022 | 846 | __le16 default_stag; |
|---|
| 1023 | 847 | __le16 pv_flags; /* same flags as add_pv */ |
|---|
| 1024 | | -#define I40E_AQC_GET_PV_PV_TYPE 0x1 |
|---|
| 1025 | | -#define I40E_AQC_GET_PV_FRWD_UNKNOWN_STAG 0x2 |
|---|
| 1026 | | -#define I40E_AQC_GET_PV_FRWD_UNKNOWN_ETAG 0x4 |
|---|
| 1027 | 848 | u8 reserved[8]; |
|---|
| 1028 | 849 | __le16 default_port_seid; |
|---|
| 1029 | 850 | }; |
|---|
| .. | .. |
|---|
| 1036 | 857 | __le16 downlink_seid; |
|---|
| 1037 | 858 | __le16 veb_flags; |
|---|
| 1038 | 859 | #define I40E_AQC_ADD_VEB_FLOATING 0x1 |
|---|
| 1039 | | -#define I40E_AQC_ADD_VEB_PORT_TYPE_SHIFT 1 |
|---|
| 1040 | | -#define I40E_AQC_ADD_VEB_PORT_TYPE_MASK (0x3 << \ |
|---|
| 1041 | | - I40E_AQC_ADD_VEB_PORT_TYPE_SHIFT) |
|---|
| 1042 | 860 | #define I40E_AQC_ADD_VEB_PORT_TYPE_DEFAULT 0x2 |
|---|
| 1043 | 861 | #define I40E_AQC_ADD_VEB_PORT_TYPE_DATA 0x4 |
|---|
| 1044 | | -#define I40E_AQC_ADD_VEB_ENABLE_L2_FILTER 0x8 /* deprecated */ |
|---|
| 1045 | 862 | #define I40E_AQC_ADD_VEB_ENABLE_DISABLE_STATS 0x10 |
|---|
| 1046 | 863 | u8 enable_tcs; |
|---|
| 1047 | 864 | u8 reserved[9]; |
|---|
| .. | .. |
|---|
| 1054 | 871 | __le16 switch_seid; |
|---|
| 1055 | 872 | /* also encodes error if rc == ENOSPC; codes are the same as add_pv */ |
|---|
| 1056 | 873 | __le16 veb_seid; |
|---|
| 1057 | | -#define I40E_AQC_VEB_ERR_FLAG_NO_VEB 0x1 |
|---|
| 1058 | | -#define I40E_AQC_VEB_ERR_FLAG_NO_SCHED 0x2 |
|---|
| 1059 | | -#define I40E_AQC_VEB_ERR_FLAG_NO_COUNTER 0x4 |
|---|
| 1060 | | -#define I40E_AQC_VEB_ERR_FLAG_NO_ENTRY 0x8 |
|---|
| 1061 | 874 | __le16 statistic_index; |
|---|
| 1062 | 875 | __le16 vebs_used; |
|---|
| 1063 | 876 | __le16 vebs_free; |
|---|
| .. | .. |
|---|
| 1090 | 903 | struct i40e_aqc_macvlan { |
|---|
| 1091 | 904 | __le16 num_addresses; |
|---|
| 1092 | 905 | __le16 seid[3]; |
|---|
| 1093 | | -#define I40E_AQC_MACVLAN_CMD_SEID_NUM_SHIFT 0 |
|---|
| 1094 | | -#define I40E_AQC_MACVLAN_CMD_SEID_NUM_MASK (0x3FF << \ |
|---|
| 1095 | | - I40E_AQC_MACVLAN_CMD_SEID_NUM_SHIFT) |
|---|
| 1096 | 906 | #define I40E_AQC_MACVLAN_CMD_SEID_VALID 0x8000 |
|---|
| 1097 | 907 | __le32 addr_high; |
|---|
| 1098 | 908 | __le32 addr_low; |
|---|
| .. | .. |
|---|
| 1106 | 916 | __le16 vlan_tag; |
|---|
| 1107 | 917 | __le16 flags; |
|---|
| 1108 | 918 | #define I40E_AQC_MACVLAN_ADD_PERFECT_MATCH 0x0001 |
|---|
| 1109 | | -#define I40E_AQC_MACVLAN_ADD_HASH_MATCH 0x0002 |
|---|
| 1110 | 919 | #define I40E_AQC_MACVLAN_ADD_IGNORE_VLAN 0x0004 |
|---|
| 1111 | | -#define I40E_AQC_MACVLAN_ADD_TO_QUEUE 0x0008 |
|---|
| 1112 | 920 | #define I40E_AQC_MACVLAN_ADD_USE_SHARED_MAC 0x0010 |
|---|
| 1113 | 921 | __le16 queue_number; |
|---|
| 1114 | | -#define I40E_AQC_MACVLAN_CMD_QUEUE_SHIFT 0 |
|---|
| 1115 | | -#define I40E_AQC_MACVLAN_CMD_QUEUE_MASK (0x7FF << \ |
|---|
| 1116 | | - I40E_AQC_MACVLAN_CMD_SEID_NUM_SHIFT) |
|---|
| 1117 | 922 | /* response section */ |
|---|
| 1118 | 923 | u8 match_method; |
|---|
| 1119 | | -#define I40E_AQC_MM_PERFECT_MATCH 0x01 |
|---|
| 1120 | | -#define I40E_AQC_MM_HASH_MATCH 0x02 |
|---|
| 1121 | 924 | #define I40E_AQC_MM_ERR_NO_RES 0xFF |
|---|
| 1122 | 925 | u8 reserved1[3]; |
|---|
| 1123 | 926 | }; |
|---|
| .. | .. |
|---|
| 1143 | 946 | __le16 vlan_tag; |
|---|
| 1144 | 947 | u8 flags; |
|---|
| 1145 | 948 | #define I40E_AQC_MACVLAN_DEL_PERFECT_MATCH 0x01 |
|---|
| 1146 | | -#define I40E_AQC_MACVLAN_DEL_HASH_MATCH 0x02 |
|---|
| 1147 | 949 | #define I40E_AQC_MACVLAN_DEL_IGNORE_VLAN 0x08 |
|---|
| 1148 | | -#define I40E_AQC_MACVLAN_DEL_ALL_VSIS 0x10 |
|---|
| 1149 | 950 | u8 reserved[3]; |
|---|
| 1150 | 951 | /* reply section */ |
|---|
| 1151 | 952 | u8 error_code; |
|---|
| 1152 | | -#define I40E_AQC_REMOVE_MACVLAN_SUCCESS 0x0 |
|---|
| 1153 | | -#define I40E_AQC_REMOVE_MACVLAN_FAIL 0xFF |
|---|
| 1154 | 953 | u8 reply_reserved[3]; |
|---|
| 1155 | 954 | }; |
|---|
| 1156 | 955 | |
|---|
| .. | .. |
|---|
| 1161 | 960 | struct i40e_aqc_add_remove_vlan_element_data { |
|---|
| 1162 | 961 | __le16 vlan_tag; |
|---|
| 1163 | 962 | u8 vlan_flags; |
|---|
| 1164 | | -/* flags for add VLAN */ |
|---|
| 1165 | | -#define I40E_AQC_ADD_VLAN_LOCAL 0x1 |
|---|
| 1166 | | -#define I40E_AQC_ADD_PVLAN_TYPE_SHIFT 1 |
|---|
| 1167 | | -#define I40E_AQC_ADD_PVLAN_TYPE_MASK (0x3 << I40E_AQC_ADD_PVLAN_TYPE_SHIFT) |
|---|
| 1168 | | -#define I40E_AQC_ADD_PVLAN_TYPE_REGULAR 0x0 |
|---|
| 1169 | | -#define I40E_AQC_ADD_PVLAN_TYPE_PRIMARY 0x2 |
|---|
| 1170 | | -#define I40E_AQC_ADD_PVLAN_TYPE_SECONDARY 0x4 |
|---|
| 1171 | | -#define I40E_AQC_VLAN_PTYPE_SHIFT 3 |
|---|
| 1172 | | -#define I40E_AQC_VLAN_PTYPE_MASK (0x3 << I40E_AQC_VLAN_PTYPE_SHIFT) |
|---|
| 1173 | | -#define I40E_AQC_VLAN_PTYPE_REGULAR_VSI 0x0 |
|---|
| 1174 | | -#define I40E_AQC_VLAN_PTYPE_PROMISC_VSI 0x8 |
|---|
| 1175 | | -#define I40E_AQC_VLAN_PTYPE_COMMUNITY_VSI 0x10 |
|---|
| 1176 | | -#define I40E_AQC_VLAN_PTYPE_ISOLATED_VSI 0x18 |
|---|
| 1177 | | -/* flags for remove VLAN */ |
|---|
| 1178 | | -#define I40E_AQC_REMOVE_VLAN_ALL 0x1 |
|---|
| 1179 | 963 | u8 reserved; |
|---|
| 1180 | 964 | u8 result; |
|---|
| 1181 | | -/* flags for add VLAN */ |
|---|
| 1182 | | -#define I40E_AQC_ADD_VLAN_SUCCESS 0x0 |
|---|
| 1183 | | -#define I40E_AQC_ADD_VLAN_FAIL_REQUEST 0xFE |
|---|
| 1184 | | -#define I40E_AQC_ADD_VLAN_FAIL_RESOURCE 0xFF |
|---|
| 1185 | | -/* flags for remove VLAN */ |
|---|
| 1186 | | -#define I40E_AQC_REMOVE_VLAN_SUCCESS 0x0 |
|---|
| 1187 | | -#define I40E_AQC_REMOVE_VLAN_FAIL 0xFF |
|---|
| 1188 | 965 | u8 reserved1[3]; |
|---|
| 1189 | 966 | }; |
|---|
| 1190 | 967 | |
|---|
| .. | .. |
|---|
| 1208 | 985 | #define I40E_AQC_SET_VSI_PROMISC_VLAN 0x10 |
|---|
| 1209 | 986 | #define I40E_AQC_SET_VSI_PROMISC_RX_ONLY 0x8000 |
|---|
| 1210 | 987 | __le16 seid; |
|---|
| 1211 | | -#define I40E_AQC_VSI_PROM_CMD_SEID_MASK 0x3FF |
|---|
| 1212 | 988 | __le16 vlan_tag; |
|---|
| 1213 | | -#define I40E_AQC_SET_VSI_VLAN_MASK 0x0FFF |
|---|
| 1214 | 989 | #define I40E_AQC_SET_VSI_VLAN_VALID 0x8000 |
|---|
| 1215 | 990 | u8 reserved[8]; |
|---|
| 1216 | 991 | }; |
|---|
| .. | .. |
|---|
| 1222 | 997 | */ |
|---|
| 1223 | 998 | struct i40e_aqc_add_tag { |
|---|
| 1224 | 999 | __le16 flags; |
|---|
| 1225 | | -#define I40E_AQC_ADD_TAG_FLAG_TO_QUEUE 0x0001 |
|---|
| 1226 | 1000 | __le16 seid; |
|---|
| 1227 | | -#define I40E_AQC_ADD_TAG_CMD_SEID_NUM_SHIFT 0 |
|---|
| 1228 | | -#define I40E_AQC_ADD_TAG_CMD_SEID_NUM_MASK (0x3FF << \ |
|---|
| 1229 | | - I40E_AQC_ADD_TAG_CMD_SEID_NUM_SHIFT) |
|---|
| 1230 | 1001 | __le16 tag; |
|---|
| 1231 | 1002 | __le16 queue_number; |
|---|
| 1232 | 1003 | u8 reserved[8]; |
|---|
| .. | .. |
|---|
| 1247 | 1018 | */ |
|---|
| 1248 | 1019 | struct i40e_aqc_remove_tag { |
|---|
| 1249 | 1020 | __le16 seid; |
|---|
| 1250 | | -#define I40E_AQC_REMOVE_TAG_CMD_SEID_NUM_SHIFT 0 |
|---|
| 1251 | | -#define I40E_AQC_REMOVE_TAG_CMD_SEID_NUM_MASK (0x3FF << \ |
|---|
| 1252 | | - I40E_AQC_REMOVE_TAG_CMD_SEID_NUM_SHIFT) |
|---|
| 1253 | 1021 | __le16 tag; |
|---|
| 1254 | 1022 | u8 reserved[12]; |
|---|
| 1255 | 1023 | }; |
|---|
| .. | .. |
|---|
| 1285 | 1053 | /* Update S/E-Tag (direct 0x0259) */ |
|---|
| 1286 | 1054 | struct i40e_aqc_update_tag { |
|---|
| 1287 | 1055 | __le16 seid; |
|---|
| 1288 | | -#define I40E_AQC_UPDATE_TAG_CMD_SEID_NUM_SHIFT 0 |
|---|
| 1289 | | -#define I40E_AQC_UPDATE_TAG_CMD_SEID_NUM_MASK (0x3FF << \ |
|---|
| 1290 | | - I40E_AQC_UPDATE_TAG_CMD_SEID_NUM_SHIFT) |
|---|
| 1291 | 1056 | __le16 old_tag; |
|---|
| 1292 | 1057 | __le16 new_tag; |
|---|
| 1293 | 1058 | u8 reserved[10]; |
|---|
| .. | .. |
|---|
| 1314 | 1079 | __le16 flags; |
|---|
| 1315 | 1080 | #define I40E_AQC_ADD_CONTROL_PACKET_FLAGS_IGNORE_MAC 0x0001 |
|---|
| 1316 | 1081 | #define I40E_AQC_ADD_CONTROL_PACKET_FLAGS_DROP 0x0002 |
|---|
| 1317 | | -#define I40E_AQC_ADD_CONTROL_PACKET_FLAGS_TO_QUEUE 0x0004 |
|---|
| 1318 | 1082 | #define I40E_AQC_ADD_CONTROL_PACKET_FLAGS_TX 0x0008 |
|---|
| 1319 | | -#define I40E_AQC_ADD_CONTROL_PACKET_FLAGS_RX 0x0000 |
|---|
| 1320 | 1083 | __le16 seid; |
|---|
| 1321 | | -#define I40E_AQC_ADD_CONTROL_PACKET_CMD_SEID_NUM_SHIFT 0 |
|---|
| 1322 | | -#define I40E_AQC_ADD_CONTROL_PACKET_CMD_SEID_NUM_MASK (0x3FF << \ |
|---|
| 1323 | | - I40E_AQC_ADD_CONTROL_PACKET_CMD_SEID_NUM_SHIFT) |
|---|
| 1324 | 1084 | __le16 queue; |
|---|
| 1325 | 1085 | u8 reserved[2]; |
|---|
| 1326 | 1086 | }; |
|---|
| .. | .. |
|---|
| 1346 | 1106 | u8 num_filters; |
|---|
| 1347 | 1107 | u8 reserved; |
|---|
| 1348 | 1108 | __le16 seid; |
|---|
| 1349 | | -#define I40E_AQC_ADD_CLOUD_CMD_SEID_NUM_SHIFT 0 |
|---|
| 1350 | | -#define I40E_AQC_ADD_CLOUD_CMD_SEID_NUM_MASK (0x3FF << \ |
|---|
| 1351 | | - I40E_AQC_ADD_CLOUD_CMD_SEID_NUM_SHIFT) |
|---|
| 1352 | 1109 | u8 big_buffer_flag; |
|---|
| 1353 | 1110 | #define I40E_AQC_ADD_CLOUD_CMD_BB 1 |
|---|
| 1354 | 1111 | u8 reserved2[3]; |
|---|
| .. | .. |
|---|
| 1375 | 1132 | } raw_v6; |
|---|
| 1376 | 1133 | } ipaddr; |
|---|
| 1377 | 1134 | __le16 flags; |
|---|
| 1378 | | -#define I40E_AQC_ADD_CLOUD_FILTER_SHIFT 0 |
|---|
| 1379 | | -#define I40E_AQC_ADD_CLOUD_FILTER_MASK (0x3F << \ |
|---|
| 1380 | | - I40E_AQC_ADD_CLOUD_FILTER_SHIFT) |
|---|
| 1381 | 1135 | /* 0x0000 reserved */ |
|---|
| 1382 | | -#define I40E_AQC_ADD_CLOUD_FILTER_OIP 0x0001 |
|---|
| 1136 | +/* 0x0001 reserved */ |
|---|
| 1383 | 1137 | /* 0x0002 reserved */ |
|---|
| 1384 | 1138 | #define I40E_AQC_ADD_CLOUD_FILTER_IMAC_IVLAN 0x0003 |
|---|
| 1385 | 1139 | #define I40E_AQC_ADD_CLOUD_FILTER_IMAC_IVLAN_TEN_ID 0x0004 |
|---|
| .. | .. |
|---|
| 1391 | 1145 | #define I40E_AQC_ADD_CLOUD_FILTER_IMAC 0x000A |
|---|
| 1392 | 1146 | #define I40E_AQC_ADD_CLOUD_FILTER_OMAC_TEN_ID_IMAC 0x000B |
|---|
| 1393 | 1147 | #define I40E_AQC_ADD_CLOUD_FILTER_IIP 0x000C |
|---|
| 1148 | +/* 0x000D reserved */ |
|---|
| 1149 | +/* 0x000E reserved */ |
|---|
| 1150 | +/* 0x000F reserved */ |
|---|
| 1394 | 1151 | /* 0x0010 to 0x0017 is for custom filters */ |
|---|
| 1395 | 1152 | #define I40E_AQC_ADD_CLOUD_FILTER_IP_PORT 0x0010 /* Dest IP + L4 Port */ |
|---|
| 1396 | 1153 | #define I40E_AQC_ADD_CLOUD_FILTER_MAC_PORT 0x0011 /* Dest MAC + L4 Port */ |
|---|
| 1397 | 1154 | #define I40E_AQC_ADD_CLOUD_FILTER_MAC_VLAN_PORT 0x0012 /* Dest MAC + VLAN + L4 Port */ |
|---|
| 1398 | 1155 | |
|---|
| 1399 | | -#define I40E_AQC_ADD_CLOUD_FLAGS_TO_QUEUE 0x0080 |
|---|
| 1400 | | -#define I40E_AQC_ADD_CLOUD_VNK_SHIFT 6 |
|---|
| 1401 | | -#define I40E_AQC_ADD_CLOUD_VNK_MASK 0x00C0 |
|---|
| 1402 | 1156 | #define I40E_AQC_ADD_CLOUD_FLAGS_IPV4 0 |
|---|
| 1403 | 1157 | #define I40E_AQC_ADD_CLOUD_FLAGS_IPV6 0x0100 |
|---|
| 1404 | 1158 | |
|---|
| 1405 | 1159 | #define I40E_AQC_ADD_CLOUD_TNL_TYPE_SHIFT 9 |
|---|
| 1406 | 1160 | #define I40E_AQC_ADD_CLOUD_TNL_TYPE_MASK 0x1E00 |
|---|
| 1407 | | -#define I40E_AQC_ADD_CLOUD_TNL_TYPE_VXLAN 0 |
|---|
| 1408 | | -#define I40E_AQC_ADD_CLOUD_TNL_TYPE_NVGRE_OMAC 1 |
|---|
| 1409 | 1161 | #define I40E_AQC_ADD_CLOUD_TNL_TYPE_GENEVE 2 |
|---|
| 1410 | | -#define I40E_AQC_ADD_CLOUD_TNL_TYPE_IP 3 |
|---|
| 1411 | | -#define I40E_AQC_ADD_CLOUD_TNL_TYPE_RESERVED 4 |
|---|
| 1412 | | -#define I40E_AQC_ADD_CLOUD_TNL_TYPE_VXLAN_GPE 5 |
|---|
| 1413 | 1162 | |
|---|
| 1414 | | -#define I40E_AQC_ADD_CLOUD_FLAGS_SHARED_OUTER_MAC 0x2000 |
|---|
| 1415 | | -#define I40E_AQC_ADD_CLOUD_FLAGS_SHARED_INNER_MAC 0x4000 |
|---|
| 1416 | | -#define I40E_AQC_ADD_CLOUD_FLAGS_SHARED_OUTER_IP 0x8000 |
|---|
| 1417 | 1163 | |
|---|
| 1418 | 1164 | __le32 tenant_id; |
|---|
| 1419 | 1165 | u8 reserved[4]; |
|---|
| 1420 | 1166 | __le16 queue_number; |
|---|
| 1421 | | -#define I40E_AQC_ADD_CLOUD_QUEUE_SHIFT 0 |
|---|
| 1422 | | -#define I40E_AQC_ADD_CLOUD_QUEUE_MASK (0x7FF << \ |
|---|
| 1423 | | - I40E_AQC_ADD_CLOUD_QUEUE_SHIFT) |
|---|
| 1424 | 1167 | u8 reserved2[14]; |
|---|
| 1425 | 1168 | /* response section */ |
|---|
| 1426 | 1169 | u8 allocation_result; |
|---|
| 1427 | | -#define I40E_AQC_ADD_CLOUD_FILTER_SUCCESS 0x0 |
|---|
| 1428 | | -#define I40E_AQC_ADD_CLOUD_FILTER_FAIL 0xFF |
|---|
| 1429 | 1170 | u8 response_reserved[7]; |
|---|
| 1430 | 1171 | }; |
|---|
| 1431 | 1172 | |
|---|
| .. | .. |
|---|
| 1437 | 1178 | struct i40e_aqc_cloud_filters_element_bb { |
|---|
| 1438 | 1179 | struct i40e_aqc_cloud_filters_element_data element; |
|---|
| 1439 | 1180 | u16 general_fields[32]; |
|---|
| 1440 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X10_WORD0 0 |
|---|
| 1441 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X10_WORD1 1 |
|---|
| 1442 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X10_WORD2 2 |
|---|
| 1443 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X11_WORD0 3 |
|---|
| 1444 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X11_WORD1 4 |
|---|
| 1445 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X11_WORD2 5 |
|---|
| 1446 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X12_WORD0 6 |
|---|
| 1447 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X12_WORD1 7 |
|---|
| 1448 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X12_WORD2 8 |
|---|
| 1449 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X13_WORD0 9 |
|---|
| 1450 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X13_WORD1 10 |
|---|
| 1451 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X13_WORD2 11 |
|---|
| 1452 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X14_WORD0 12 |
|---|
| 1453 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X14_WORD1 13 |
|---|
| 1454 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X14_WORD2 14 |
|---|
| 1455 | 1181 | #define I40E_AQC_ADD_CLOUD_FV_FLU_0X16_WORD0 15 |
|---|
| 1456 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X16_WORD1 16 |
|---|
| 1457 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X16_WORD2 17 |
|---|
| 1458 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X16_WORD3 18 |
|---|
| 1459 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X16_WORD4 19 |
|---|
| 1460 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X16_WORD5 20 |
|---|
| 1461 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X16_WORD6 21 |
|---|
| 1462 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X16_WORD7 22 |
|---|
| 1463 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X17_WORD0 23 |
|---|
| 1464 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X17_WORD1 24 |
|---|
| 1465 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X17_WORD2 25 |
|---|
| 1466 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X17_WORD3 26 |
|---|
| 1467 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X17_WORD4 27 |
|---|
| 1468 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X17_WORD5 28 |
|---|
| 1469 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X17_WORD6 29 |
|---|
| 1470 | | -#define I40E_AQC_ADD_CLOUD_FV_FLU_0X17_WORD7 30 |
|---|
| 1471 | 1182 | }; |
|---|
| 1472 | 1183 | |
|---|
| 1473 | 1184 | I40E_CHECK_STRUCT_LEN(0x80, i40e_aqc_cloud_filters_element_bb); |
|---|
| .. | .. |
|---|
| 1496 | 1207 | |
|---|
| 1497 | 1208 | struct i40e_aqc_replace_cloud_filters_cmd { |
|---|
| 1498 | 1209 | u8 valid_flags; |
|---|
| 1499 | | -#define I40E_AQC_REPLACE_L1_FILTER 0x0 |
|---|
| 1500 | | -#define I40E_AQC_REPLACE_CLOUD_FILTER 0x1 |
|---|
| 1501 | | -#define I40E_AQC_GET_CLOUD_FILTERS 0x2 |
|---|
| 1502 | | -#define I40E_AQC_MIRROR_CLOUD_FILTER 0x4 |
|---|
| 1503 | | -#define I40E_AQC_HIGH_PRIORITY_CLOUD_FILTER 0x8 |
|---|
| 1504 | 1210 | u8 old_filter_type; |
|---|
| 1505 | 1211 | u8 new_filter_type; |
|---|
| 1506 | 1212 | u8 tr_bit; |
|---|
| .. | .. |
|---|
| 1513 | 1219 | |
|---|
| 1514 | 1220 | struct i40e_aqc_replace_cloud_filters_cmd_buf { |
|---|
| 1515 | 1221 | u8 data[32]; |
|---|
| 1516 | | -/* Filter type INPUT codes*/ |
|---|
| 1517 | | -#define I40E_AQC_REPLACE_CLOUD_CMD_INPUT_ENTRIES_MAX 3 |
|---|
| 1518 | | -#define I40E_AQC_REPLACE_CLOUD_CMD_INPUT_VALIDATED BIT(7) |
|---|
| 1519 | | - |
|---|
| 1520 | | -/* Field Vector offsets */ |
|---|
| 1521 | | -#define I40E_AQC_REPLACE_CLOUD_CMD_INPUT_FV_MAC_DA 0 |
|---|
| 1522 | | -#define I40E_AQC_REPLACE_CLOUD_CMD_INPUT_FV_STAG_ETH 6 |
|---|
| 1523 | | -#define I40E_AQC_REPLACE_CLOUD_CMD_INPUT_FV_STAG 7 |
|---|
| 1524 | | -#define I40E_AQC_REPLACE_CLOUD_CMD_INPUT_FV_VLAN 8 |
|---|
| 1525 | | -#define I40E_AQC_REPLACE_CLOUD_CMD_INPUT_FV_STAG_OVLAN 9 |
|---|
| 1526 | | -#define I40E_AQC_REPLACE_CLOUD_CMD_INPUT_FV_STAG_IVLAN 10 |
|---|
| 1527 | | -#define I40E_AQC_REPLACE_CLOUD_CMD_INPUT_FV_TUNNLE_KEY 11 |
|---|
| 1528 | | -#define I40E_AQC_REPLACE_CLOUD_CMD_INPUT_FV_IMAC 12 |
|---|
| 1529 | | -/* big FLU */ |
|---|
| 1530 | | -#define I40E_AQC_REPLACE_CLOUD_CMD_INPUT_FV_IP_DA 14 |
|---|
| 1531 | | -/* big FLU */ |
|---|
| 1532 | | -#define I40E_AQC_REPLACE_CLOUD_CMD_INPUT_FV_OIP_DA 15 |
|---|
| 1533 | | - |
|---|
| 1534 | | -#define I40E_AQC_REPLACE_CLOUD_CMD_INPUT_FV_INNER_VLAN 37 |
|---|
| 1535 | 1222 | struct i40e_filter_data filters[8]; |
|---|
| 1536 | 1223 | }; |
|---|
| 1537 | 1224 | |
|---|
| .. | .. |
|---|
| 1548 | 1235 | #define I40E_AQC_MIRROR_RULE_TYPE_SHIFT 0 |
|---|
| 1549 | 1236 | #define I40E_AQC_MIRROR_RULE_TYPE_MASK (0x7 << \ |
|---|
| 1550 | 1237 | I40E_AQC_MIRROR_RULE_TYPE_SHIFT) |
|---|
| 1551 | | -#define I40E_AQC_MIRROR_RULE_TYPE_VPORT_INGRESS 1 |
|---|
| 1552 | | -#define I40E_AQC_MIRROR_RULE_TYPE_VPORT_EGRESS 2 |
|---|
| 1553 | 1238 | #define I40E_AQC_MIRROR_RULE_TYPE_VLAN 3 |
|---|
| 1554 | 1239 | #define I40E_AQC_MIRROR_RULE_TYPE_ALL_INGRESS 4 |
|---|
| 1555 | 1240 | #define I40E_AQC_MIRROR_RULE_TYPE_ALL_EGRESS 5 |
|---|
| .. | .. |
|---|
| 1592 | 1277 | |
|---|
| 1593 | 1278 | struct i40e_aqc_get_applied_profiles { |
|---|
| 1594 | 1279 | u8 flags; |
|---|
| 1595 | | -#define I40E_AQC_GET_DDP_GET_CONF 0x1 |
|---|
| 1596 | | -#define I40E_AQC_GET_DDP_GET_RDPU_CONF 0x2 |
|---|
| 1597 | 1280 | u8 rsv[3]; |
|---|
| 1598 | 1281 | __le32 reserved; |
|---|
| 1599 | 1282 | __le32 addr_high; |
|---|
| .. | .. |
|---|
| 1610 | 1293 | struct i40e_aqc_pfc_ignore { |
|---|
| 1611 | 1294 | u8 tc_bitmap; |
|---|
| 1612 | 1295 | u8 command_flags; /* unused on response */ |
|---|
| 1613 | | -#define I40E_AQC_PFC_IGNORE_SET 0x80 |
|---|
| 1614 | | -#define I40E_AQC_PFC_IGNORE_CLEAR 0x0 |
|---|
| 1615 | 1296 | u8 reserved[14]; |
|---|
| 1616 | 1297 | }; |
|---|
| 1617 | 1298 | |
|---|
| .. | .. |
|---|
| 1728 | 1409 | u8 reserved[4]; |
|---|
| 1729 | 1410 | u8 tc_valid_bits; |
|---|
| 1730 | 1411 | u8 seepage; |
|---|
| 1731 | | -#define I40E_AQ_ETS_SEEPAGE_EN_MASK 0x1 |
|---|
| 1732 | 1412 | u8 tc_strict_priority_flags; |
|---|
| 1733 | 1413 | u8 reserved1[17]; |
|---|
| 1734 | 1414 | u8 tc_bw_share_credits[8]; |
|---|
| .. | .. |
|---|
| 1885 | 1565 | I40E_PHY_TYPE_25GBASE_LR = 0x22, |
|---|
| 1886 | 1566 | I40E_PHY_TYPE_25GBASE_AOC = 0x23, |
|---|
| 1887 | 1567 | I40E_PHY_TYPE_25GBASE_ACC = 0x24, |
|---|
| 1568 | + I40E_PHY_TYPE_2_5GBASE_T = 0x26, |
|---|
| 1569 | + I40E_PHY_TYPE_5GBASE_T = 0x27, |
|---|
| 1570 | + I40E_PHY_TYPE_2_5GBASE_T_LINK_STATUS = 0x30, |
|---|
| 1571 | + I40E_PHY_TYPE_5GBASE_T_LINK_STATUS = 0x31, |
|---|
| 1888 | 1572 | I40E_PHY_TYPE_MAX, |
|---|
| 1889 | 1573 | I40E_PHY_TYPE_NOT_SUPPORTED_HIGH_TEMP = 0xFD, |
|---|
| 1890 | 1574 | I40E_PHY_TYPE_EMPTY = 0xFE, |
|---|
| .. | .. |
|---|
| 1926 | 1610 | BIT_ULL(I40E_PHY_TYPE_25GBASE_SR) | \ |
|---|
| 1927 | 1611 | BIT_ULL(I40E_PHY_TYPE_25GBASE_LR) | \ |
|---|
| 1928 | 1612 | BIT_ULL(I40E_PHY_TYPE_25GBASE_AOC) | \ |
|---|
| 1929 | | - BIT_ULL(I40E_PHY_TYPE_25GBASE_ACC)) |
|---|
| 1613 | + BIT_ULL(I40E_PHY_TYPE_25GBASE_ACC) | \ |
|---|
| 1614 | + BIT_ULL(I40E_PHY_TYPE_2_5GBASE_T) | \ |
|---|
| 1615 | + BIT_ULL(I40E_PHY_TYPE_5GBASE_T)) |
|---|
| 1930 | 1616 | |
|---|
| 1617 | +#define I40E_LINK_SPEED_2_5GB_SHIFT 0x0 |
|---|
| 1931 | 1618 | #define I40E_LINK_SPEED_100MB_SHIFT 0x1 |
|---|
| 1932 | 1619 | #define I40E_LINK_SPEED_1000MB_SHIFT 0x2 |
|---|
| 1933 | 1620 | #define I40E_LINK_SPEED_10GB_SHIFT 0x3 |
|---|
| 1934 | 1621 | #define I40E_LINK_SPEED_40GB_SHIFT 0x4 |
|---|
| 1935 | 1622 | #define I40E_LINK_SPEED_20GB_SHIFT 0x5 |
|---|
| 1936 | 1623 | #define I40E_LINK_SPEED_25GB_SHIFT 0x6 |
|---|
| 1624 | +#define I40E_LINK_SPEED_5GB_SHIFT 0x7 |
|---|
| 1937 | 1625 | |
|---|
| 1938 | 1626 | enum i40e_aq_link_speed { |
|---|
| 1939 | 1627 | I40E_LINK_SPEED_UNKNOWN = 0, |
|---|
| 1940 | 1628 | I40E_LINK_SPEED_100MB = BIT(I40E_LINK_SPEED_100MB_SHIFT), |
|---|
| 1941 | 1629 | I40E_LINK_SPEED_1GB = BIT(I40E_LINK_SPEED_1000MB_SHIFT), |
|---|
| 1630 | + I40E_LINK_SPEED_2_5GB = (1 << I40E_LINK_SPEED_2_5GB_SHIFT), |
|---|
| 1631 | + I40E_LINK_SPEED_5GB = (1 << I40E_LINK_SPEED_5GB_SHIFT), |
|---|
| 1942 | 1632 | I40E_LINK_SPEED_10GB = BIT(I40E_LINK_SPEED_10GB_SHIFT), |
|---|
| 1943 | 1633 | I40E_LINK_SPEED_40GB = BIT(I40E_LINK_SPEED_40GB_SHIFT), |
|---|
| 1944 | 1634 | I40E_LINK_SPEED_20GB = BIT(I40E_LINK_SPEED_20GB_SHIFT), |
|---|
| .. | .. |
|---|
| 1961 | 1651 | u8 abilities; |
|---|
| 1962 | 1652 | #define I40E_AQ_PHY_FLAG_PAUSE_TX 0x01 |
|---|
| 1963 | 1653 | #define I40E_AQ_PHY_FLAG_PAUSE_RX 0x02 |
|---|
| 1964 | | -#define I40E_AQ_PHY_FLAG_LOW_POWER 0x04 |
|---|
| 1965 | | -#define I40E_AQ_PHY_LINK_ENABLED 0x08 |
|---|
| 1966 | | -#define I40E_AQ_PHY_AN_ENABLED 0x10 |
|---|
| 1967 | | -#define I40E_AQ_PHY_FLAG_MODULE_QUAL 0x20 |
|---|
| 1968 | | -#define I40E_AQ_PHY_FEC_ABILITY_KR 0x40 |
|---|
| 1969 | | -#define I40E_AQ_PHY_FEC_ABILITY_RS 0x80 |
|---|
| 1970 | 1654 | __le16 eee_capability; |
|---|
| 1971 | | -#define I40E_AQ_EEE_100BASE_TX 0x0002 |
|---|
| 1972 | | -#define I40E_AQ_EEE_1000BASE_T 0x0004 |
|---|
| 1973 | | -#define I40E_AQ_EEE_10GBASE_T 0x0008 |
|---|
| 1974 | | -#define I40E_AQ_EEE_1000BASE_KX 0x0010 |
|---|
| 1975 | | -#define I40E_AQ_EEE_10GBASE_KX4 0x0020 |
|---|
| 1976 | | -#define I40E_AQ_EEE_10GBASE_KR 0x0040 |
|---|
| 1977 | 1655 | __le32 eeer_val; |
|---|
| 1978 | 1656 | u8 d3_lpan; |
|---|
| 1979 | | -#define I40E_AQ_SET_PHY_D3_LPAN_ENA 0x01 |
|---|
| 1980 | 1657 | u8 phy_type_ext; |
|---|
| 1981 | 1658 | #define I40E_AQ_PHY_TYPE_EXT_25G_KR 0X01 |
|---|
| 1982 | 1659 | #define I40E_AQ_PHY_TYPE_EXT_25G_CR 0X02 |
|---|
| 1983 | 1660 | #define I40E_AQ_PHY_TYPE_EXT_25G_SR 0x04 |
|---|
| 1984 | 1661 | #define I40E_AQ_PHY_TYPE_EXT_25G_LR 0x08 |
|---|
| 1985 | | -#define I40E_AQ_PHY_TYPE_EXT_25G_AOC 0x10 |
|---|
| 1986 | | -#define I40E_AQ_PHY_TYPE_EXT_25G_ACC 0x20 |
|---|
| 1987 | 1662 | u8 fec_cfg_curr_mod_ext_info; |
|---|
| 1988 | | -#define I40E_AQ_ENABLE_FEC_KR 0x01 |
|---|
| 1989 | | -#define I40E_AQ_ENABLE_FEC_RS 0x02 |
|---|
| 1990 | 1663 | #define I40E_AQ_REQUEST_FEC_KR 0x04 |
|---|
| 1991 | 1664 | #define I40E_AQ_REQUEST_FEC_RS 0x08 |
|---|
| 1992 | 1665 | #define I40E_AQ_ENABLE_FEC_AUTO 0x10 |
|---|
| 1993 | | -#define I40E_AQ_FEC |
|---|
| 1994 | | -#define I40E_AQ_MODULE_TYPE_EXT_MASK 0xE0 |
|---|
| 1995 | | -#define I40E_AQ_MODULE_TYPE_EXT_SHIFT 5 |
|---|
| 1996 | 1666 | |
|---|
| 1997 | 1667 | u8 ext_comp_code; |
|---|
| 1998 | 1668 | u8 phy_id[4]; |
|---|
| .. | .. |
|---|
| 2038 | 1708 | struct i40e_aq_set_mac_config { |
|---|
| 2039 | 1709 | __le16 max_frame_size; |
|---|
| 2040 | 1710 | u8 params; |
|---|
| 2041 | | -#define I40E_AQ_SET_MAC_CONFIG_CRC_EN 0x04 |
|---|
| 2042 | | -#define I40E_AQ_SET_MAC_CONFIG_PACING_MASK 0x78 |
|---|
| 2043 | | -#define I40E_AQ_SET_MAC_CONFIG_PACING_SHIFT 3 |
|---|
| 2044 | | -#define I40E_AQ_SET_MAC_CONFIG_PACING_NONE 0x0 |
|---|
| 2045 | | -#define I40E_AQ_SET_MAC_CONFIG_PACING_1B_13TX 0xF |
|---|
| 2046 | | -#define I40E_AQ_SET_MAC_CONFIG_PACING_1DW_9TX 0x9 |
|---|
| 2047 | | -#define I40E_AQ_SET_MAC_CONFIG_PACING_1DW_4TX 0x8 |
|---|
| 2048 | | -#define I40E_AQ_SET_MAC_CONFIG_PACING_3DW_7TX 0x7 |
|---|
| 2049 | | -#define I40E_AQ_SET_MAC_CONFIG_PACING_2DW_3TX 0x6 |
|---|
| 2050 | | -#define I40E_AQ_SET_MAC_CONFIG_PACING_1DW_1TX 0x5 |
|---|
| 2051 | | -#define I40E_AQ_SET_MAC_CONFIG_PACING_3DW_2TX 0x4 |
|---|
| 2052 | | -#define I40E_AQ_SET_MAC_CONFIG_PACING_7DW_3TX 0x3 |
|---|
| 2053 | | -#define I40E_AQ_SET_MAC_CONFIG_PACING_4DW_1TX 0x2 |
|---|
| 2054 | | -#define I40E_AQ_SET_MAC_CONFIG_PACING_9DW_1TX 0x1 |
|---|
| 2055 | 1711 | u8 tx_timer_priority; /* bitmap */ |
|---|
| 2056 | 1712 | __le16 tx_timer_value; |
|---|
| 2057 | 1713 | __le16 fc_refresh_threshold; |
|---|
| .. | .. |
|---|
| 2073 | 1729 | /* Get Link Status cmd & response data structure (direct 0x0607) */ |
|---|
| 2074 | 1730 | struct i40e_aqc_get_link_status { |
|---|
| 2075 | 1731 | __le16 command_flags; /* only field set on command */ |
|---|
| 2076 | | -#define I40E_AQ_LSE_MASK 0x3 |
|---|
| 2077 | | -#define I40E_AQ_LSE_NOP 0x0 |
|---|
| 2078 | 1732 | #define I40E_AQ_LSE_DISABLE 0x2 |
|---|
| 2079 | 1733 | #define I40E_AQ_LSE_ENABLE 0x3 |
|---|
| 2080 | 1734 | /* only response uses this flag */ |
|---|
| .. | .. |
|---|
| 2083 | 1737 | u8 link_speed; /* i40e_aq_link_speed */ |
|---|
| 2084 | 1738 | u8 link_info; |
|---|
| 2085 | 1739 | #define I40E_AQ_LINK_UP 0x01 /* obsolete */ |
|---|
| 2086 | | -#define I40E_AQ_LINK_UP_FUNCTION 0x01 |
|---|
| 2087 | | -#define I40E_AQ_LINK_FAULT 0x02 |
|---|
| 2088 | | -#define I40E_AQ_LINK_FAULT_TX 0x04 |
|---|
| 2089 | | -#define I40E_AQ_LINK_FAULT_RX 0x08 |
|---|
| 2090 | | -#define I40E_AQ_LINK_FAULT_REMOTE 0x10 |
|---|
| 2091 | | -#define I40E_AQ_LINK_UP_PORT 0x20 |
|---|
| 2092 | 1740 | #define I40E_AQ_MEDIA_AVAILABLE 0x40 |
|---|
| 2093 | | -#define I40E_AQ_SIGNAL_DETECT 0x80 |
|---|
| 2094 | 1741 | u8 an_info; |
|---|
| 2095 | 1742 | #define I40E_AQ_AN_COMPLETED 0x01 |
|---|
| 2096 | | -#define I40E_AQ_LP_AN_ABILITY 0x02 |
|---|
| 2097 | | -#define I40E_AQ_PD_FAULT 0x04 |
|---|
| 2098 | | -#define I40E_AQ_FEC_EN 0x08 |
|---|
| 2099 | | -#define I40E_AQ_PHY_LOW_POWER 0x10 |
|---|
| 2100 | 1743 | #define I40E_AQ_LINK_PAUSE_TX 0x20 |
|---|
| 2101 | 1744 | #define I40E_AQ_LINK_PAUSE_RX 0x40 |
|---|
| 2102 | 1745 | #define I40E_AQ_QUALIFIED_MODULE 0x80 |
|---|
| 2103 | 1746 | u8 ext_info; |
|---|
| 2104 | | -#define I40E_AQ_LINK_PHY_TEMP_ALARM 0x01 |
|---|
| 2105 | | -#define I40E_AQ_LINK_XCESSIVE_ERRORS 0x02 |
|---|
| 2106 | | -#define I40E_AQ_LINK_TX_SHIFT 0x02 |
|---|
| 2107 | | -#define I40E_AQ_LINK_TX_MASK (0x03 << I40E_AQ_LINK_TX_SHIFT) |
|---|
| 2108 | | -#define I40E_AQ_LINK_TX_ACTIVE 0x00 |
|---|
| 2109 | | -#define I40E_AQ_LINK_TX_DRAINED 0x01 |
|---|
| 2110 | | -#define I40E_AQ_LINK_TX_FLUSHED 0x03 |
|---|
| 2111 | | -#define I40E_AQ_LINK_FORCED_40G 0x10 |
|---|
| 2112 | | -/* 25G Error Codes */ |
|---|
| 2113 | | -#define I40E_AQ_25G_NO_ERR 0X00 |
|---|
| 2114 | | -#define I40E_AQ_25G_NOT_PRESENT 0X01 |
|---|
| 2115 | | -#define I40E_AQ_25G_NVM_CRC_ERR 0X02 |
|---|
| 2116 | | -#define I40E_AQ_25G_SBUS_UCODE_ERR 0X03 |
|---|
| 2117 | | -#define I40E_AQ_25G_SERDES_UCODE_ERR 0X04 |
|---|
| 2118 | | -#define I40E_AQ_25G_NIMB_UCODE_ERR 0X05 |
|---|
| 2119 | 1747 | u8 loopback; /* use defines from i40e_aqc_set_lb_mode */ |
|---|
| 2120 | 1748 | /* Since firmware API 1.7 loopback field keeps power class info as well */ |
|---|
| 2121 | 1749 | #define I40E_AQ_LOOPBACK_MASK 0x07 |
|---|
| 2122 | | -#define I40E_AQ_PWR_CLASS_SHIFT_LB 6 |
|---|
| 2123 | | -#define I40E_AQ_PWR_CLASS_MASK_LB (0x03 << I40E_AQ_PWR_CLASS_SHIFT_LB) |
|---|
| 2124 | 1750 | __le16 max_frame_size; |
|---|
| 2125 | 1751 | u8 config; |
|---|
| 2126 | 1752 | #define I40E_AQ_CONFIG_FEC_KR_ENA 0x01 |
|---|
| .. | .. |
|---|
| 2130 | 1756 | union { |
|---|
| 2131 | 1757 | struct { |
|---|
| 2132 | 1758 | u8 power_desc; |
|---|
| 2133 | | -#define I40E_AQ_LINK_POWER_CLASS_1 0x00 |
|---|
| 2134 | | -#define I40E_AQ_LINK_POWER_CLASS_2 0x01 |
|---|
| 2135 | | -#define I40E_AQ_LINK_POWER_CLASS_3 0x02 |
|---|
| 2136 | | -#define I40E_AQ_LINK_POWER_CLASS_4 0x03 |
|---|
| 2137 | | -#define I40E_AQ_PWR_CLASS_MASK 0x03 |
|---|
| 2138 | 1759 | u8 reserved[4]; |
|---|
| 2139 | 1760 | }; |
|---|
| 2140 | 1761 | struct { |
|---|
| .. | .. |
|---|
| 2152 | 1773 | __le16 event_mask; |
|---|
| 2153 | 1774 | #define I40E_AQ_EVENT_LINK_UPDOWN 0x0002 |
|---|
| 2154 | 1775 | #define I40E_AQ_EVENT_MEDIA_NA 0x0004 |
|---|
| 2155 | | -#define I40E_AQ_EVENT_LINK_FAULT 0x0008 |
|---|
| 2156 | | -#define I40E_AQ_EVENT_PHY_TEMP_ALARM 0x0010 |
|---|
| 2157 | | -#define I40E_AQ_EVENT_EXCESSIVE_ERRORS 0x0020 |
|---|
| 2158 | | -#define I40E_AQ_EVENT_SIGNAL_DETECT 0x0040 |
|---|
| 2159 | | -#define I40E_AQ_EVENT_AN_COMPLETED 0x0080 |
|---|
| 2160 | 1776 | #define I40E_AQ_EVENT_MODULE_QUAL_FAIL 0x0100 |
|---|
| 2161 | | -#define I40E_AQ_EVENT_PORT_TX_SUSPENDED 0x0200 |
|---|
| 2162 | 1777 | u8 reserved1[6]; |
|---|
| 2163 | 1778 | }; |
|---|
| 2164 | 1779 | |
|---|
| .. | .. |
|---|
| 2190 | 1805 | /* Set PHY Debug command (0x0622) */ |
|---|
| 2191 | 1806 | struct i40e_aqc_set_phy_debug { |
|---|
| 2192 | 1807 | u8 command_flags; |
|---|
| 2193 | | -#define I40E_AQ_PHY_DEBUG_RESET_INTERNAL 0x02 |
|---|
| 2194 | | -#define I40E_AQ_PHY_DEBUG_RESET_EXTERNAL_SHIFT 2 |
|---|
| 2195 | | -#define I40E_AQ_PHY_DEBUG_RESET_EXTERNAL_MASK (0x03 << \ |
|---|
| 2196 | | - I40E_AQ_PHY_DEBUG_RESET_EXTERNAL_SHIFT) |
|---|
| 2197 | | -#define I40E_AQ_PHY_DEBUG_RESET_EXTERNAL_NONE 0x00 |
|---|
| 2198 | | -#define I40E_AQ_PHY_DEBUG_RESET_EXTERNAL_HARD 0x01 |
|---|
| 2199 | | -#define I40E_AQ_PHY_DEBUG_RESET_EXTERNAL_SOFT 0x02 |
|---|
| 2200 | 1808 | /* Disable link manageability on a single port */ |
|---|
| 2201 | 1809 | #define I40E_AQ_PHY_DEBUG_DISABLE_LINK_FW 0x10 |
|---|
| 2202 | 1810 | /* Disable link manageability on all ports */ |
|---|
| .. | .. |
|---|
| 2228 | 1836 | /* Get PHY Register command (0x0629) */ |
|---|
| 2229 | 1837 | struct i40e_aqc_phy_register_access { |
|---|
| 2230 | 1838 | u8 phy_interface; |
|---|
| 2231 | | -#define I40E_AQ_PHY_REG_ACCESS_INTERNAL 0 |
|---|
| 2232 | 1839 | #define I40E_AQ_PHY_REG_ACCESS_EXTERNAL 1 |
|---|
| 2233 | 1840 | #define I40E_AQ_PHY_REG_ACCESS_EXTERNAL_MODULE 2 |
|---|
| 2234 | 1841 | u8 dev_address; |
|---|
| 2235 | | - u8 reserved1[2]; |
|---|
| 1842 | + u8 cmd_flags; |
|---|
| 1843 | +#define I40E_AQ_PHY_REG_ACCESS_DONT_CHANGE_QSFP_PAGE 0x01 |
|---|
| 1844 | +#define I40E_AQ_PHY_REG_ACCESS_SET_MDIO_IF_NUMBER 0x02 |
|---|
| 1845 | +#define I40E_AQ_PHY_REG_ACCESS_MDIO_IF_NUMBER_SHIFT 2 |
|---|
| 1846 | +#define I40E_AQ_PHY_REG_ACCESS_MDIO_IF_NUMBER_MASK (0x3 << \ |
|---|
| 1847 | + I40E_AQ_PHY_REG_ACCESS_MDIO_IF_NUMBER_SHIFT) |
|---|
| 1848 | + u8 reserved1; |
|---|
| 2236 | 1849 | __le32 reg_address; |
|---|
| 2237 | 1850 | __le32 reg_value; |
|---|
| 2238 | 1851 | u8 reserved2[4]; |
|---|
| .. | .. |
|---|
| 2249 | 1862 | #define I40E_AQ_NVM_LAST_CMD 0x01 |
|---|
| 2250 | 1863 | #define I40E_AQ_NVM_REARRANGE_TO_FLAT 0x20 |
|---|
| 2251 | 1864 | #define I40E_AQ_NVM_REARRANGE_TO_STRUCT 0x40 |
|---|
| 2252 | | -#define I40E_AQ_NVM_FLASH_ONLY 0x80 |
|---|
| 2253 | 1865 | #define I40E_AQ_NVM_PRESERVATION_FLAGS_SHIFT 1 |
|---|
| 2254 | | -#define I40E_AQ_NVM_PRESERVATION_FLAGS_MASK 0x03 |
|---|
| 2255 | 1866 | #define I40E_AQ_NVM_PRESERVATION_FLAGS_SELECTED 0x03 |
|---|
| 2256 | 1867 | #define I40E_AQ_NVM_PRESERVATION_FLAGS_ALL 0x01 |
|---|
| 2257 | 1868 | u8 module_pointer; |
|---|
| .. | .. |
|---|
| 2266 | 1877 | /* NVM Config Read (indirect 0x0704) */ |
|---|
| 2267 | 1878 | struct i40e_aqc_nvm_config_read { |
|---|
| 2268 | 1879 | __le16 cmd_flags; |
|---|
| 2269 | | -#define I40E_AQ_ANVM_SINGLE_OR_MULTIPLE_FEATURES_MASK 1 |
|---|
| 2270 | | -#define I40E_AQ_ANVM_READ_SINGLE_FEATURE 0 |
|---|
| 2271 | | -#define I40E_AQ_ANVM_READ_MULTIPLE_FEATURES 1 |
|---|
| 2272 | 1880 | __le16 element_count; |
|---|
| 2273 | 1881 | __le16 element_id; /* Feature/field ID */ |
|---|
| 2274 | 1882 | __le16 element_id_msw; /* MSWord of field ID */ |
|---|
| .. | .. |
|---|
| 2290 | 1898 | I40E_CHECK_CMD_LENGTH(i40e_aqc_nvm_config_write); |
|---|
| 2291 | 1899 | |
|---|
| 2292 | 1900 | /* Used for 0x0704 as well as for 0x0705 commands */ |
|---|
| 2293 | | -#define I40E_AQ_ANVM_FEATURE_OR_IMMEDIATE_SHIFT 1 |
|---|
| 2294 | | -#define I40E_AQ_ANVM_FEATURE_OR_IMMEDIATE_MASK \ |
|---|
| 2295 | | - BIT(I40E_AQ_ANVM_FEATURE_OR_IMMEDIATE_SHIFT) |
|---|
| 2296 | | -#define I40E_AQ_ANVM_FEATURE 0 |
|---|
| 2297 | | -#define I40E_AQ_ANVM_IMMEDIATE_FIELD BIT(FEATURE_OR_IMMEDIATE_SHIFT) |
|---|
| 2298 | 1901 | struct i40e_aqc_nvm_config_data_feature { |
|---|
| 2299 | 1902 | __le16 feature_id; |
|---|
| 2300 | | -#define I40E_AQ_ANVM_FEATURE_OPTION_OEM_ONLY 0x01 |
|---|
| 2301 | | -#define I40E_AQ_ANVM_FEATURE_OPTION_DWORD_MAP 0x08 |
|---|
| 2302 | | -#define I40E_AQ_ANVM_FEATURE_OPTION_POR_CSR 0x10 |
|---|
| 2303 | 1903 | __le16 feature_options; |
|---|
| 2304 | 1904 | __le16 feature_selection; |
|---|
| 2305 | 1905 | }; |
|---|
| .. | .. |
|---|
| 2319 | 1919 | * no command data struct used |
|---|
| 2320 | 1920 | */ |
|---|
| 2321 | 1921 | struct i40e_aqc_nvm_oem_post_update { |
|---|
| 2322 | | -#define I40E_AQ_NVM_OEM_POST_UPDATE_EXTERNAL_DATA 0x01 |
|---|
| 2323 | 1922 | u8 sel_data; |
|---|
| 2324 | 1923 | u8 reserved[7]; |
|---|
| 2325 | 1924 | }; |
|---|
| .. | .. |
|---|
| 2341 | 1940 | */ |
|---|
| 2342 | 1941 | struct i40e_aqc_thermal_sensor { |
|---|
| 2343 | 1942 | u8 sensor_action; |
|---|
| 2344 | | -#define I40E_AQ_THERMAL_SENSOR_READ_CONFIG 0 |
|---|
| 2345 | | -#define I40E_AQ_THERMAL_SENSOR_SET_CONFIG 1 |
|---|
| 2346 | | -#define I40E_AQ_THERMAL_SENSOR_READ_TEMP 2 |
|---|
| 2347 | 1943 | u8 reserved[7]; |
|---|
| 2348 | 1944 | __le32 addr_high; |
|---|
| 2349 | 1945 | __le32 addr_low; |
|---|
| .. | .. |
|---|
| 2396 | 1992 | */ |
|---|
| 2397 | 1993 | struct i40e_aqc_alternate_write_done { |
|---|
| 2398 | 1994 | __le16 cmd_flags; |
|---|
| 2399 | | -#define I40E_AQ_ALTERNATE_MODE_BIOS_MASK 1 |
|---|
| 2400 | | -#define I40E_AQ_ALTERNATE_MODE_BIOS_LEGACY 0 |
|---|
| 2401 | | -#define I40E_AQ_ALTERNATE_MODE_BIOS_UEFI 1 |
|---|
| 2402 | | -#define I40E_AQ_ALTERNATE_RESET_NEEDED 2 |
|---|
| 2403 | 1995 | u8 reserved[14]; |
|---|
| 2404 | 1996 | }; |
|---|
| 2405 | 1997 | |
|---|
| .. | .. |
|---|
| 2408 | 2000 | /* Set OEM mode (direct 0x0905) */ |
|---|
| 2409 | 2001 | struct i40e_aqc_alternate_set_mode { |
|---|
| 2410 | 2002 | __le32 mode; |
|---|
| 2411 | | -#define I40E_AQ_ALTERNATE_MODE_NONE 0 |
|---|
| 2412 | | -#define I40E_AQ_ALTERNATE_MODE_OEM 1 |
|---|
| 2413 | 2003 | u8 reserved[12]; |
|---|
| 2414 | 2004 | }; |
|---|
| 2415 | 2005 | |
|---|
| .. | .. |
|---|
| 2435 | 2025 | #define I40E_AQ_LLDP_MIB_TYPE_MASK 0x3 |
|---|
| 2436 | 2026 | #define I40E_AQ_LLDP_MIB_LOCAL 0x0 |
|---|
| 2437 | 2027 | #define I40E_AQ_LLDP_MIB_REMOTE 0x1 |
|---|
| 2438 | | -#define I40E_AQ_LLDP_MIB_LOCAL_AND_REMOTE 0x2 |
|---|
| 2439 | 2028 | #define I40E_AQ_LLDP_BRIDGE_TYPE_MASK 0xC |
|---|
| 2440 | 2029 | #define I40E_AQ_LLDP_BRIDGE_TYPE_SHIFT 0x2 |
|---|
| 2441 | 2030 | #define I40E_AQ_LLDP_BRIDGE_TYPE_NEAREST_BRIDGE 0x0 |
|---|
| 2442 | | -#define I40E_AQ_LLDP_BRIDGE_TYPE_NON_TPMR 0x1 |
|---|
| 2443 | | -#define I40E_AQ_LLDP_TX_SHIFT 0x4 |
|---|
| 2444 | | -#define I40E_AQ_LLDP_TX_MASK (0x03 << I40E_AQ_LLDP_TX_SHIFT) |
|---|
| 2445 | 2031 | /* TX pause flags use I40E_AQ_LINK_TX_* above */ |
|---|
| 2446 | 2032 | __le16 local_len; |
|---|
| 2447 | 2033 | __le16 remote_len; |
|---|
| .. | .. |
|---|
| 2457 | 2043 | */ |
|---|
| 2458 | 2044 | struct i40e_aqc_lldp_update_mib { |
|---|
| 2459 | 2045 | u8 command; |
|---|
| 2460 | | -#define I40E_AQ_LLDP_MIB_UPDATE_ENABLE 0x0 |
|---|
| 2461 | 2046 | #define I40E_AQ_LLDP_MIB_UPDATE_DISABLE 0x1 |
|---|
| 2462 | 2047 | u8 reserved[7]; |
|---|
| 2463 | 2048 | __le32 addr_high; |
|---|
| .. | .. |
|---|
| 2496 | 2081 | /* Stop LLDP (direct 0x0A05) */ |
|---|
| 2497 | 2082 | struct i40e_aqc_lldp_stop { |
|---|
| 2498 | 2083 | u8 command; |
|---|
| 2499 | | -#define I40E_AQ_LLDP_AGENT_STOP 0x0 |
|---|
| 2500 | | -#define I40E_AQ_LLDP_AGENT_SHUTDOWN 0x1 |
|---|
| 2084 | +#define I40E_AQ_LLDP_AGENT_SHUTDOWN 0x1 |
|---|
| 2085 | +#define I40E_AQ_LLDP_AGENT_STOP_PERSIST 0x2 |
|---|
| 2501 | 2086 | u8 reserved[15]; |
|---|
| 2502 | 2087 | }; |
|---|
| 2503 | 2088 | |
|---|
| 2504 | 2089 | I40E_CHECK_CMD_LENGTH(i40e_aqc_lldp_stop); |
|---|
| 2505 | 2090 | |
|---|
| 2506 | 2091 | /* Start LLDP (direct 0x0A06) */ |
|---|
| 2507 | | - |
|---|
| 2508 | 2092 | struct i40e_aqc_lldp_start { |
|---|
| 2509 | 2093 | u8 command; |
|---|
| 2510 | | -#define I40E_AQ_LLDP_AGENT_START 0x1 |
|---|
| 2094 | +#define I40E_AQ_LLDP_AGENT_START 0x1 |
|---|
| 2095 | +#define I40E_AQ_LLDP_AGENT_START_PERSIST 0x2 |
|---|
| 2511 | 2096 | u8 reserved[15]; |
|---|
| 2512 | 2097 | }; |
|---|
| 2513 | 2098 | |
|---|
| .. | .. |
|---|
| 2601 | 2186 | * Used to replace the local MIB of a given LLDP agent. e.g. DCBx |
|---|
| 2602 | 2187 | */ |
|---|
| 2603 | 2188 | struct i40e_aqc_lldp_set_local_mib { |
|---|
| 2604 | | -#define SET_LOCAL_MIB_AC_TYPE_DCBX_SHIFT 0 |
|---|
| 2605 | | -#define SET_LOCAL_MIB_AC_TYPE_DCBX_MASK BIT(SET_LOCAL_MIB_AC_TYPE_DCBX_SHIFT) |
|---|
| 2606 | | -#define SET_LOCAL_MIB_AC_TYPE_LOCAL_MIB 0x0 |
|---|
| 2607 | | -#define SET_LOCAL_MIB_AC_TYPE_NON_WILLING_APPS_SHIFT (1) |
|---|
| 2608 | | -#define SET_LOCAL_MIB_AC_TYPE_NON_WILLING_APPS_MASK \ |
|---|
| 2609 | | - BIT(SET_LOCAL_MIB_AC_TYPE_NON_WILLING_APPS_SHIFT) |
|---|
| 2610 | | -#define SET_LOCAL_MIB_AC_TYPE_NON_WILLING_APPS 0x1 |
|---|
| 2611 | 2189 | u8 type; |
|---|
| 2612 | 2190 | u8 reserved0; |
|---|
| 2613 | 2191 | __le16 length; |
|---|
| .. | .. |
|---|
| 2622 | 2200 | * Used for stopping/starting specific LLDP agent. e.g. DCBx |
|---|
| 2623 | 2201 | */ |
|---|
| 2624 | 2202 | struct i40e_aqc_lldp_stop_start_specific_agent { |
|---|
| 2625 | | -#define I40E_AQC_START_SPECIFIC_AGENT_SHIFT 0 |
|---|
| 2626 | | -#define I40E_AQC_START_SPECIFIC_AGENT_MASK \ |
|---|
| 2627 | | - BIT(I40E_AQC_START_SPECIFIC_AGENT_SHIFT) |
|---|
| 2628 | 2203 | u8 command; |
|---|
| 2629 | 2204 | u8 reserved[15]; |
|---|
| 2630 | 2205 | }; |
|---|
| 2631 | 2206 | |
|---|
| 2632 | 2207 | I40E_CHECK_CMD_LENGTH(i40e_aqc_lldp_stop_start_specific_agent); |
|---|
| 2208 | + |
|---|
| 2209 | +/* Restore LLDP Agent factory settings (direct 0x0A0A) */ |
|---|
| 2210 | +struct i40e_aqc_lldp_restore { |
|---|
| 2211 | + u8 command; |
|---|
| 2212 | +#define I40E_AQ_LLDP_AGENT_RESTORE 0x1 |
|---|
| 2213 | + u8 reserved[15]; |
|---|
| 2214 | +}; |
|---|
| 2215 | + |
|---|
| 2216 | +I40E_CHECK_CMD_LENGTH(i40e_aqc_lldp_restore); |
|---|
| 2633 | 2217 | |
|---|
| 2634 | 2218 | /* Add Udp Tunnel command and completion (direct 0x0B00) */ |
|---|
| 2635 | 2219 | struct i40e_aqc_add_udp_tunnel { |
|---|
| .. | .. |
|---|
| 2638 | 2222 | u8 protocol_type; |
|---|
| 2639 | 2223 | #define I40E_AQC_TUNNEL_TYPE_VXLAN 0x00 |
|---|
| 2640 | 2224 | #define I40E_AQC_TUNNEL_TYPE_NGE 0x01 |
|---|
| 2641 | | -#define I40E_AQC_TUNNEL_TYPE_TEREDO 0x10 |
|---|
| 2642 | | -#define I40E_AQC_TUNNEL_TYPE_VXLAN_GPE 0x11 |
|---|
| 2643 | 2225 | u8 reserved1[10]; |
|---|
| 2644 | 2226 | }; |
|---|
| 2645 | 2227 | |
|---|
| .. | .. |
|---|
| 2649 | 2231 | __le16 udp_port; |
|---|
| 2650 | 2232 | u8 filter_entry_index; |
|---|
| 2651 | 2233 | u8 multiple_pfs; |
|---|
| 2652 | | -#define I40E_AQC_SINGLE_PF 0x0 |
|---|
| 2653 | | -#define I40E_AQC_MULTIPLE_PFS 0x1 |
|---|
| 2654 | 2234 | u8 total_filters; |
|---|
| 2655 | 2235 | u8 reserved[11]; |
|---|
| 2656 | 2236 | }; |
|---|
| .. | .. |
|---|
| 2723 | 2303 | u8 key1_len; /* 0 to 15 */ |
|---|
| 2724 | 2304 | u8 key2_len; /* 0 to 15 */ |
|---|
| 2725 | 2305 | u8 flags; |
|---|
| 2726 | | -#define I40E_AQC_TUNNEL_KEY_STRUCT_OVERRIDE 0x01 |
|---|
| 2727 | | -/* response flags */ |
|---|
| 2728 | | -#define I40E_AQC_TUNNEL_KEY_STRUCT_SUCCESS 0x01 |
|---|
| 2729 | | -#define I40E_AQC_TUNNEL_KEY_STRUCT_MODIFIED 0x02 |
|---|
| 2730 | | -#define I40E_AQC_TUNNEL_KEY_STRUCT_OVERRIDDEN 0x03 |
|---|
| 2731 | 2306 | u8 network_key_index; |
|---|
| 2732 | | -#define I40E_AQC_NETWORK_KEY_INDEX_VXLAN 0x0 |
|---|
| 2733 | | -#define I40E_AQC_NETWORK_KEY_INDEX_NGE 0x1 |
|---|
| 2734 | | -#define I40E_AQC_NETWORK_KEY_INDEX_FLEX_MAC_IN_UDP 0x2 |
|---|
| 2735 | | -#define I40E_AQC_NETWORK_KEY_INDEX_GRE 0x3 |
|---|
| 2736 | 2307 | u8 reserved[10]; |
|---|
| 2737 | 2308 | }; |
|---|
| 2738 | 2309 | |
|---|
| .. | .. |
|---|
| 2741 | 2312 | /* OEM mode commands (direct 0xFE0x) */ |
|---|
| 2742 | 2313 | struct i40e_aqc_oem_param_change { |
|---|
| 2743 | 2314 | __le32 param_type; |
|---|
| 2744 | | -#define I40E_AQ_OEM_PARAM_TYPE_PF_CTL 0 |
|---|
| 2745 | | -#define I40E_AQ_OEM_PARAM_TYPE_BW_CTL 1 |
|---|
| 2746 | | -#define I40E_AQ_OEM_PARAM_MAC 2 |
|---|
| 2747 | 2315 | __le32 param_value1; |
|---|
| 2748 | 2316 | __le16 param_value2; |
|---|
| 2749 | 2317 | u8 reserved[6]; |
|---|
| .. | .. |
|---|
| 2753 | 2321 | |
|---|
| 2754 | 2322 | struct i40e_aqc_oem_state_change { |
|---|
| 2755 | 2323 | __le32 state; |
|---|
| 2756 | | -#define I40E_AQ_OEM_STATE_LINK_DOWN 0x0 |
|---|
| 2757 | | -#define I40E_AQ_OEM_STATE_LINK_UP 0x1 |
|---|
| 2758 | 2324 | u8 reserved[12]; |
|---|
| 2759 | 2325 | }; |
|---|
| 2760 | 2326 | |
|---|
| .. | .. |
|---|
| 2790 | 2356 | |
|---|
| 2791 | 2357 | struct i40e_acq_set_test_mode { |
|---|
| 2792 | 2358 | u8 mode; |
|---|
| 2793 | | -#define I40E_AQ_TEST_PARTIAL 0 |
|---|
| 2794 | | -#define I40E_AQ_TEST_FULL 1 |
|---|
| 2795 | | -#define I40E_AQ_TEST_NVM 2 |
|---|
| 2796 | 2359 | u8 reserved[3]; |
|---|
| 2797 | 2360 | u8 command; |
|---|
| 2798 | | -#define I40E_AQ_TEST_OPEN 0 |
|---|
| 2799 | | -#define I40E_AQ_TEST_CLOSE 1 |
|---|
| 2800 | | -#define I40E_AQ_TEST_INC 2 |
|---|
| 2801 | 2361 | u8 reserved2[3]; |
|---|
| 2802 | 2362 | __le32 address_high; |
|---|
| 2803 | 2363 | __le32 address_low; |
|---|
| .. | .. |
|---|
| 2838 | 2398 | I40E_CHECK_CMD_LENGTH(i40e_aqc_debug_modify_reg); |
|---|
| 2839 | 2399 | |
|---|
| 2840 | 2400 | /* dump internal data (0xFF08, indirect) */ |
|---|
| 2841 | | - |
|---|
| 2842 | | -#define I40E_AQ_CLUSTER_ID_AUX 0 |
|---|
| 2843 | | -#define I40E_AQ_CLUSTER_ID_SWITCH_FLU 1 |
|---|
| 2844 | | -#define I40E_AQ_CLUSTER_ID_TXSCHED 2 |
|---|
| 2845 | | -#define I40E_AQ_CLUSTER_ID_HMC 3 |
|---|
| 2846 | | -#define I40E_AQ_CLUSTER_ID_MAC0 4 |
|---|
| 2847 | | -#define I40E_AQ_CLUSTER_ID_MAC1 5 |
|---|
| 2848 | | -#define I40E_AQ_CLUSTER_ID_MAC2 6 |
|---|
| 2849 | | -#define I40E_AQ_CLUSTER_ID_MAC3 7 |
|---|
| 2850 | | -#define I40E_AQ_CLUSTER_ID_DCB 8 |
|---|
| 2851 | | -#define I40E_AQ_CLUSTER_ID_EMP_MEM 9 |
|---|
| 2852 | | -#define I40E_AQ_CLUSTER_ID_PKT_BUF 10 |
|---|
| 2853 | | -#define I40E_AQ_CLUSTER_ID_ALTRAM 11 |
|---|
| 2854 | | - |
|---|
| 2855 | 2401 | struct i40e_aqc_debug_dump_internals { |
|---|
| 2856 | 2402 | u8 cluster_id; |
|---|
| 2857 | 2403 | u8 table_id; |
|---|