]> git.baikalelectronics.ru Git - kernel.git/commit
RDMA/siw: Fix reporting vendor_part_id
authorKamal Heib <kamalheib1@gmail.com>
Tue, 7 Jul 2020 13:09:31 +0000 (16:09 +0300)
committerJason Gunthorpe <jgg@nvidia.com>
Wed, 8 Jul 2020 12:24:45 +0000 (09:24 -0300)
commitfca78617afa6f9511bba73cb392ff772f81938e2
tree528dd7b4b54d6b683f602c8423315d8afdf8bd1d
parent2d1e63753fc82a1d034fb74b67a5eb3b37638e0a
RDMA/siw: Fix reporting vendor_part_id

Move the initialization of the vendor_part_id to be before calling
ib_register_device(), this is needed because the query_device() callback
is called from the context of ib_register_device() before initializing the
vendor_part_id, so the reported value is wrong.

Fixes: f8c4999b094d ("rdma/siw: network and RDMA core interface")
Link: https://lore.kernel.org/r/20200707130931.444724-1-kamalheib1@gmail.com
Signed-off-by: Kamal Heib <kamalheib1@gmail.com>
Reviewed-by: Bernard Metzler <bmt@zurich.ibm.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
drivers/infiniband/sw/siw/siw_main.c