Skip to content

Commit

Permalink
[PATCH] jbd: use BUILD_BUG_ON in journal init
Browse files Browse the repository at this point in the history
Signed-off-by: Alexey Dobriyan <[email protected]>
Acked-by: Stephen Tweedie <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
Alexey Dobriyan authored and Linus Torvalds committed Sep 27, 2006
1 parent ae6ddcc commit 2aed348
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions fs/jbd/journal.c
Original file line number Diff line number Diff line change
Expand Up @@ -2047,13 +2047,7 @@ static int __init journal_init(void)
{
int ret;

/* Static check for data structure consistency. There's no code
* invoked --- we'll just get a linker failure if things aren't right.
*/
extern void journal_bad_superblock_size(void);
if (sizeof(struct journal_superblock_s) != 1024)
journal_bad_superblock_size();

BUILD_BUG_ON(sizeof(struct journal_superblock_s) != 1024);

ret = journal_init_caches();
if (ret != 0)
Expand Down

0 comments on commit 2aed348

Please sign in to comment.