RDMA/core: create struct ib_port_cache
authorJack Wang <jinpu.wang@profitbricks.com>
Tue, 17 Jan 2017 09:11:12 +0000 (10:11 +0100)
committerDoug Ledford <dledford@redhat.com>
Tue, 24 Jan 2017 21:20:37 +0000 (16:20 -0500)
commit21d6454a392d552c7e845f39884f7cf86f9426b9
treec8d266a076d56d53d02e55a13faac61917c53de3
parentdfc0e5550664a727a59921db7d9e7a41c21d03bb
RDMA/core: create struct ib_port_cache

As Jason suggested, we have 4 elements for per port arrays,
it's better to have a separate structure to represent them.

It simplifies code a bit, ~ 30 lines of code less :)

Signed-off-by: Jack Wang <jinpu.wang@profitbricks.com>
Reviewed-by: Michael Wang <yun.wang@profitbricks.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/core/cache.c
include/rdma/ib_verbs.h