]> git.baikalelectronics.ru Git - kernel.git/commit
IB/hfi1: Return invalid field for non-QSFP CableInfo queries
authorEaswar Hariharan <easwar.hariharan@intel.com>
Tue, 16 Aug 2016 20:25:34 +0000 (13:25 -0700)
committerDoug Ledford <dledford@redhat.com>
Mon, 22 Aug 2016 19:00:42 +0000 (15:00 -0400)
commit9e642addcf3f685a3981b10c5d9c2eb3e250827e
tree775ef2974f0e86c9e78f6ea7ad6f2771b891ffc0
parented6e6f641fd3fa5059aa5078ec3687e2167dc296
IB/hfi1: Return invalid field for non-QSFP CableInfo queries

The driver does not check if the CableInfo query is supported for the
port type. Return early if CableInfo is not supported for the port type,
making compliance with the specification explicit and preventing lower
level code from potentially doing the wrong thing if the query is not
supported for the hardware implementation.

Reviewed-by: Ira Weiny <ira.weiny@intel.com>
Signed-off-by: Easwar Hariharan <easwar.hariharan@intel.com>
Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/hw/hfi1/mad.c