]> git.baikalelectronics.ru Git - kernel.git/commit
IB/hfi1: Prevent LNI out of sync by resetting host interface version
authorSebastian Sanchez <sebastian.sanchez@intel.com>
Mon, 2 Oct 2017 18:04:26 +0000 (11:04 -0700)
committerDoug Ledford <dledford@redhat.com>
Wed, 4 Oct 2017 19:39:45 +0000 (15:39 -0400)
commit713c11ee34ff63e94f64ddb46da8e6d5842d1a14
tree8550683b40bb201366790d1cd611608313301f30
parentb6a840ea3d441b1d6dc29e4e97a561f5e55d3200
IB/hfi1: Prevent LNI out of sync by resetting host interface version

When the link is disabled and re-enabled, the host version bit is not
set again, so the firmware behaves as though it’s interacting with an
old driver. This causes LNI to get out of sync. The host version bit
needs to be set at load_8051_firmware() and _dc_start(). Currently, it's
only set at load_8051_firmware().

Create a common function to set the bit with the intent to make the code
more maintainable in the future, set the host version bit at _dc_start()
and modify the 8051 command API to prevent a deadlock as _dc_start() is
already holding the dc8051 lock.

Fixes: 79186686a226 ("IB/hfi1: Always perform offline transition")
Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com>
Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com>
Signed-off-by: Sebastian Sanchez <sebastian.sanchez@intel.com>
Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/hw/hfi1/chip.c
drivers/infiniband/hw/hfi1/chip.h
drivers/infiniband/hw/hfi1/firmware.c