aboutsummaryrefslogtreecommitdiffstats
path: root/fs/udf/ialloc.c
diff options
context:
space:
mode:
authorMarcin Slusarz <marcin.slusarz@gmail.com>2008-02-08 07:20:36 -0500
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2008-02-08 12:22:35 -0500
commit4b11111aba6c80cc2969fd1806d2a869bfc9f357 (patch)
tree57b72a1ca58859dc6a9e47d647f29cebb9bcf7e0 /fs/udf/ialloc.c
parentbd45a420f93d18c91115f3f0568dd6a2555aa15a (diff)
udf: fix coding style
fix coding style errors found by checkpatch: - assignments in if conditions - braces {} around single statement blocks - no spaces after commas - printks without KERN_* - lines longer than 80 characters - spaces between "type *" and variable name before: 192 errors, 561 warnings, 8987 lines checked after: 1 errors, 38 warnings, 9468 lines checked Signed-off-by: Marcin Slusarz <marcin.slusarz@gmail.com> Cc: Jan Kara <jack@suse.cz> Cc: Christoph Hellwig <hch@lst.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs/udf/ialloc.c')
-rw-r--r--fs/udf/ialloc.c24
1 files changed, 17 insertions, 7 deletions
diff --git a/fs/udf/ialloc.c b/fs/udf/ialloc.c
index 8145e943be61..7697b489a292 100644
--- a/fs/udf/ialloc.c
+++ b/fs/udf/ialloc.c
@@ -82,7 +82,8 @@ struct inode *udf_new_inode(struct inode *dir, int mode, int *err)
82 UDF_I_NEXT_ALLOC_GOAL(inode) = 0; 82 UDF_I_NEXT_ALLOC_GOAL(inode) = 0;
83 UDF_I_STRAT4096(inode) = 0; 83 UDF_I_STRAT4096(inode) = 0;
84 84
85 block = udf_new_block(dir->i_sb, NULL, UDF_I_LOCATION(dir).partitionReferenceNum, 85 block = udf_new_block(dir->i_sb, NULL,
86 UDF_I_LOCATION(dir).partitionReferenceNum,
86 start, err); 87 start, err);
87 if (*err) { 88 if (*err) {
88 iput(inode); 89 iput(inode);
@@ -91,11 +92,15 @@ struct inode *udf_new_inode(struct inode *dir, int mode, int *err)
91 92
92 mutex_lock(&sbi->s_alloc_mutex); 93 mutex_lock(&sbi->s_alloc_mutex);
93 if (sbi->s_lvid_bh) { 94 if (sbi->s_lvid_bh) {
94 struct logicalVolIntegrityDesc *lvid = (struct logicalVolIntegrityDesc *)sbi->s_lvid_bh->b_data; 95 struct logicalVolIntegrityDesc *lvid =
95 struct logicalVolIntegrityDescImpUse *lvidiu = udf_sb_lvidiu(sbi); 96 (struct logicalVolIntegrityDesc *)
97 sbi->s_lvid_bh->b_data;
98 struct logicalVolIntegrityDescImpUse *lvidiu =
99 udf_sb_lvidiu(sbi);
96 struct logicalVolHeaderDesc *lvhd; 100 struct logicalVolHeaderDesc *lvhd;
97 uint64_t uniqueID; 101 uint64_t uniqueID;
98 lvhd = (struct logicalVolHeaderDesc *)(lvid->logicalVolContentsUse); 102 lvhd = (struct logicalVolHeaderDesc *)
103 (lvid->logicalVolContentsUse);
99 if (S_ISDIR(mode)) 104 if (S_ISDIR(mode))
100 lvidiu->numDirs = 105 lvidiu->numDirs =
101 cpu_to_le32(le32_to_cpu(lvidiu->numDirs) + 1); 106 cpu_to_le32(le32_to_cpu(lvidiu->numDirs) + 1);
@@ -119,7 +124,8 @@ struct inode *udf_new_inode(struct inode *dir, int mode, int *err)
119 } 124 }
120 125
121 UDF_I_LOCATION(inode).logicalBlockNum = block; 126 UDF_I_LOCATION(inode).logicalBlockNum = block;
122 UDF_I_LOCATION(inode).partitionReferenceNum = UDF_I_LOCATION(dir).partitionReferenceNum; 127 UDF_I_LOCATION(inode).partitionReferenceNum =
128 UDF_I_LOCATION(dir).partitionReferenceNum;
123 inode->i_ino = udf_get_lb_pblock(sb, UDF_I_LOCATION(inode), 0); 129 inode->i_ino = udf_get_lb_pblock(sb, UDF_I_LOCATION(inode), 0);
124 inode->i_blocks = 0; 130 inode->i_blocks = 0;
125 UDF_I_LENEATTR(inode) = 0; 131 UDF_I_LENEATTR(inode) = 0;
@@ -129,10 +135,14 @@ struct inode *udf_new_inode(struct inode *dir, int mode, int *err)
129 UDF_I_EFE(inode) = 1; 135 UDF_I_EFE(inode) = 1;
130 if (UDF_VERS_USE_EXTENDED_FE > sbi->s_udfrev) 136 if (UDF_VERS_USE_EXTENDED_FE > sbi->s_udfrev)
131 sbi->s_udfrev = UDF_VERS_USE_EXTENDED_FE; 137 sbi->s_udfrev = UDF_VERS_USE_EXTENDED_FE;
132 UDF_I_DATA(inode) = kzalloc(inode->i_sb->s_blocksize - sizeof(struct extendedFileEntry), GFP_KERNEL); 138 UDF_I_DATA(inode) = kzalloc(inode->i_sb->s_blocksize -
139 sizeof(struct extendedFileEntry),
140 GFP_KERNEL);
133 } else { 141 } else {
134 UDF_I_EFE(inode) = 0; 142 UDF_I_EFE(inode) = 0;
135 UDF_I_DATA(inode) = kzalloc(inode->i_sb->s_blocksize - sizeof(struct fileEntry), GFP_KERNEL); 143 UDF_I_DATA(inode) = kzalloc(inode->i_sb->s_blocksize -
144 sizeof(struct fileEntry),
145 GFP_KERNEL);
136 } 146 }
137 if (!UDF_I_DATA(inode)) { 147 if (!UDF_I_DATA(inode)) {
138 iput(inode); 148 iput(inode);