]> git.baikalelectronics.ru Git - kernel.git/commit
IB/mlx5: Fix function updating xlt emergency path
authorArtemy Kovalyov <artemyko@mellanox.com>
Wed, 5 Apr 2017 06:23:51 +0000 (09:23 +0300)
committerDoug Ledford <dledford@redhat.com>
Tue, 25 Apr 2017 19:40:28 +0000 (15:40 -0400)
commitbb14910e69ae566c6e195323a8e7d6c9d892ac41
tree412988c919303bc48fce6a4ef10b6d8271f642e9
parent77fafa3b80ead5a6ac4c7d2cb7f237f6e9133b11
IB/mlx5: Fix function updating xlt emergency path

In memory shortage path we fall back to use spare buffer.
mlx5_ib_update_xlt() called from ib_uverbs_reg_mr when ibmr.ucontext
not initialized yet.

Scenario how to test it:
1. trigger memory exhaustion so __get_free_pages(GFP_KERNEL, 4) will fail
2. register MR
3. there should be no kernel oops

Fixes: b83366b2be84 ('IB/mlx5: Add MR cache for large UMR regions')
Signed-off-by: Artemy Kovalyov <artemyko@mellanox.com>
Signed-off-by: Leon Romanovsky <leon@kernel.org>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/hw/mlx5/mr.c