be2net: Change f/w command versions for Lancer
authorPadmanabh Ratnakar <padmanabh.ratnakar@emulex.com>
Mon, 7 Mar 2011 03:08:52 +0000 (03:08 +0000)
committerDavid S. Miller <davem@davemloft.net>
Mon, 7 Mar 2011 23:26:57 +0000 (15:26 -0800)
Change f/w command versions for Lancer

Signed-off-by: Padmanabh Ratnakar <padmanabh.ratnakar@emulex.com>
Signed-off-by: Sathya Perla <sathya.perla@emulex.com>
Signed-off-by: Subramanian Seetharaman <subbu.seetharaman@emulex.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/benet/be_cmds.c
drivers/net/benet/be_cmds.h

index 1822ecdadc7e1b23b96b00bf6c0d9c1c5683a389..cc3a235475bc0a96ac52b048f615eb54821f1ce0 100644 (file)
@@ -726,7 +726,7 @@ int be_cmd_cq_create(struct be_adapter *adapter,
 
        req->num_pages =  cpu_to_le16(PAGES_4K_SPANNED(q_mem->va, q_mem->size));
        if (lancer_chip(adapter)) {
-               req->hdr.version = 1;
+               req->hdr.version = 2;
                req->page_size = 1; /* 1 for 4K */
                AMAP_SET_BITS(struct amap_cq_context_lancer, coalescwm, ctxt,
                                                                coalesce_wm);
@@ -862,6 +862,12 @@ int be_cmd_txq_create(struct be_adapter *adapter,
        be_cmd_hdr_prepare(&req->hdr, CMD_SUBSYSTEM_ETH, OPCODE_ETH_TX_CREATE,
                sizeof(*req));
 
+       if (lancer_chip(adapter)) {
+               req->hdr.version = 1;
+               AMAP_SET_BITS(struct amap_tx_context, if_id, ctxt,
+                                       adapter->if_handle);
+       }
+
        req->num_pages = PAGES_4K_SPANNED(q_mem->va, q_mem->size);
        req->ulp_num = BE_ULP1_NUM;
        req->type = BE_ETH_TX_RING_TYPE_STANDARD;
index 93e5768fc70583e05129b314396da2c44a904584..5bdaa22dee80333e8b23941acc0181dd655d3fb6 100644 (file)
@@ -430,7 +430,7 @@ struct be_cmd_resp_mcc_create {
 /* Pseudo amap definition in which each bit of the actual structure is defined
  * as a byte: used to calculate offset/shift/mask of each field */
 struct amap_tx_context {
-       u8 rsvd0[16];           /* dword 0 */
+       u8 if_id[16];           /* dword 0 */
        u8 tx_ring_size[4];     /* dword 0 */
        u8 rsvd1[26];           /* dword 0 */
        u8 pci_func_id[8];      /* dword 1 */