]> git.baikalelectronics.ru Git - kernel.git/commit
IB/mlx5: Limit query HCA clock
authorNoa Osherovich <noaos@mellanox.com>
Sat, 4 Jun 2016 12:15:31 +0000 (15:15 +0300)
committerDoug Ledford <dledford@redhat.com>
Tue, 7 Jun 2016 14:03:49 +0000 (10:03 -0400)
commit8b3161be1dafcb3d1273a24f9bdbbd7cfb500073
treec6a46c036b9f4d0bc93c4383da96864b20e01728
parentec61b858b340a7e27cb9ec3a5560257979c93c93
IB/mlx5: Limit query HCA clock

When PAGE_SIZE is larger than 4K, the user shouldn't be able to query
the HCA core clock. This counter is within 4KB boundary and the
user-space shall not read information that's after this boundary.

Fixes: f5a02fa0d8a95 ('IB/mlx5: Add hca_core_clock_offset to...')
Signed-off-by: Majd Dibbiny <majd@mellanox.com>
Signed-off-by: Noa Osherovich <noaos@mellanox.com>
Signed-off-by: Leon Romanovsky <leon@kernel.org>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/hw/mlx5/main.c