Date: Mon, 22 Jun 2009 20:09:21 GMT From: Aditya Sarawgi <truncs@FreeBSD.org> To: Perforce Change Reviews <perforce@FreeBSD.org> Subject: PERFORCE change 164894 for review Message-ID: <200906222009.n5MK9LJp057704@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=164894 Change 164894 by truncs@aditya on 2009/06/22 20:09:04 New functions. ext2_hashalloc will be used for inode allocation policy, ext2_dirpref will be used for allocating if its a directory and ext2_alloccg will be used for allocating a block if it's available. Affected files ... .. //depot/projects/soc2009/soc_ext2fs/src/sys/gnu/fs/ext2fs/ext2_alloc.c#7 edit Differences ... ==== //depot/projects/soc2009/soc_ext2fs/src/sys/gnu/fs/ext2fs/ext2_alloc.c#7 (text+ko) ==== @@ -51,7 +51,11 @@ #include <gnu/fs/ext2fs/ext2_extern.h> static void ext2_fserr(struct m_ext2fs *, u_int, char *); - +static daddr_t ext2_alloccg(struct inode *, int, daddr_t, int); +static ino_t ext2_dirpref(struct m_ext2fs *); +static ino_t ext2_hashalloc(struct inode *, int, long, int, + daddr_t (*)(struct inode *, int, daddr_t, + int)); /* * Linux calls this functions at the following locations: * (1) the inode is freed @@ -370,11 +374,11 @@ fs = pip->i_e2fs; if (fs->e2fs->e2fs_ficount == 0) goto noinodes; - + /* call the Linux routine - it returns the inode number only */ ino = ext2_new_inode(pip, mode); - if (ino == 0) + if (ino == 0) goto noinodes; error = VFS_VGET(pvp->v_mount, ino, LK_EXCLUSIVE, vpp); if (error) {
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200906222009.n5MK9LJp057704>