diff options
author | Theodore Ts'o <tytso@mit.edu> | 2009-04-27 22:48:48 -0400 |
---|---|---|
committer | Theodore Ts'o <tytso@mit.edu> | 2009-04-27 22:48:48 -0400 |
commit | c5ca7c7636fa689a9746b6032f83aa7fffec31c6 (patch) | |
tree | eebbdd1d477b5062148ee61c9e1bf1d4da3e9e05 /firmware/tehuti | |
parent | 29fa89d088941d79765d60f22d5ccdd6b8696e11 (diff) |
ext4: Fallback to vmalloc if kmalloc can't allocate s_flex_groups array
For very large filesystems, the s_flex_groups array can get quite big.
For example, a filesystem that can be resized up to 16TB will have
8192 flex groups (assuming the default flex_bg size of 16), so the
array is 96k, which is *very* marginal for kmalloc(). On the other
hand, a 160GB filesystem without the resize_inode feature will only
require 960 bytes. So we try to allocate the array first using
kmalloc(), and if that fails, we'll try to use vmalloc() instead.
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
Diffstat (limited to 'firmware/tehuti')
0 files changed, 0 insertions, 0 deletions