]> git.baikalelectronics.ru Git - kernel.git/commit
mlx4_core: Scale size of MTT table with system RAM
authorRoland Dreier <roland@purestorage.com>
Mon, 5 Mar 2012 18:05:28 +0000 (10:05 -0800)
committerRoland Dreier <roland@purestorage.com>
Mon, 12 Mar 2012 23:24:59 +0000 (16:24 -0700)
commit746198336e237ee0de2d110b259aded1c8f1bb2c
treefdb7cb84d4ae634303c5337203ce482ae4c83c97
parent70510654cf41d26a47087ea722d5e1896aba65a8
mlx4_core: Scale size of MTT table with system RAM

The current driver defaults to 1M MTT segments, where each segment holds
8 MTT entries.  This limits the total memory registered to 8M * PAGE_SIZE
which is 32GB with 4K pages.  Since systems that have much more memory
are pretty common now (at least among systems with InfiniBand hardware),
this limit ends up getting hit in practice quite a bit.

Handle this by having the driver allocate at least enough MTT entries to
cover 2 * totalram pages.

Signed-off-by: Roland Dreier <roland@purestorage.com>
drivers/net/ethernet/mellanox/mlx4/mlx4.h
drivers/net/ethernet/mellanox/mlx4/profile.c