summaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/hw/hfi1/firmware.c
diff options
context:
space:
mode:
authorMichael J. Ruhl2017-03-21 01:25:48 +0100
committerDoug Ledford2017-04-05 20:45:09 +0200
commit5e6e94244bba1eb5be3c5ac9ceb3af87280b56d1 (patch)
tree62307f74ec02c078a58fd3da4d30312e04ada389 /drivers/infiniband/hw/hfi1/firmware.c
parentIB/hfi1: Check for QSFP presence before attempting reads (diff)
downloadkernel-qcow2-linux-5e6e94244bba1eb5be3c5ac9ceb3af87280b56d1.tar.gz
kernel-qcow2-linux-5e6e94244bba1eb5be3c5ac9ceb3af87280b56d1.tar.xz
kernel-qcow2-linux-5e6e94244bba1eb5be3c5ac9ceb3af87280b56d1.zip
IB/hfi1: Add a patch value to the firmware version string
The HFI firmware now includes a patch level in its version. Updating the necessary code to include the patch version in the firmware string. Reviewed-by: Easwar Hariharan <easwar.hariharan@intel.com> Signed-off-by: Michael J. Ruhl <michael.j.ruhl@intel.com> Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com> Signed-off-by: Doug Ledford <dledford@redhat.com>
Diffstat (limited to 'drivers/infiniband/hw/hfi1/firmware.c')
-rw-r--r--drivers/infiniband/hw/hfi1/firmware.c14
1 files changed, 8 insertions, 6 deletions
diff --git a/drivers/infiniband/hw/hfi1/firmware.c b/drivers/infiniband/hw/hfi1/firmware.c
index 0dd50cdb039a..4042c11b2742 100644
--- a/drivers/infiniband/hw/hfi1/firmware.c
+++ b/drivers/infiniband/hw/hfi1/firmware.c
@@ -1,5 +1,5 @@
/*
- * Copyright(c) 2015, 2016 Intel Corporation.
+ * Copyright(c) 2015 - 2017 Intel Corporation.
*
* This file is provided under a dual BSD/GPLv2 license. When using or
* redistributing this file, you may do so under either license.
@@ -1004,7 +1004,9 @@ static int load_8051_firmware(struct hfi1_devdata *dd,
{
u64 reg;
int ret;
- u8 ver_a, ver_b;
+ u8 ver_major;
+ u8 ver_minor;
+ u8 ver_patch;
/*
* DC Reset sequence
@@ -1073,10 +1075,10 @@ static int load_8051_firmware(struct hfi1_devdata *dd,
return -ETIMEDOUT;
}
- read_misc_status(dd, &ver_a, &ver_b);
- dd_dev_info(dd, "8051 firmware version %d.%d\n",
- (int)ver_b, (int)ver_a);
- dd->dc8051_ver = dc8051_ver(ver_b, ver_a);
+ read_misc_status(dd, &ver_major, &ver_minor, &ver_patch);
+ dd_dev_info(dd, "8051 firmware version %d.%d.%d\n",
+ (int)ver_major, (int)ver_minor, (int)ver_patch);
+ dd->dc8051_ver = dc8051_ver(ver_major, ver_minor, ver_patch);
return 0;
}