IB/hfi1: Cleanup UD packet handler.
authorDasaratharaman Chandramouli <dasaratharaman.chandramouli@intel.com>
Mon, 25 Jul 2016 20:40:28 +0000 (13:40 -0700)
committerDoug Ledford <dledford@redhat.com>
Tue, 2 Aug 2016 20:00:58 +0000 (16:00 -0400)
commit89c057cae4deaeab94c652c06b855af2bb754f50
tree372ea875cef33b9e3a832169793a2131ff7c28c3
parentd4d602e9a3035d039befdd37df5213b430948f28
IB/hfi1: Cleanup UD packet handler.

Cleanup hfi1_ud_rcv to not have to look at the packet
header fields multiple times. The fields are looked up
once and used throughout the function. Also fix sc
computation when validating MAD packets.

Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com>
Reviewed-by: Dean Luick <dean.luick@intel.com>
Reviewed-by: Ira Weiny <ira.weiny@intel.com>
Signed-off-by: Dasaratharaman Chandramouli <dasaratharaman.chandramouli@intel.com>
Signed-off-by: Don Hiatt <don.hiatt@intel.com>
Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/hw/hfi1/ud.c