diff options
Diffstat (limited to 'fs/ufs')
-rw-r--r-- | fs/ufs/balloc.c | 20 | ||||
-rw-r--r-- | fs/ufs/cylinder.c | 2 | ||||
-rw-r--r-- | fs/ufs/ialloc.c | 12 | ||||
-rw-r--r-- | fs/ufs/inode.c | 6 | ||||
-rw-r--r-- | fs/ufs/namei.c | 24 | ||||
-rw-r--r-- | fs/ufs/super.c | 10 | ||||
-rw-r--r-- | fs/ufs/truncate.c | 8 | ||||
-rw-r--r-- | fs/ufs/util.c | 4 | ||||
-rw-r--r-- | fs/ufs/util.h | 2 |
9 files changed, 43 insertions, 45 deletions
diff --git a/fs/ufs/balloc.c b/fs/ufs/balloc.c index 2f156b42a..fa83ba5be 100644 --- a/fs/ufs/balloc.c +++ b/fs/ufs/balloc.c @@ -110,8 +110,8 @@ void ufs_free_fragments (struct inode * inode, unsigned fragment, unsigned count INC_SWAB32(ubh_cg_blktot (ucpi, cylno)); } - ubh_mark_buffer_dirty (USPI_UBH, 1); - ubh_mark_buffer_dirty (UCPI_UBH, 1); + ubh_mark_buffer_dirty (USPI_UBH); + ubh_mark_buffer_dirty (UCPI_UBH); if (sb->s_flags & MS_SYNCHRONOUS) { ubh_ll_rw_block (WRITE, 1, (struct ufs_buffer_head **)&ucpi); ubh_wait_on_buffer (UCPI_UBH); @@ -196,8 +196,8 @@ do_more: INC_SWAB32(ubh_cg_blktot(ucpi, cylno)); } - ubh_mark_buffer_dirty (USPI_UBH, 1); - ubh_mark_buffer_dirty (UCPI_UBH, 1); + ubh_mark_buffer_dirty (USPI_UBH); + ubh_mark_buffer_dirty (UCPI_UBH); if (sb->s_flags & MS_SYNCHRONOUS) { ubh_ll_rw_block (WRITE, 1, (struct ufs_buffer_head **)&ucpi); ubh_wait_on_buffer (UCPI_UBH); @@ -227,7 +227,7 @@ failed: bh = getblk (sb->s_dev, result + i, sb->s_blocksize); \ memset (bh->b_data, 0, sb->s_blocksize); \ mark_buffer_uptodate(bh, 1); \ - mark_buffer_dirty (bh, 1); \ + mark_buffer_dirty (bh); \ if (IS_SYNC(inode)) { \ ll_rw_block (WRITE, 1, &bh); \ wait_on_buffer (bh); \ @@ -364,7 +364,7 @@ unsigned ufs_new_fragments (struct inode * inode, u32 * p, unsigned fragment, { mark_buffer_clean (bh); bh->b_blocknr = result + i; - mark_buffer_dirty (bh, 0); + mark_buffer_dirty (bh); if (IS_SYNC(inode)) { ll_rw_block (WRITE, 1, &bh); wait_on_buffer (bh); @@ -458,8 +458,8 @@ unsigned ufs_add_fragments (struct inode * inode, unsigned fragment, SUB_SWAB32(sb->fs_cs(cgno).cs_nffree, count); SUB_SWAB32(usb1->fs_cstotal.cs_nffree, count); - ubh_mark_buffer_dirty (USPI_UBH, 1); - ubh_mark_buffer_dirty (UCPI_UBH, 1); + ubh_mark_buffer_dirty (USPI_UBH); + ubh_mark_buffer_dirty (UCPI_UBH); if (sb->s_flags & MS_SYNCHRONOUS) { ubh_ll_rw_block (WRITE, 1, (struct ufs_buffer_head **)&ucpi); ubh_wait_on_buffer (UCPI_UBH); @@ -582,8 +582,8 @@ cg_found: INC_SWAB32(ucg->cg_frsum[allocsize - count]); succed: - ubh_mark_buffer_dirty (USPI_UBH, 1); - ubh_mark_buffer_dirty (UCPI_UBH, 1); + ubh_mark_buffer_dirty (USPI_UBH); + ubh_mark_buffer_dirty (UCPI_UBH); if (sb->s_flags & MS_SYNCHRONOUS) { ubh_ll_rw_block (WRITE, 1, (struct ufs_buffer_head **)&ucpi); ubh_wait_on_buffer (UCPI_UBH); diff --git a/fs/ufs/cylinder.c b/fs/ufs/cylinder.c index ed261321d..4afc9d9d6 100644 --- a/fs/ufs/cylinder.c +++ b/fs/ufs/cylinder.c @@ -119,7 +119,7 @@ void ufs_put_cylinder (struct super_block * sb, unsigned bitmap_nr) ucg->cg_rotor = SWAB32(ucpi->c_rotor); ucg->cg_frotor = SWAB32(ucpi->c_frotor); ucg->cg_irotor = SWAB32(ucpi->c_irotor); - ubh_mark_buffer_dirty (UCPI_UBH, 1); + ubh_mark_buffer_dirty (UCPI_UBH); for (i = 1; i < UCPI_UBH->count; i++) { brelse (UCPI_UBH->bh[i]); } diff --git a/fs/ufs/ialloc.c b/fs/ufs/ialloc.c index f93a55c4e..1a97daf7c 100644 --- a/fs/ufs/ialloc.c +++ b/fs/ufs/ialloc.c @@ -121,8 +121,8 @@ void ufs_free_inode (struct inode * inode) DEC_SWAB32(sb->fs_cs(cg).cs_ndir); } } - ubh_mark_buffer_dirty (USPI_UBH, 1); - ubh_mark_buffer_dirty (UCPI_UBH, 1); + ubh_mark_buffer_dirty (USPI_UBH); + ubh_mark_buffer_dirty (UCPI_UBH); if (sb->s_flags & MS_SYNCHRONOUS) { ubh_ll_rw_block (WRITE, 1, (struct ufs_buffer_head **) &ucpi); ubh_wait_on_buffer (UCPI_UBH); @@ -252,8 +252,8 @@ cg_found: INC_SWAB32(sb->fs_cs(cg).cs_ndir); } - ubh_mark_buffer_dirty (USPI_UBH, 1); - ubh_mark_buffer_dirty (UCPI_UBH, 1); + ubh_mark_buffer_dirty (USPI_UBH); + ubh_mark_buffer_dirty (UCPI_UBH); if (sb->s_flags & MS_SYNCHRONOUS) { ubh_ll_rw_block (WRITE, 1, (struct ufs_buffer_head **) &ucpi); ubh_wait_on_buffer (UCPI_UBH); @@ -265,9 +265,7 @@ cg_found: inode->i_nlink = 1; inode->i_dev = sb->s_dev; inode->i_uid = current->fsuid; - if (test_opt (sb, GRPID)) - inode->i_gid = dir->i_gid; - else if (dir->i_mode & S_ISGID) { + if (dir->i_mode & S_ISGID) { inode->i_gid = dir->i_gid; if (S_ISDIR(mode)) mode |= S_ISGID; diff --git a/fs/ufs/inode.c b/fs/ufs/inode.c index 771069834..10a9d9be4 100644 --- a/fs/ufs/inode.c +++ b/fs/ufs/inode.c @@ -360,7 +360,7 @@ repeat: *new = 1; } - mark_buffer_dirty(bh, 1); + mark_buffer_dirty(bh); if (IS_SYNC(inode)) { ll_rw_block (WRITE, 1, &bh); wait_on_buffer (bh); @@ -493,7 +493,7 @@ struct buffer_head *ufs_getfrag(struct inode *inode, unsigned int fragment, if (buffer_new(&dummy)) { memset(bh->b_data, 0, inode->i_sb->s_blocksize); mark_buffer_uptodate(bh, 1); - mark_buffer_dirty(bh, 1); + mark_buffer_dirty(bh); } return bh; } @@ -711,7 +711,7 @@ static int ufs_update_inode(struct inode * inode, int do_sync) if (!inode->i_nlink) memset (ufs_inode, 0, sizeof(struct ufs_inode)); - mark_buffer_dirty(bh, 1); + mark_buffer_dirty(bh); if (do_sync) { ll_rw_block (WRITE, 1, &bh); wait_on_buffer (bh); diff --git a/fs/ufs/namei.c b/fs/ufs/namei.c index 7966998d9..70a29b393 100644 --- a/fs/ufs/namei.c +++ b/fs/ufs/namei.c @@ -321,7 +321,7 @@ static struct buffer_head * ufs_add_entry (struct inode * dir, dir->i_mtime = dir->i_ctime = CURRENT_TIME; mark_inode_dirty(dir); dir->i_version = ++event; - mark_buffer_dirty(bh, 1); + mark_buffer_dirty(bh); *res_dir = de; *err = 0; @@ -428,7 +428,7 @@ static int ufs_create (struct inode * dir, struct dentry * dentry, int mode) de->d_ino = SWAB32(inode->i_ino); ufs_set_de_type (de, inode->i_mode); dir->i_version = ++event; - mark_buffer_dirty(bh, 1); + mark_buffer_dirty(bh); if (IS_SYNC(dir)) { ll_rw_block (WRITE, 1, &bh); wait_on_buffer (bh); @@ -467,7 +467,7 @@ static int ufs_mknod (struct inode * dir, struct dentry *dentry, int mode, int r de->d_ino = SWAB32(inode->i_ino); ufs_set_de_type (de, inode->i_mode); dir->i_version = ++event; - mark_buffer_dirty(bh, 1); + mark_buffer_dirty(bh); if (IS_SYNC(dir)) { ll_rw_block (WRITE, 1, &bh); wait_on_buffer (bh); @@ -530,7 +530,7 @@ static int ufs_mkdir(struct inode * dir, struct dentry * dentry, int mode) ufs_set_de_namlen(de,2); strcpy (de->d_name, ".."); inode->i_nlink = 2; - mark_buffer_dirty(dir_block, 1); + mark_buffer_dirty(dir_block); brelse (dir_block); inode->i_mode = S_IFDIR | mode; if (dir->i_mode & S_ISGID) @@ -542,7 +542,7 @@ static int ufs_mkdir(struct inode * dir, struct dentry * dentry, int mode) de->d_ino = SWAB32(inode->i_ino); ufs_set_de_type (de, inode->i_mode); dir->i_version = ++event; - mark_buffer_dirty(bh, 1); + mark_buffer_dirty(bh); if (IS_SYNC(dir)) { ll_rw_block (WRITE, 1, &bh); wait_on_buffer (bh); @@ -657,7 +657,7 @@ static int ufs_rmdir (struct inode * dir, struct dentry *dentry) dir->i_version = ++event; if (retval) goto end_rmdir; - mark_buffer_dirty(bh, 1); + mark_buffer_dirty(bh); if (IS_SYNC(dir)) { ll_rw_block (WRITE, 1, &bh); wait_on_buffer (bh); @@ -718,7 +718,7 @@ static int ufs_unlink(struct inode * dir, struct dentry *dentry) if (retval) goto end_unlink; dir->i_version = ++event; - mark_buffer_dirty(bh, 1); + mark_buffer_dirty(bh); if (IS_SYNC(dir)) { ll_rw_block (WRITE, 1, &bh); wait_on_buffer (bh); @@ -785,7 +785,7 @@ static int ufs_symlink (struct inode * dir, struct dentry * dentry, goto out_no_entry; de->d_ino = SWAB32(inode->i_ino); dir->i_version = ++event; - mark_buffer_dirty(bh, 1); + mark_buffer_dirty(bh); if (IS_SYNC(dir)) { ll_rw_block (WRITE, 1, &bh); wait_on_buffer (bh); @@ -825,7 +825,7 @@ static int ufs_link (struct dentry * old_dentry, struct inode * dir, de->d_ino = SWAB32(inode->i_ino); dir->i_version = ++event; - mark_buffer_dirty(bh, 1); + mark_buffer_dirty(bh); if (IS_SYNC(dir)) { ll_rw_block (WRITE, 1, &bh); wait_on_buffer (bh); @@ -930,7 +930,7 @@ static int ufs_rename (struct inode * old_dir, struct dentry * old_dentry, mark_inode_dirty(old_dir); if (dir_bh) { PARENT_INO(dir_bh->b_data) = SWAB32(new_dir->i_ino); - mark_buffer_dirty(dir_bh, 1); + mark_buffer_dirty(dir_bh); old_dir->i_nlink--; mark_inode_dirty(old_dir); if (new_inode) { @@ -941,13 +941,13 @@ static int ufs_rename (struct inode * old_dir, struct dentry * old_dentry, mark_inode_dirty(new_dir); } } - mark_buffer_dirty(old_bh, 1); + mark_buffer_dirty(old_bh); if (IS_SYNC(old_dir)) { ll_rw_block (WRITE, 1, &old_bh); wait_on_buffer (old_bh); } - mark_buffer_dirty(new_bh, 1); + mark_buffer_dirty(new_bh); if (IS_SYNC(new_dir)) { ll_rw_block (WRITE, 1, &new_bh); wait_on_buffer (new_bh); diff --git a/fs/ufs/super.c b/fs/ufs/super.c index c41228adf..6d83d7c51 100644 --- a/fs/ufs/super.c +++ b/fs/ufs/super.c @@ -192,7 +192,7 @@ void ufs_error (struct super_block * sb, const char * function, if (!(sb->s_flags & MS_RDONLY)) { usb1->fs_clean = UFS_FSBAD; - ubh_mark_buffer_dirty(USPI_UBH, 1); + ubh_mark_buffer_dirty(USPI_UBH); sb->s_dirt = 1; sb->s_flags |= MS_RDONLY; } @@ -224,7 +224,7 @@ void ufs_panic (struct super_block * sb, const char * function, if (!(sb->s_flags & MS_RDONLY)) { usb1->fs_clean = UFS_FSBAD; - ubh_mark_buffer_dirty(USPI_UBH, 1); + ubh_mark_buffer_dirty(USPI_UBH); sb->s_dirt = 1; } va_start (args, fmt); @@ -422,7 +422,7 @@ void ufs_put_cylinder_structures (struct super_block * sb) { ubh_memcpyubh (ubh, space, size); space += size; ubh_mark_buffer_uptodate (ubh, 1); - ubh_mark_buffer_dirty (ubh, 0); + ubh_mark_buffer_dirty (ubh); ubh_brelse (ubh); } for (i = 0; i < sb->u.ufs_sb.s_cg_loaded; i++) { @@ -845,7 +845,7 @@ void ufs_write_super (struct super_block * sb) { if ((flags & UFS_ST_MASK) == UFS_ST_SUN || (flags & UFS_ST_MASK) == UFS_ST_SUNx86) ufs_set_fs_state(usb1, usb3, UFS_FSOK - SWAB32(usb1->fs_time)); - ubh_mark_buffer_dirty (USPI_UBH, 1); + ubh_mark_buffer_dirty (USPI_UBH); } sb->s_dirt = 0; UFSD(("EXIT\n")) @@ -915,7 +915,7 @@ int ufs_remount (struct super_block * sb, int * mount_flags, char * data) if ((flags & UFS_ST_MASK) == UFS_ST_SUN || (flags & UFS_ST_MASK) == UFS_ST_SUNx86) ufs_set_fs_state(usb1, usb3, UFS_FSOK - SWAB32(usb1->fs_time)); - ubh_mark_buffer_dirty (USPI_UBH, 1); + ubh_mark_buffer_dirty (USPI_UBH); sb->s_dirt = 0; sb->s_flags |= MS_RDONLY; } diff --git a/fs/ufs/truncate.c b/fs/ufs/truncate.c index 57de81eb8..183ccfb13 100644 --- a/fs/ufs/truncate.c +++ b/fs/ufs/truncate.c @@ -248,7 +248,7 @@ static int ufs_trunc_indirect (struct inode * inode, unsigned offset, u32 * p) bforget (bh); } *ind = SWAB32(0); - ubh_mark_buffer_dirty(ind_ubh, 1); + ubh_mark_buffer_dirty(ind_ubh); if (free_count == 0) { frag_to_free = tmp; free_count = uspi->s_fpb; @@ -334,7 +334,7 @@ static int ufs_trunc_dindirect (struct inode * inode, unsigned offset, u32 * p) if (!tmp) continue; retry |= ufs_trunc_indirect (inode, offset + (i << uspi->s_apbshift), dind); - ubh_mark_buffer_dirty(dind_bh, 1); + ubh_mark_buffer_dirty(dind_bh); } for (i = 0; i < uspi->s_apb; i++) @@ -400,7 +400,7 @@ static int ufs_trunc_tindirect (struct inode * inode) tind = ubh_get_addr32 (tind_bh, i); retry |= ufs_trunc_dindirect(inode, UFS_NDADDR + uspi->s_apb + ((i + 1) << uspi->s_2apbshift), tind); - ubh_mark_buffer_dirty(tind_bh, 1); + ubh_mark_buffer_dirty(tind_bh); } for (i = 0; i < uspi->s_apb; i++) if (SWAB32(*ubh_get_addr32 (tind_bh, i))) @@ -466,7 +466,7 @@ void ufs_truncate (struct inode * inode) bh = ufs_bread (inode, inode->i_size >> uspi->s_fshift, 0, &err); if (bh) { memset (bh->b_data + offset, 0, uspi->s_fsize - offset); - mark_buffer_dirty (bh, 0); + mark_buffer_dirty (bh); brelse (bh); } } diff --git a/fs/ufs/util.c b/fs/ufs/util.c index e6d5f3a5b..334e0efdb 100644 --- a/fs/ufs/util.c +++ b/fs/ufs/util.c @@ -94,13 +94,13 @@ void ubh_brelse_uspi (struct ufs_sb_private_info * uspi) } } -void ubh_mark_buffer_dirty (struct ufs_buffer_head * ubh, int flag) +void ubh_mark_buffer_dirty (struct ufs_buffer_head * ubh) { unsigned i; if (!ubh) return; for ( i = 0; i < ubh->count; i++ ) - mark_buffer_dirty (ubh->bh[i], flag); + mark_buffer_dirty (ubh->bh[i]); } void ubh_mark_buffer_uptodate (struct ufs_buffer_head * ubh, int flag) diff --git a/fs/ufs/util.h b/fs/ufs/util.h index 049b194ee..0def49d95 100644 --- a/fs/ufs/util.h +++ b/fs/ufs/util.h @@ -212,7 +212,7 @@ extern struct ufs_buffer_head * _ubh_bread_(struct ufs_sb_private_info *, kdev_t extern struct ufs_buffer_head * ubh_bread_uspi(struct ufs_sb_private_info *, kdev_t, unsigned, unsigned); extern void ubh_brelse (struct ufs_buffer_head *); extern void ubh_brelse_uspi (struct ufs_sb_private_info *); -extern void ubh_mark_buffer_dirty (struct ufs_buffer_head *, int); +extern void ubh_mark_buffer_dirty (struct ufs_buffer_head *); extern void ubh_mark_buffer_uptodate (struct ufs_buffer_head *, int); extern void ubh_ll_rw_block (int, unsigned, struct ufs_buffer_head **); extern void ubh_wait_on_buffer (struct ufs_buffer_head *); |