]> git.baikalelectronics.ru Git - kernel.git/commit
IB/mlx4: Forbid using sysfs to change RoCE pkeys
authorJack Morgenstein <jackm@dev.mellanox.co.il>
Thu, 30 Jul 2015 14:34:23 +0000 (17:34 +0300)
committerDoug Ledford <dledford@redhat.com>
Sun, 30 Aug 2015 22:12:22 +0000 (18:12 -0400)
commite0cb05a628f6efbc26b1977fd89366e1bcc76e22
treeba54c6a19f12f68c88c5209a52abb2101168ce86
parentbe7df1b4b61495afb7bc4727d135f6320242e82e
IB/mlx4: Forbid using sysfs to change RoCE pkeys

The pkey mapping for RoCE must remain the default mapping:
VFs:
  virtual index 0 = mapped to real index 0 (0xFFFF)
  All others indices: mapped to a real pkey index containing an
                      invalid pkey.
PF:
  virtual index i = real index i.

Don't allow users to change these mappings using files found in
sysfs.

Fixes: b5a4d3038409 ('IB/mlx4: Add iov directory in sysfs under the ib device')
Signed-off-by: Jack Morgenstein <jackm@dev.mellanox.co.il>
Signed-off-by: Or Gerlitz <ogerlitz@mellanox.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/hw/mlx4/sysfs.c