From: Yishai Hadas Date: Mon, 13 Aug 2012 08:15:06 +0000 (+0000) Subject: mlx4_core: Allow large mlx4_buddy bitmaps X-Git-Tag: v3.6-rc3~36^2^4~3 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=89dd86db78e08b51bab29e168fd41b2fd943e6b6;p=pandora-kernel.git mlx4_core: Allow large mlx4_buddy bitmaps mlx4_buddy_init uses kmalloc() to allocate bitmaps, which fails when the required size is beyond the max supported value (or when memory is too fragmented to handle a huge allocation). Extend this to use use vmalloc() if kmalloc() fails, and take that into account when freeing the bitmaps as well. This fixes a driver load failure when log num mtt is 26 or higher, and is a step in the direction of allowing to register huge amounts of memory on large memory systems. Signed-off-by: Yishai Hadas Signed-off-by: Or Gerlitz Signed-off-by: Roland Dreier --- Reading git-diff-tree failed