IB/iser: Remove a redundant always-false condition
authorSagi Grimberg <sagig@mellanox.com>
Thu, 6 Aug 2015 15:32:51 +0000 (18:32 +0300)
committerDoug Ledford <dledford@redhat.com>
Sun, 30 Aug 2015 22:12:28 +0000 (18:12 -0400)
We always call iser_initialize_task_headers() and set
the header tx_sg.lkey to the device mr lkey, so no
point in checking it in iser_create_send_desc().

Signed-off-by: Sagi Grimberg <sagig@mellanox.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/ulp/iser/iser_initiator.c

index 0a47f42fec24efd0bcc986911e6bd40d28a1da10..9ff6dec6f8be068966976e5bb8ded8c141a802c1 100644 (file)
@@ -170,13 +170,7 @@ static void iser_create_send_desc(struct iser_conn *iser_conn,
 
        memset(&tx_desc->iser_header, 0, sizeof(struct iser_hdr));
        tx_desc->iser_header.flags = ISER_VER;
-
        tx_desc->num_sge = 1;
-
-       if (tx_desc->tx_sg[0].lkey != device->mr->lkey) {
-               tx_desc->tx_sg[0].lkey = device->mr->lkey;
-               iser_dbg("sdesc %p lkey mismatch, fixing\n", tx_desc);
-       }
 }
 
 static void iser_free_login_buf(struct iser_conn *iser_conn)