Mellanox mlx4_core MTT allocation not as large as expected
Issue
- In the mlx4 driver, MTT allocation code, the operation in /drivers/net/mlx4/profile.c, in mlx4_make_profile() states that we wish to dedicate as many MTT's by default as is the maximum amount of RAM in pages, times two. However, the real world allocation is seen to be much smaller:
/*
* We want to scale the number of MTTs with the size of the
* system memory, since it makes sense to register a lot of
* memory on a system with a lot of memory. As a heuristic,
* make sure we have enough MTTs to cover twice the system
* memory (with PAGE_SIZE entries).
*
* This number has to be a power of two and fit into 32 bits
* due to device limitations, so cap this at 2^31 as well.
* That limits us to 8TB of memory registration per HCA with
* 4KB pages, which is probably OK for the next few months.
*/
Environment
- Red Hat Enterprise Linux 7
- Red Hat Enterprise Linux 6
- mlx4_core module
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.
Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.
