提交 0e4562da 编写于 作者: C Chien Tung 提交者: Roland Dreier

RDMA/nes: Fix fw_ver in /sys

/sys/class/infiniband/nes?/fw_ver is not displaying firmware version
properly (it shows 0.0.0 with the current code).  Fill in the correct
firmware version number.
Signed-off-by: NChien Tung <chien.tin.tung@intel.com>
Signed-off-by: NRoland Dreier <rolandd@cisco.com>
上级 92322377
......@@ -2808,10 +2808,9 @@ static ssize_t show_fw_ver(struct device *dev, struct device_attribute *attr,
struct nes_vnic *nesvnic = nesibdev->nesvnic;
nes_debug(NES_DBG_INIT, "\n");
return sprintf(buf, "%x.%x.%x\n",
(int)(nesvnic->nesdev->nesadapter->fw_ver >> 32),
(int)(nesvnic->nesdev->nesadapter->fw_ver >> 16) & 0xffff,
(int)(nesvnic->nesdev->nesadapter->fw_ver & 0xffff));
return sprintf(buf, "%u.%u\n",
(nesvnic->nesdev->nesadapter->firmware_version >> 16),
(nesvnic->nesdev->nesadapter->firmware_version & 0x000000ff));
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册