linux-stable/drivers/infiniband/hw
Matan Barak 6cbac1e4cd IB/mlx5: Allow mapping the free running counter on PROT_EXEC
The current mlx5 code disallows mapping the free running counter of
mlx5 based hardwares when PROT_EXEC is set.
Although this behaviour is correct, Linux does add an implicit VM_EXEC
to the vm_flags if the READ_IMPLIES_EXEC bit is set in the process
personality. This happens for example if the process stack is
executable.

This causes libmlx5 to output a warning and prevents the user from
reading the free running clock.
Executing the init segment of the hardware isn't a security risk
(at least no more than executing a process own stack), so we just
prevent writes to there.

Fixes: d69e3bcf79 ('IB/mlx5: Mmap the HCA's core clock register to
		      user-space')
Signed-off-by: Matan Barak <matanb@mellanox.com>
Reviewed-by: Haggai Eran <haggaie@mellanox.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
2016-05-13 19:40:03 -04:00
..
cxgb3 iw_cxgb3: initialize ibdev.iwcm->ifname for port mapping 2016-04-26 12:46:54 -04:00
cxgb4 RDMA/iw_cxgb4: remove abort_connection() usage from ep_timeout() 2016-05-05 16:11:14 -04:00
i40iw RDMA/i40iw: Fix for removing quad hash entries 2016-04-28 16:32:55 -04:00
mlx4 IB/mlx4: Use list_for_each_entry_safe 2016-05-13 19:40:03 -04:00
mlx5 IB/mlx5: Allow mapping the free running counter on PROT_EXEC 2016-05-13 19:40:03 -04:00
mthca mm/gup: Switch all callers of get_user_pages() to not pass tsk/mm 2016-02-16 10:11:12 +01:00
nes RDMA/nes: replace custom print_hex_dump() 2016-05-13 19:40:01 -04:00
ocrdma IB/ocrdma: Skip using unneeded intermediate variable 2016-03-03 13:33:22 -05:00
qib IB/rdmavt,hfi1,qib: Fix memory leak 2016-04-28 16:32:27 -04:00
usnic Merge branch 'mm-pkeys-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2016-03-20 19:08:56 -07:00
Makefile i40iw: changes for build of i40iw module 2016-03-16 13:50:54 -04:00