]> git.baikalelectronics.ru Git - kernel.git/commit
mlx5_core: Adjust hca_cap.uar_page_sz to conform to Connect-IB spec
authorMoshe Lazer <moshel@mellanox.com>
Wed, 10 Jul 2013 11:31:03 +0000 (14:31 +0300)
committerRoland Dreier <roland@purestorage.com>
Thu, 11 Jul 2013 23:45:08 +0000 (16:45 -0700)
commit53a683952b9e3df796f0fc14526b05663a5bb941
tree93867e6ea58c82b182c073b1b17e1e4a12b65762
parent8d8a30c89633a2c9c836bd1740286d189a82898d
mlx5_core: Adjust hca_cap.uar_page_sz to conform to Connect-IB spec

Sparse reported an endianness bug in the assignment to hca_cap.uar_page_sz.

Fix the declaration of this field to be __be16 (which is what is in
the firmware spec), renaming the field to log_uar_pg_size to conform
to the spec, which fixes the endianness bug reported by sparse.

Reported-by: Fengguang Wu <fengguang.wu@intel.com>
Signed-off-by: Moshe Lazer <moshel@mellanox.com>
Signed-off-by: Or Gerlitz <ogerlitz@mellanox.com>
Signed-off-by: Roland Dreier <roland@purestorage.com>
drivers/net/ethernet/mellanox/mlx5/core/main.c
include/linux/mlx5/device.h