diff options
author | oulijun <oulijun@huawei.com> | 2018-05-04 04:57:06 +0200 |
---|---|---|
committer | Doug Ledford <dledford@redhat.com> | 2018-05-09 16:45:18 +0200 |
commit | ad18e20ba2887e221e903d311f4c9a1586eacffb (patch) | |
tree | 30eb6ac8c0103cd41eb5f936a603ef17da2b4d4f /drivers | |
parent | RDMA/hns: Load the RoCE dirver automatically (diff) | |
download | linux-ad18e20ba2887e221e903d311f4c9a1586eacffb.tar.xz linux-ad18e20ba2887e221e903d311f4c9a1586eacffb.zip |
RDMA/hns: Update convert function of endian format
Because the sys_image_guid of ib_device_attr structure is __be64, it
need to use cpu_to_be64 for converting.
Signed-off-by: Lijun Ou <oulijun@huawei.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/infiniband/hw/hns/hns_roce_main.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/infiniband/hw/hns/hns_roce_main.c b/drivers/infiniband/hw/hns/hns_roce_main.c index 9d48bc07a9e6..96fb6a9ed93c 100644 --- a/drivers/infiniband/hw/hns/hns_roce_main.c +++ b/drivers/infiniband/hw/hns/hns_roce_main.c @@ -199,7 +199,7 @@ static int hns_roce_query_device(struct ib_device *ib_dev, memset(props, 0, sizeof(*props)); - props->sys_image_guid = cpu_to_be32(hr_dev->sys_image_guid); + props->sys_image_guid = cpu_to_be64(hr_dev->sys_image_guid); props->max_mr_size = (u64)(~(0ULL)); props->page_size_cap = hr_dev->caps.page_size_cap; props->vendor_id = hr_dev->vendor_id; |