diff options
author | Fabian Frederick <fabf@skynet.be> | 2014-08-08 17:22:22 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-08-08 18:57:24 -0400 |
commit | e2ffcf5c7ee7eb979b1f2375404668a2f5076c1b (patch) | |
tree | 9b12c25cb2629f87e1e7ab22e5dac55e7cda6818 | |
parent | 834b18b23e1012e6c2987af703490bc60956d211 (diff) |
fs/adfs/dir_fplus.c: use ARRAY_SIZE instead of sizeof/sizeof[0]
Use kernel.h definition.
Signed-off-by: Fabian Frederick <fabf@skynet.be>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r-- | fs/adfs/dir_fplus.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/adfs/dir_fplus.c b/fs/adfs/dir_fplus.c index d9e3bee4e653..7673c1fdbfc0 100644 --- a/fs/adfs/dir_fplus.c +++ b/fs/adfs/dir_fplus.c | |||
@@ -55,7 +55,7 @@ adfs_fplus_read(struct super_block *sb, unsigned int id, unsigned int sz, struct | |||
55 | } | 55 | } |
56 | 56 | ||
57 | size >>= sb->s_blocksize_bits; | 57 | size >>= sb->s_blocksize_bits; |
58 | if (size > sizeof(dir->bh)/sizeof(dir->bh[0])) { | 58 | if (size > ARRAY_SIZE(dir->bh)) { |
59 | /* this directory is too big for fixed bh set, must allocate */ | 59 | /* this directory is too big for fixed bh set, must allocate */ |
60 | struct buffer_head **bh_fplus = | 60 | struct buffer_head **bh_fplus = |
61 | kzalloc(size * sizeof(struct buffer_head *), | 61 | kzalloc(size * sizeof(struct buffer_head *), |