* IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
* WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
*
* IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
* WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
*
if (vp->v_type == VCHR || vp->v_type == VBLK) {
vp->v_op = &spec_inodeops;
if (nvp = checkalias(vp, ip->i_rdev, mntp)) {
if (vp->v_type == VCHR || vp->v_type == VBLK) {
vp->v_op = &spec_inodeops;
if (nvp = checkalias(vp, ip->i_rdev, mntp)) {
- if (prtactive && vp->v_count != 0)
- printf("ufs_inactive: pushing active ino %d dev 0x%x\n",
- ip->i_number, ip->i_dev);
+ if (prtactive && vp->v_usecount != 0)
+ vprint("ufs_inactive: pushing active", vp);
* If we are done with the inode, reclaim it
* so that it can be reused immediately.
*/
* If we are done with the inode, reclaim it
* so that it can be reused immediately.
*/
- if (prtactive && vp->v_count != 0)
- printf("ufs_reclaim: pushing active ino %d dev 0x%x\n",
- ip->i_number, ip->i_dev);
+ if (prtactive && vp->v_usecount != 0)
+ vprint("ufs_reclaim: pushing active", vp);
{
register daddr_t lastblock;
daddr_t bn, lbn, lastiblock[NIADDR];
{
register daddr_t lastblock;
daddr_t bn, lbn, lastiblock[NIADDR];
int offset, osize, size, level;
long count, nblocks, blocksreleased = 0;
register int i;
int offset, osize, size, level;
long count, nblocks, blocksreleased = 0;
register int i;
- error = balloc(oip, lbn, offset, &bn, B_CLRBUF);
- if (error)
+ aflags = B_CLRBUF;
+ if (flags & IO_SYNC)
+ aflags |= B_SYNC;
+ if (error = balloc(oip, lbn, offset, &bp, aflags))
count = howmany(size, CLBYTES);
munhash(oip->i_devvp, bn + i * CLBYTES / DEV_BSIZE);
count = howmany(size, CLBYTES);
munhash(oip->i_devvp, bn + i * CLBYTES / DEV_BSIZE);
- allerror = syncip(oip, MNT_WAIT);
+ vinvalbuf(ITOV(oip), (length > 0));
+ allerror = iupdat(oip, &time, &time, MNT_WAIT);
bcopy((caddr_t)bap, (caddr_t)copy, (u_int)fs->fs_bsize);
bzero((caddr_t)&bap[last + 1],
(u_int)(NINDIR(fs) - (last + 1)) * sizeof (daddr_t));
bcopy((caddr_t)bap, (caddr_t)copy, (u_int)fs->fs_bsize);
bzero((caddr_t)&bap[last + 1],
(u_int)(NINDIR(fs) - (last + 1)) * sizeof (daddr_t));
- printf("unlocking unlocked inode %d on dev 0x%x\n",
- ip->i_number, ip->i_dev);
+ vprint("iunlock: unlocked inode", ITOV(ip));
+ ip->i_spare0 = 0;
+ u.u_spare[0]--;