Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

JFS: White space cleanup

Removed trailing spaces & tabs, and spaces preceding tabs.
Also a couple very minor comment cleanups.

Signed-off-by: Dave Kleikamp <shaggy@austin.ibm.com>
(cherry picked from f74156539964d7b3d5164fdf8848e6a682f75b97 commit)

+509 -511
+4 -4
fs/jfs/acl.c
··· 5 5 * 6 6 * This program is free software; you can redistribute it and/or modify 7 7 * it under the terms of the GNU General Public License as published by 8 - * the Free Software Foundation; either version 2 of the License, or 8 + * the Free Software Foundation; either version 2 of the License, or 9 9 * (at your option) any later version. 10 - * 10 + * 11 11 * This program is distributed in the hope that it will be useful, 12 12 * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 14 14 * the GNU General Public License for more details. 15 15 * 16 16 * You should have received a copy of the GNU General Public License 17 - * along with this program; if not, write to the Free Software 17 + * along with this program; if not, write to the Free Software 18 18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 19 19 */ 20 20 ··· 183 183 posix_acl_release(acl); 184 184 } else 185 185 inode->i_mode &= ~current->fs->umask; 186 - 186 + 187 187 JFS_IP(inode)->mode2 = (JFS_IP(inode)->mode2 & 0xffff0000) | 188 188 inode->i_mode; 189 189
+1 -1
fs/jfs/endian24.h
··· 1 1 /* 2 - * Copyright (c) International Business Machines Corp., 2001 2 + * Copyright (C) International Business Machines Corp., 2001 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by
+4 -4
fs/jfs/file.c
··· 4 4 * 5 5 * This program is free software; you can redistribute it and/or modify 6 6 * it under the terms of the GNU General Public License as published by 7 - * the Free Software Foundation; either version 2 of the License, or 7 + * the Free Software Foundation; either version 2 of the License, or 8 8 * (at your option) any later version. 9 - * 9 + * 10 10 * This program is distributed in the hope that it will be useful, 11 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 13 13 * the GNU General Public License for more details. 14 14 * 15 15 * You should have received a copy of the GNU General Public License 16 - * along with this program; if not, write to the Free Software 16 + * along with this program; if not, write to the Free Software 17 17 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 18 */ 19 19 ··· 108 108 .aio_read = generic_file_aio_read, 109 109 .aio_write = generic_file_aio_write, 110 110 .mmap = generic_file_mmap, 111 - .sendfile = generic_file_sendfile, 111 + .sendfile = generic_file_sendfile, 112 112 .fsync = jfs_fsync, 113 113 .release = jfs_release, 114 114 .ioctl = jfs_ioctl,
+4 -4
fs/jfs/inode.c
··· 4 4 * 5 5 * This program is free software; you can redistribute it and/or modify 6 6 * it under the terms of the GNU General Public License as published by 7 - * the Free Software Foundation; either version 2 of the License, or 7 + * the Free Software Foundation; either version 2 of the License, or 8 8 * (at your option) any later version. 9 - * 9 + * 10 10 * This program is distributed in the hope that it will be useful, 11 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 13 13 * the GNU General Public License for more details. 14 14 * 15 15 * You should have received a copy of the GNU General Public License 16 - * along with this program; if not, write to the Free Software 16 + * along with this program; if not, write to the Free Software 17 17 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 18 */ 19 19 ··· 33 33 34 34 void jfs_read_inode(struct inode *inode) 35 35 { 36 - if (diRead(inode)) { 36 + if (diRead(inode)) { 37 37 make_bad_inode(inode); 38 38 return; 39 39 }
+4 -4
fs/jfs/jfs_acl.h
··· 1 1 /* 2 - * Copyright (c) International Business Machines Corp., 2002 2 + * Copyright (C) International Business Machines Corp., 2002 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18 #ifndef _H_JFS_ACL
+3 -3
fs/jfs/jfs_btree.h
··· 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18 #ifndef _H_JFS_BTREE
+3 -3
fs/jfs/jfs_debug.c
··· 4 4 * 5 5 * This program is free software; you can redistribute it and/or modify 6 6 * it under the terms of the GNU General Public License as published by 7 - * the Free Software Foundation; either version 2 of the License, or 7 + * the Free Software Foundation; either version 2 of the License, or 8 8 * (at your option) any later version. 9 - * 9 + * 10 10 * This program is distributed in the hope that it will be useful, 11 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 13 13 * the GNU General Public License for more details. 14 14 * 15 15 * You should have received a copy of the GNU General Public License 16 - * along with this program; if not, write to the Free Software 16 + * along with this program; if not, write to the Free Software 17 17 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 18 */ 19 19
+4 -4
fs/jfs/jfs_dinode.h
··· 1 1 /* 2 - * Copyright (c) International Business Machines Corp., 2000-2001 2 + * Copyright (C) International Business Machines Corp., 2000-2001 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18 #ifndef _H_JFS_DINODE
+91 -91
fs/jfs/jfs_dmap.c
··· 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18 ··· 30 30 * 31 31 * the working state of the block allocation map is accessed in 32 32 * two directions: 33 - * 33 + * 34 34 * 1) allocation and free requests that start at the dmap 35 35 * level and move up through the dmap control pages (i.e. 36 36 * the vast majority of requests). 37 - * 38 - * 2) allocation requests that start at dmap control page 39 - * level and work down towards the dmaps. 40 - * 41 - * the serialization scheme used here is as follows. 42 37 * 43 - * requests which start at the bottom are serialized against each 44 - * other through buffers and each requests holds onto its buffers 45 - * as it works it way up from a single dmap to the required level 38 + * 2) allocation requests that start at dmap control page 39 + * level and work down towards the dmaps. 40 + * 41 + * the serialization scheme used here is as follows. 42 + * 43 + * requests which start at the bottom are serialized against each 44 + * other through buffers and each requests holds onto its buffers 45 + * as it works it way up from a single dmap to the required level 46 46 * of dmap control page. 47 47 * requests that start at the top are serialized against each other 48 48 * and request that start from the bottom by the multiple read/single 49 49 * write inode lock of the bmap inode. requests starting at the top 50 50 * take this lock in write mode while request starting at the bottom 51 51 * take the lock in read mode. a single top-down request may proceed 52 - * exclusively while multiple bottoms-up requests may proceed 53 - * simultaneously (under the protection of busy buffers). 54 - * 52 + * exclusively while multiple bottoms-up requests may proceed 53 + * simultaneously (under the protection of busy buffers). 54 + * 55 55 * in addition to information found in dmaps and dmap control pages, 56 56 * the working state of the block allocation map also includes read/ 57 57 * write information maintained in the bmap descriptor (i.e. total ··· 59 59 * a single exclusive lock (BMAP_LOCK) is used to guard this information 60 60 * in the face of multiple-bottoms up requests. 61 61 * (lock ordering: IREAD_LOCK, BMAP_LOCK); 62 - * 62 + * 63 63 * accesses to the persistent state of the block allocation map (limited 64 64 * to the persistent bitmaps in dmaps) is guarded by (busy) buffers. 65 65 */ ··· 120 120 /* 121 121 * buddy table 122 122 * 123 - * table used for determining buddy sizes within characters of 123 + * table used for determining buddy sizes within characters of 124 124 * dmap bitmap words. the characters themselves serve as indexes 125 125 * into the table, with the table elements yielding the maximum 126 126 * binary buddy of free bits within the character. ··· 146 146 147 147 148 148 /* 149 - * NAME: dbMount() 149 + * NAME: dbMount() 150 150 * 151 151 * FUNCTION: initializate the block allocation map. 152 152 * ··· 223 223 224 224 225 225 /* 226 - * NAME: dbUnmount() 226 + * NAME: dbUnmount() 227 227 * 228 228 * FUNCTION: terminate the block allocation map in preparation for 229 229 * file system unmount. 230 230 * 231 - * the in-core bmap descriptor is written to disk and 231 + * the in-core bmap descriptor is written to disk and 232 232 * the memory for this descriptor is freed. 233 233 * 234 234 * PARAMETERS: ··· 311 311 312 312 313 313 /* 314 - * NAME: dbFree() 314 + * NAME: dbFree() 315 315 * 316 316 * FUNCTION: free the specified block range from the working block 317 317 * allocation map. ··· 397 397 * 398 398 * FUNCTION: update the allocation state (free or allocate) of the 399 399 * specified block range in the persistent block allocation map. 400 - * 400 + * 401 401 * the blocks will be updated in the persistent map one 402 402 * dmap at a time. 403 403 * ··· 475 475 /* update the bits of the dmap words. the first and last 476 476 * words may only have a subset of their bits updated. if 477 477 * this is the case, we'll work against that word (i.e. 478 - * partial first and/or last) only in a single pass. a 478 + * partial first and/or last) only in a single pass. a 479 479 * single pass will also be used to update all words that 480 480 * are to have all their bits updated. 481 481 */ ··· 662 662 * the block allocation policy uses hints and a multi-step 663 663 * approach. 664 664 * 665 - * for allocation requests smaller than the number of blocks 665 + * for allocation requests smaller than the number of blocks 666 666 * per dmap, we first try to allocate the new blocks 667 667 * immediately following the hint. if these blocks are not 668 668 * available, we try to allocate blocks near the hint. if 669 - * no blocks near the hint are available, we next try to 669 + * no blocks near the hint are available, we next try to 670 670 * allocate within the same dmap as contains the hint. 671 671 * 672 672 * if no blocks are available in the dmap or the allocation ··· 713 713 #endif /* _STILL_TO_PORT */ 714 714 715 715 /* get the log2 number of blocks to be allocated. 716 - * if the number of blocks is not a log2 multiple, 716 + * if the number of blocks is not a log2 multiple, 717 717 * it will be rounded up to the next log2 multiple. 718 718 */ 719 719 l2nb = BLKSTOL2(nblocks); ··· 906 906 * validate extent request: 907 907 * 908 908 * note: defragfs policy: 909 - * max 64 blocks will be moved. 909 + * max 64 blocks will be moved. 910 910 * allocation request size must be satisfied from a single dmap. 911 911 */ 912 912 if (nblocks <= 0 || nblocks > BPERDMAP || blkno >= bmp->db_mapsize) { ··· 1333 1333 * or two sub-trees, depending on the allocation group size. 1334 1334 * we search the top nodes of these subtrees left to right for 1335 1335 * sufficient free space. if sufficient free space is found, 1336 - * the subtree is searched to find the leftmost leaf that 1336 + * the subtree is searched to find the leftmost leaf that 1337 1337 * has free space. once we have made it to the leaf, we 1338 1338 * move the search to the next lower level dmap control page 1339 1339 * corresponding to this leaf. we continue down the dmap control ··· 1398 1398 * that fully describes the allocation group since the allocation 1399 1399 * group is already fully described by a dmap. in this case, we 1400 1400 * just call dbAllocCtl() to search the dmap tree and allocate the 1401 - * required space if available. 1401 + * required space if available. 1402 1402 * 1403 1403 * if the allocation group is completely free, dbAllocCtl() is 1404 1404 * also called to allocate the required space. this is done for ··· 1450 1450 (1 << (L2LPERCTL - (bmp->db_agheigth << 1))) / bmp->db_agwidth; 1451 1451 ti = bmp->db_agstart + bmp->db_agwidth * (agno & (agperlev - 1)); 1452 1452 1453 - /* dmap control page trees fan-out by 4 and a single allocation 1453 + /* dmap control page trees fan-out by 4 and a single allocation 1454 1454 * group may be described by 1 or 2 subtrees within the ag level 1455 1455 * dmap control page, depending upon the ag size. examine the ag's 1456 1456 * subtrees for sufficient free space, starting with the leftmost ··· 1633 1633 1634 1634 /* starting at the specified dmap control page level and block 1635 1635 * number, search down the dmap control levels for the starting 1636 - * block number of a dmap page that contains or starts off 1636 + * block number of a dmap page that contains or starts off 1637 1637 * sufficient free blocks. 1638 1638 */ 1639 1639 for (lev = level, b = *blkno; lev >= 0; lev--) { ··· 1677 1677 } 1678 1678 1679 1679 /* adjust the block number to reflect the location within 1680 - * the dmap control page (i.e. the leaf) at which free 1680 + * the dmap control page (i.e. the leaf) at which free 1681 1681 * space was found. 1682 1682 */ 1683 1683 b += (((s64) leafidx) << budmin); ··· 1700 1700 * NAME: dbAllocCtl() 1701 1701 * 1702 1702 * FUNCTION: attempt to allocate a specified number of contiguous 1703 - * blocks starting within a specific dmap. 1704 - * 1703 + * blocks starting within a specific dmap. 1704 + * 1705 1705 * this routine is called by higher level routines that search 1706 1706 * the dmap control pages above the actual dmaps for contiguous 1707 1707 * free space. the result of successful searches by these 1708 - * routines are the starting block numbers within dmaps, with 1708 + * routines are the starting block numbers within dmaps, with 1709 1709 * the dmaps themselves containing the desired contiguous free 1710 1710 * space or starting a contiguous free space of desired size 1711 1711 * that is made up of the blocks of one or more dmaps. these ··· 1872 1872 * 1873 1873 * FUNCTION: attempt to allocate a specified number of contiguous blocks 1874 1874 * from a specified dmap. 1875 - * 1875 + * 1876 1876 * this routine checks if the contiguous blocks are available. 1877 1877 * if so, nblocks of blocks are allocated; otherwise, ENOSPC is 1878 1878 * returned. 1879 1879 * 1880 1880 * PARAMETERS: 1881 1881 * mp - pointer to bmap descriptor 1882 - * dp - pointer to dmap to attempt to allocate blocks from. 1882 + * dp - pointer to dmap to attempt to allocate blocks from. 1883 1883 * l2nb - log2 number of contiguous block desired. 1884 1884 * nblocks - actual number of contiguous block desired. 1885 1885 * results - on successful return, set to the starting block number ··· 1890 1890 * -ENOSPC - insufficient disk resources 1891 1891 * -EIO - i/o error 1892 1892 * 1893 - * serialization: IREAD_LOCK(ipbmap), e.g., from dbAlloc(), or 1893 + * serialization: IREAD_LOCK(ipbmap), e.g., from dbAlloc(), or 1894 1894 * IWRITE_LOCK(ipbmap), e.g., dbAllocCtl(), held on entry/exit; 1895 1895 */ 1896 1896 static int ··· 2032 2032 2033 2033 /* root changed. bubble the change up to the dmap control pages. 2034 2034 * if the adjustment of the upper level control pages fails, 2035 - * backout the deallocation. 2035 + * backout the deallocation. 2036 2036 */ 2037 2037 if ((rc = dbAdjCtl(bmp, blkno, dp->tree.stree[ROOT], 0, 0))) { 2038 2038 word = (blkno & (BPERDMAP - 1)) >> L2DBWORD; ··· 2245 2245 * words (i.e. partial first and/or last) on an individual basis 2246 2246 * (a single pass), freeing the bits of interest by hand and updating 2247 2247 * the leaf corresponding to the dmap word. a single pass will be used 2248 - * for all dmap words fully contained within the specified range. 2248 + * for all dmap words fully contained within the specified range. 2249 2249 * within this pass, the bits of all fully contained dmap words will 2250 2250 * be marked as free in a single shot and the leaves will be updated. a 2251 2251 * single leaf may describe the free space of multiple dmap words, ··· 2267 2267 */ 2268 2268 if (nb < DBWORD) { 2269 2269 /* free (zero) the appropriate bits within this 2270 - * dmap word. 2270 + * dmap word. 2271 2271 */ 2272 2272 dp->wmap[word] &= 2273 2273 cpu_to_le32(~(ONES << (DBWORD - nb) ··· 2327 2327 2328 2328 BMAP_LOCK(bmp); 2329 2329 2330 - /* update the free count for the allocation group and 2330 + /* update the free count for the allocation group and 2331 2331 * map. 2332 2332 */ 2333 2333 agno = blkno >> bmp->db_agl2size; ··· 2378 2378 * or deallocation resulted in the root change. this range 2379 2379 * is respresented by a single leaf of the current dmapctl 2380 2380 * and the leaf will be updated with this value, possibly 2381 - * causing a binary buddy system within the leaves to be 2381 + * causing a binary buddy system within the leaves to be 2382 2382 * split or joined. the update may also cause the dmapctl's 2383 2383 * dmtree to be updated. 2384 2384 * ··· 2590 2590 } 2591 2591 } 2592 2592 2593 - /* adjust the dmap tree to reflect the specified leaf's new 2593 + /* adjust the dmap tree to reflect the specified leaf's new 2594 2594 * value. 2595 2595 */ 2596 2596 dbAdjTree(tp, leafno, newval); ··· 2638 2638 /* the back split is accomplished by iteratively finding the leaf 2639 2639 * that starts the buddy system that contains the specified leaf and 2640 2640 * splitting that system in two. this iteration continues until 2641 - * the specified leaf becomes the start of a buddy system. 2641 + * the specified leaf becomes the start of a buddy system. 2642 2642 * 2643 2643 * determine maximum possible l2 size for the specified leaf. 2644 2644 */ ··· 2853 2853 * NAME: dbFindLeaf() 2854 2854 * 2855 2855 * FUNCTION: search a dmtree_t for sufficient free blocks, returning 2856 - * the index of a leaf describing the free blocks if 2856 + * the index of a leaf describing the free blocks if 2857 2857 * sufficient free blocks are found. 2858 2858 * 2859 2859 * the search starts at the top of the dmtree_t tree and ··· 2869 2869 * 2870 2870 * RETURN VALUES: 2871 2871 * 0 - success 2872 - * -ENOSPC - insufficient free blocks. 2872 + * -ENOSPC - insufficient free blocks. 2873 2873 */ 2874 2874 static int dbFindLeaf(dmtree_t * tp, int l2nb, int *leafidx) 2875 2875 { ··· 3090 3090 3091 3091 3092 3092 /* 3093 - * NAME: dbAllocBottomUp() 3093 + * NAME: dbAllocBottomUp() 3094 3094 * 3095 3095 * FUNCTION: alloc the specified block range from the working block 3096 3096 * allocation map. ··· 3241 3241 BMAP_LOCK(bmp); 3242 3242 3243 3243 /* if this allocation group is completely free, 3244 - * update the highest active allocation group number 3244 + * update the highest active allocation group number 3245 3245 * if this allocation group is the new max. 3246 3246 */ 3247 3247 agno = blkno >> bmp->db_agl2size; ··· 3273 3273 * NAME: dbExtendFS() 3274 3274 * 3275 3275 * FUNCTION: extend bmap from blkno for nblocks; 3276 - * dbExtendFS() updates bmap ready for dbAllocBottomUp(); 3276 + * dbExtendFS() updates bmap ready for dbAllocBottomUp(); 3277 3277 * 3278 3278 * L2 3279 3279 * | ··· 3284 3284 * d0,...,dn d0,...,dn d0,...,dn d0,...,dn d0,...,dn d0,.,dm; 3285 3285 * L2L1L0d0,...,dnL0d0,...,dnL0d0,...,dnL1L0d0,...,dnL0d0,...,dnL0d0,..dm 3286 3286 * 3287 - * <---old---><----------------------------extend-----------------------> 3287 + * <---old---><----------------------------extend-----------------------> 3288 3288 */ 3289 3289 int dbExtendFS(struct inode *ipbmap, s64 blkno, s64 nblocks) 3290 3290 { ··· 3330 3330 bmp->db_numag += ((u32) newsize % (u32) bmp->db_agsize) ? 1 : 0; 3331 3331 3332 3332 /* 3333 - * reconfigure db_agfree[] 3333 + * reconfigure db_agfree[] 3334 3334 * from old AG configuration to new AG configuration; 3335 3335 * 3336 3336 * coalesce contiguous k (newAGSize/oldAGSize) AGs; ··· 3491 3491 } /* for each dmap in a L0 */ 3492 3492 3493 3493 /* 3494 - * build current L0 page from its leaves, and 3494 + * build current L0 page from its leaves, and 3495 3495 * initialize corresponding parent L1 leaf 3496 3496 */ 3497 3497 *l1leaf = dbInitDmapCtl(l0dcp, 0, ++i); ··· 3515 3515 } /* for each L0 in a L1 */ 3516 3516 3517 3517 /* 3518 - * build current L1 page from its leaves, and 3518 + * build current L1 page from its leaves, and 3519 3519 * initialize corresponding parent L2 leaf 3520 3520 */ 3521 3521 *l2leaf = dbInitDmapCtl(l1dcp, 1, ++j); ··· 3570 3570 * finalize bmap control page 3571 3571 */ 3572 3572 //finalize: 3573 - /* 3573 + /* 3574 3574 * compute db_agpref: preferred ag to allocate from 3575 3575 * (the leftmost ag with average free space in it); 3576 3576 */ ··· 3614 3614 3615 3615 /* 3616 3616 * compute db_aglevel, db_agheigth, db_width, db_agstart: 3617 - * an ag is covered in aglevel dmapctl summary tree, 3618 - * at agheight level height (from leaf) with agwidth number of nodes 3619 - * each, which starts at agstart index node of the smmary tree node 3617 + * an ag is covered in aglevel dmapctl summary tree, 3618 + * at agheight level height (from leaf) with agwidth number of nodes 3619 + * each, which starts at agstart index node of the smmary tree node 3620 3620 * array; 3621 3621 */ 3622 3622 bmp->db_aglevel = BMAPSZTOLEV(bmp->db_agsize); ··· 3635 3635 3636 3636 /* 3637 3637 * NAME: dbInitDmap()/ujfs_idmap_page() 3638 - * 3638 + * 3639 3639 * FUNCTION: initialize working/persistent bitmap of the dmap page 3640 3640 * for the specified number of blocks: 3641 - * 3641 + * 3642 3642 * at entry, the bitmaps had been initialized as free (ZEROS); 3643 - * The number of blocks will only account for the actually 3644 - * existing blocks. Blocks which don't actually exist in 3643 + * The number of blocks will only account for the actually 3644 + * existing blocks. Blocks which don't actually exist in 3645 3645 * the aggregate will be marked as allocated (ONES); 3646 3646 * 3647 3647 * PARAMETERS: ··· 3677 3677 3678 3678 /* 3679 3679 * free the bits corresponding to the block range (ZEROS): 3680 - * note: not all bits of the first and last words may be contained 3680 + * note: not all bits of the first and last words may be contained 3681 3681 * within the block range. 3682 3682 */ 3683 3683 for (r = nblocks; r > 0; r -= nb, blkno += nb) { ··· 3709 3709 } 3710 3710 3711 3711 /* 3712 - * mark bits following the range to be freed (non-existing 3712 + * mark bits following the range to be freed (non-existing 3713 3713 * blocks) as allocated (ONES) 3714 3714 */ 3715 3715 ··· 3741 3741 3742 3742 /* 3743 3743 * NAME: dbInitDmapTree()/ujfs_complete_dmap() 3744 - * 3744 + * 3745 3745 * FUNCTION: initialize summary tree of the specified dmap: 3746 3746 * 3747 3747 * at entry, bitmap of the dmap has been initialized; 3748 - * 3748 + * 3749 3749 * PARAMETERS: 3750 3750 * dp - dmap to complete 3751 3751 * blkno - starting block number for this dmap ··· 3769 3769 3770 3770 /* init each leaf from corresponding wmap word: 3771 3771 * note: leaf is set to NOFREE(-1) if all blocks of corresponding 3772 - * bitmap word are allocated. 3772 + * bitmap word are allocated. 3773 3773 */ 3774 3774 cp = tp->stree + le32_to_cpu(tp->leafidx); 3775 3775 for (i = 0; i < LPERDMAP; i++) ··· 3782 3782 3783 3783 /* 3784 3784 * NAME: dbInitTree()/ujfs_adjtree() 3785 - * 3785 + * 3786 3786 * FUNCTION: initialize binary buddy summary tree of a dmap or dmapctl. 3787 3787 * 3788 - * at entry, the leaves of the tree has been initialized 3788 + * at entry, the leaves of the tree has been initialized 3789 3789 * from corresponding bitmap word or root of summary tree 3790 3790 * of the child control page; 3791 3791 * configure binary buddy system at the leaf level, then ··· 3813 3813 /* 3814 3814 * configure the leaf levevl into binary buddy system 3815 3815 * 3816 - * Try to combine buddies starting with a buddy size of 1 3817 - * (i.e. two leaves). At a buddy size of 1 two buddy leaves 3818 - * can be combined if both buddies have a maximum free of l2min; 3819 - * the combination will result in the left-most buddy leaf having 3820 - * a maximum free of l2min+1. 3821 - * After processing all buddies for a given size, process buddies 3822 - * at the next higher buddy size (i.e. current size * 2) and 3823 - * the next maximum free (current free + 1). 3824 - * This continues until the maximum possible buddy combination 3816 + * Try to combine buddies starting with a buddy size of 1 3817 + * (i.e. two leaves). At a buddy size of 1 two buddy leaves 3818 + * can be combined if both buddies have a maximum free of l2min; 3819 + * the combination will result in the left-most buddy leaf having 3820 + * a maximum free of l2min+1. 3821 + * After processing all buddies for a given size, process buddies 3822 + * at the next higher buddy size (i.e. current size * 2) and 3823 + * the next maximum free (current free + 1). 3824 + * This continues until the maximum possible buddy combination 3825 3825 * yields maximum free. 3826 3826 */ 3827 3827 for (l2free = dtp->budmin, bsize = 1; l2free < l2max; ··· 3845 3845 * bubble summary information of leaves up the tree. 3846 3846 * 3847 3847 * Starting at the leaf node level, the four nodes described by 3848 - * the higher level parent node are compared for a maximum free and 3849 - * this maximum becomes the value of the parent node. 3850 - * when all lower level nodes are processed in this fashion then 3851 - * move up to the next level (parent becomes a lower level node) and 3848 + * the higher level parent node are compared for a maximum free and 3849 + * this maximum becomes the value of the parent node. 3850 + * when all lower level nodes are processed in this fashion then 3851 + * move up to the next level (parent becomes a lower level node) and 3852 3852 * continue the process for that level. 3853 3853 */ 3854 3854 for (child = le32_to_cpu(dtp->leafidx), ··· 3857 3857 /* get index of 1st node of parent level */ 3858 3858 parent = (child - 1) >> 2; 3859 3859 3860 - /* set the value of the parent node as the maximum 3860 + /* set the value of the parent node as the maximum 3861 3861 * of the four nodes of the current level. 3862 3862 */ 3863 3863 for (i = 0, cp = tp + child, cp1 = tp + parent; ··· 3885 3885 dcp->budmin = L2BPERDMAP + L2LPERCTL * level; 3886 3886 3887 3887 /* 3888 - * initialize the leaves of current level that were not covered 3889 - * by the specified input block range (i.e. the leaves have no 3888 + * initialize the leaves of current level that were not covered 3889 + * by the specified input block range (i.e. the leaves have no 3890 3890 * low level dmapctl or dmap). 3891 3891 */ 3892 3892 cp = &dcp->stree[CTLLEAFIND + i]; ··· 3900 3900 3901 3901 /* 3902 3902 * NAME: dbGetL2AGSize()/ujfs_getagl2size() 3903 - * 3903 + * 3904 3904 * FUNCTION: Determine log2(allocation group size) from aggregate size 3905 - * 3905 + * 3906 3906 * PARAMETERS: 3907 3907 * nblocks - Number of blocks in aggregate 3908 3908 * ··· 3935 3935 3936 3936 /* 3937 3937 * NAME: dbMapFileSizeToMapSize() 3938 - * 3939 - * FUNCTION: compute number of blocks the block allocation map file 3938 + * 3939 + * FUNCTION: compute number of blocks the block allocation map file 3940 3940 * can cover from the map file size; 3941 3941 * 3942 3942 * RETURNS: Number of blocks which can be covered by this block map file; ··· 3968 3968 npages = nblocks >> JFS_SBI(sb)->l2nbperpage; 3969 3969 level = BMAPPGTOLEV(npages); 3970 3970 3971 - /* At each level, accumulate the number of dmap pages covered by 3971 + /* At each level, accumulate the number of dmap pages covered by 3972 3972 * the number of full child levels below it; 3973 3973 * repeat for the last incomplete child level. 3974 3974 */ ··· 3990 3990 npages--; 3991 3991 } 3992 3992 3993 - /* convert the number of dmaps into the number of blocks 3993 + /* convert the number of dmaps into the number of blocks 3994 3994 * which can be covered by the dmaps; 3995 3995 */ 3996 3996 nblocks = ndmaps << L2BPERDMAP;
+14 -14
fs/jfs/jfs_dmap.h
··· 1 1 /* 2 - * Copyright (c) International Business Machines Corp., 2000-2002 2 + * Copyright (C) International Business Machines Corp., 2000-2002 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18 #ifndef _H_JFS_DMAP ··· 27 27 #define L2LPERDMAP 8 /* l2 number of leaves per dmap tree */ 28 28 #define DBWORD 32 /* # of blks covered by a map word */ 29 29 #define L2DBWORD 5 /* l2 # of blks covered by a mword */ 30 - #define BUDMIN L2DBWORD /* max free string in a map word */ 30 + #define BUDMIN L2DBWORD /* max free string in a map word */ 31 31 #define BPERDMAP (LPERDMAP * DBWORD) /* num of blks per dmap */ 32 32 #define L2BPERDMAP 13 /* l2 num of blks per dmap */ 33 33 #define CTLTREESIZE (1024+256+64+16+4+1) /* size of a dmapctl tree */ ··· 57 57 58 58 #define MAXMAPSIZE MAXL2SIZE /* maximum aggregate map size */ 59 59 60 - /* 60 + /* 61 61 * determine the maximum free string for four (lower level) nodes 62 62 * of the tree. 63 63 */ ··· 122 122 #define BLKTOCTL(b,s,l) \ 123 123 (((l) == 2) ? 1 : ((l) == 1) ? BLKTOL1((b),(s)) : BLKTOL0((b),(s))) 124 124 125 - /* 125 + /* 126 126 * convert aggregate map size to the zero origin dmapctl level of the 127 127 * top dmapctl. 128 128 */ ··· 192 192 193 193 /* macros for accessing fields within dmtree */ 194 194 #define dmt_nleafs t1.nleafs 195 - #define dmt_l2nleafs t1.l2nleafs 196 - #define dmt_leafidx t1.leafidx 197 - #define dmt_height t1.height 198 - #define dmt_budmin t1.budmin 199 - #define dmt_stree t1.stree 195 + #define dmt_l2nleafs t1.l2nleafs 196 + #define dmt_leafidx t1.leafidx 197 + #define dmt_height t1.height 198 + #define dmt_budmin t1.budmin 199 + #define dmt_stree t1.stree 200 200 201 - /* 201 + /* 202 202 * on-disk aggregate disk allocation map descriptor. 203 203 */ 204 204 struct dbmap_disk { ··· 237 237 s64 dn_agsize; /* num of blks per alloc group */ 238 238 signed char dn_maxfreebud; /* max free buddy system */ 239 239 }; /* - 4096 - */ 240 - /* 240 + /* 241 241 * in-memory aggregate disk allocation map descriptor. 242 242 */ 243 243 struct bmap {
+7 -7
fs/jfs/jfs_dtree.c
··· 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18 ··· 78 78 * 79 79 * case-insensitive search: 80 80 * 81 - * fold search key; 81 + * fold search key; 82 82 * 83 83 * case-insensitive search of B-tree: 84 84 * for internal entry, router key is already folded; ··· 93 93 * else 94 94 * return no match; 95 95 * 96 - * serialization: 96 + * serialization: 97 97 * target directory inode lock is being held on entry/exit 98 98 * of all main directory service routines. 99 99 * ··· 925 925 * 926 926 * return: 0 - success; 927 927 * errno - failure; 928 - * leaf page unpinned; 928 + * leaf page unpinned; 929 929 */ 930 930 static int dtSplitUp(tid_t tid, 931 931 struct inode *ip, struct dtsplit * split, struct btstack * btstack) ··· 3767 3767 * across page boundary 3768 3768 * 3769 3769 * return: non-zero on error 3770 - * 3770 + * 3771 3771 */ 3772 3772 static int ciGetLeafPrefixKey(dtpage_t * lp, int li, dtpage_t * rp, 3773 3773 int ri, struct component_name * key, int flag)
+5 -5
fs/jfs/jfs_dtree.h
··· 1 1 /* 2 - * Copyright (c) International Business Machines Corp., 2000-2002 2 + * Copyright (C) International Business Machines Corp., 2000-2002 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18 #ifndef _H_JFS_DTREE ··· 80 80 /* 81 81 * leaf node entry head/only segment 82 82 * 83 - * For legacy filesystems, name contains 13 wchars -- no index field 83 + * For legacy filesystems, name contains 13 wchars -- no index field 84 84 */ 85 85 struct ldtentry { 86 86 __le32 inumber; /* 4: 4-byte aligned */
+21 -21
fs/jfs/jfs_extent.c
··· 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18 ··· 125 125 } 126 126 127 127 /* allocate the disk blocks for the extent. initially, extBalloc() 128 - * will try to allocate disk blocks for the requested size (xlen). 128 + * will try to allocate disk blocks for the requested size (xlen). 129 129 * if this fails (xlen contiguous free blocks not avaliable), it'll 130 130 * try to allocate a smaller number of blocks (producing a smaller 131 131 * extent), with this smaller number of blocks consisting of the ··· 150 150 /* determine the value of the extent flag */ 151 151 xflag = abnr ? XAD_NOTRECORDED : 0; 152 152 153 - /* if we can extend the hint extent to cover the current request, 153 + /* if we can extend the hint extent to cover the current request, 154 154 * extend it. otherwise, insert a new extent to 155 155 * cover the current request. 156 156 */ ··· 159 159 else 160 160 rc = xtInsert(0, ip, xflag, xoff, (int) nxlen, &nxaddr, 0); 161 161 162 - /* if the extend or insert failed, 162 + /* if the extend or insert failed, 163 163 * free the newly allocated blocks and return the error. 164 164 */ 165 165 if (rc) { ··· 235 235 xoff = offsetXAD(xp); 236 236 237 237 /* if the extend page is abnr and if the request is for 238 - * the extent to be allocated and recorded, 238 + * the extent to be allocated and recorded, 239 239 * make the page allocated and recorded. 240 240 */ 241 241 if ((xp->flag & XAD_NOTRECORDED) && !abnr) { ··· 397 397 if ((rc = xtLookupList(ip, &lxdl, &xadl, 0))) 398 398 return (rc); 399 399 400 - /* check if not extent exists for the previous page. 400 + /* check if not extent exists for the previous page. 401 401 * this is possible for sparse files. 402 402 */ 403 403 if (xadl.nxad == 0) { ··· 410 410 */ 411 411 xp->flag &= XAD_NOTRECORDED; 412 412 413 - if(xadl.nxad != 1 || lengthXAD(xp) != nbperpage) { 413 + if(xadl.nxad != 1 || lengthXAD(xp) != nbperpage) { 414 414 jfs_error(ip->i_sb, "extHint: corrupt xtree"); 415 415 return -EIO; 416 416 } ··· 492 492 * FUNCTION: allocate disk blocks to form an extent. 493 493 * 494 494 * initially, we will try to allocate disk blocks for the 495 - * requested size (nblocks). if this fails (nblocks 495 + * requested size (nblocks). if this fails (nblocks 496 496 * contiguous free blocks not avaliable), we'll try to allocate 497 497 * a smaller number of blocks (producing a smaller extent), with 498 498 * this smaller number of blocks consisting of the requested ··· 500 500 * number (i.e. 16 -> 8). we'll continue to round down and 501 501 * retry the allocation until the number of blocks to allocate 502 502 * is smaller than the number of blocks per page. 503 - * 503 + * 504 504 * PARAMETERS: 505 505 * ip - the inode of the file. 506 506 * hint - disk block number to be used as an allocation hint. ··· 509 509 * exit, this value is set to the number of blocks actually 510 510 * allocated. 511 511 * blkno - pointer to a block address that is filled in on successful 512 - * return with the starting block number of the newly 512 + * return with the starting block number of the newly 513 513 * allocated block range. 514 514 * 515 515 * RETURN VALUES: ··· 530 530 /* get the number of blocks to initially attempt to allocate. 531 531 * we'll first try the number of blocks requested unless this 532 532 * number is greater than the maximum number of contiguous free 533 - * blocks in the map. in that case, we'll start off with the 533 + * blocks in the map. in that case, we'll start off with the 534 534 * maximum free. 535 535 */ 536 536 max = (s64) 1 << bmp->db_maxfreebud; ··· 582 582 * 583 583 * FUNCTION: attempt to extend an extent's allocation. 584 584 * 585 - * initially, we will try to extend the extent's allocation 586 - * in place. if this fails, we'll try to move the extent 587 - * to a new set of blocks. if moving the extent, we initially 585 + * Initially, we will try to extend the extent's allocation 586 + * in place. If this fails, we'll try to move the extent 587 + * to a new set of blocks. If moving the extent, we initially 588 588 * will try to allocate disk blocks for the requested size 589 - * (nnew). if this fails (new contiguous free blocks not 590 - * avaliable), we'll try to allocate a smaller number of 589 + * (newnblks). if this fails (new contiguous free blocks not 590 + * avaliable), we'll try to allocate a smaller number of 591 591 * blocks (producing a smaller extent), with this smaller 592 592 * number of blocks consisting of the requested number of 593 593 * blocks rounded down to the next smaller power of 2 594 - * number (i.e. 16 -> 8). we'll continue to round down and 594 + * number (i.e. 16 -> 8). We'll continue to round down and 595 595 * retry the allocation until the number of blocks to allocate 596 596 * is smaller than the number of blocks per page. 597 - * 597 + * 598 598 * PARAMETERS: 599 599 * ip - the inode of the file. 600 600 * blkno - starting block number of the extents current allocation. ··· 625 625 return (rc); 626 626 } 627 627 628 - /* in place extension not possible. 628 + /* in place extension not possible. 629 629 * try to move the extent to a new set of blocks. 630 630 */ 631 631 return (extBalloc(ip, blkno, newnblks, newblkno));
+4 -4
fs/jfs/jfs_extent.h
··· 1 1 /* 2 - * Copyright (c) International Business Machines Corp., 2000-2001 2 + * Copyright (C) International Business Machines Corp., 2000-2001 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18 #ifndef _H_JFS_EXTENT
+12 -12
fs/jfs/jfs_filsys.h
··· 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18 #ifndef _H_JFS_FILSYS ··· 21 21 /* 22 22 * jfs_filsys.h 23 23 * 24 - * file system (implementation-dependent) constants 24 + * file system (implementation-dependent) constants 25 25 * 26 - * refer to <limits.h> for system wide implementation-dependent constants 26 + * refer to <limits.h> for system wide implementation-dependent constants 27 27 */ 28 28 29 29 /* ··· 49 49 50 50 #define JFS_DFS 0x20000000 /* DCE DFS LFS support */ 51 51 52 - #define JFS_LINUX 0x10000000 /* Linux support */ 52 + #define JFS_LINUX 0x10000000 /* Linux support */ 53 53 /* case-sensitive name/directory support */ 54 54 55 55 /* directory option */ ··· 59 59 #define JFS_COMMIT 0x00000f00 /* commit option mask */ 60 60 #define JFS_GROUPCOMMIT 0x00000100 /* group (of 1) commit */ 61 61 #define JFS_LAZYCOMMIT 0x00000200 /* lazy commit */ 62 - #define JFS_TMPFS 0x00000400 /* temporary file system - 62 + #define JFS_TMPFS 0x00000400 /* temporary file system - 63 63 * do not log/commit: 64 64 */ 65 65 ··· 196 196 * followed by 1st extent of map 197 197 */ 198 198 #define AITBL_OFF (AIMAP_OFF + (SIZE_OF_MAP_PAGE << 1)) 199 - /* 199 + /* 200 200 * 1st extent of aggregate inode table 201 201 */ 202 202 #define SUPER2_OFF (AITBL_OFF + INODE_EXTENT_SIZE) ··· 270 270 */ 271 271 #define FM_CLEAN 0x00000000 /* file system is unmounted and clean */ 272 272 #define FM_MOUNT 0x00000001 /* file system is mounted cleanly */ 273 - #define FM_DIRTY 0x00000002 /* file system was not unmounted and clean 274 - * when mounted or 273 + #define FM_DIRTY 0x00000002 /* file system was not unmounted and clean 274 + * when mounted or 275 275 * commit failure occurred while being mounted: 276 - * fsck() must be run to repair 276 + * fsck() must be run to repair 277 277 */ 278 278 #define FM_LOGREDO 0x00000004 /* log based recovery (logredo()) failed: 279 - * fsck() must be run to repair 279 + * fsck() must be run to repair 280 280 */ 281 281 #define FM_EXTENDFS 0x00000008 /* file system extendfs() in progress */ 282 282
+111 -111
fs/jfs/jfs_imap.c
··· 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18 ··· 98 98 * FUNCTION: initialize the incore inode map control structures for 99 99 * a fileset or aggregate init time. 100 100 * 101 - * the inode map's control structure (dinomap) is 101 + * the inode map's control structure (dinomap) is 102 102 * brought in from disk and placed in virtual memory. 103 103 * 104 104 * PARAMETERS: ··· 107 107 * RETURN VALUES: 108 108 * 0 - success 109 109 * -ENOMEM - insufficient free virtual memory. 110 - * -EIO - i/o error. 110 + * -EIO - i/o error. 111 111 */ 112 112 int diMount(struct inode *ipimap) 113 113 { ··· 191 191 * RETURN VALUES: 192 192 * 0 - success 193 193 * -ENOMEM - insufficient free virtual memory. 194 - * -EIO - i/o error. 194 + * -EIO - i/o error. 195 195 */ 196 196 int diUnmount(struct inode *ipimap, int mounterror) 197 197 { ··· 281 281 * on entry, the specifed incore inode should itself 282 282 * specify the disk inode number corresponding to the 283 283 * incore inode (i.e. i_number should be initialized). 284 - * 284 + * 285 285 * this routine handles incore inode initialization for 286 286 * both "special" and "regular" inodes. special inodes 287 287 * are those required early in the mount process and ··· 289 289 * is not yet initialized. these "special" inodes are 290 290 * identified by a NULL inode map inode pointer and are 291 291 * actually initialized by a call to diReadSpecial(). 292 - * 292 + * 293 293 * for regular inodes, the iag describing the disk inode 294 294 * is read from disk to determine the inode extent address 295 295 * for the disk inode. with the inode extent address in ··· 302 302 * 303 303 * RETURN VALUES: 304 304 * 0 - success 305 - * -EIO - i/o error. 305 + * -EIO - i/o error. 306 306 * -ENOMEM - insufficient memory 307 - * 307 + * 308 308 */ 309 309 int diRead(struct inode *ip) 310 310 { ··· 586 586 * page of the extent that contains the disk inode is 587 587 * read and the disk inode portion of the incore inode 588 588 * is copied to the disk inode. 589 - * 589 + * 590 590 * PARAMETERS: 591 591 * tid - transacation id 592 592 * ip - pointer to incore inode to be written to the inode extent. 593 593 * 594 594 * RETURN VALUES: 595 595 * 0 - success 596 - * -EIO - i/o error. 596 + * -EIO - i/o error. 597 597 */ 598 598 int diWrite(tid_t tid, struct inode *ip) 599 599 { ··· 676 676 * copy btree root from in-memory inode to on-disk inode 677 677 * 678 678 * (tlock is taken from inline B+-tree root in in-memory 679 - * inode when the B+-tree root is updated, which is pointed 679 + * inode when the B+-tree root is updated, which is pointed 680 680 * by jfs_ip->blid as well as being on tx tlock list) 681 681 * 682 - * further processing of btree root is based on the copy 683 - * in in-memory inode, where txLog() will log from, and, 682 + * further processing of btree root is based on the copy 683 + * in in-memory inode, where txLog() will log from, and, 684 684 * for xtree root, txUpdateMap() will update map and reset 685 685 * XAD_NEW bit; 686 686 */ ··· 824 824 memcpy(&dp->di_DASD, &ip->i_DASD, sizeof(struct dasd)); 825 825 #endif /* _JFS_FASTDASD */ 826 826 827 - /* release the buffer holding the updated on-disk inode. 827 + /* release the buffer holding the updated on-disk inode. 828 828 * the buffer will be later written by commit processing. 829 829 */ 830 830 write_metapage(mp); ··· 842 842 * if the inode to be freed represents the first (only) 843 843 * free inode within the iag, the iag will be placed on 844 844 * the ag free inode list. 845 - * 845 + * 846 846 * freeing the inode will cause the inode extent to be 847 847 * freed if the inode is the only allocated inode within 848 848 * the extent. in this case all the disk resource backing ··· 865 865 * any updates and are held until all updates are complete. 866 866 * 867 867 * PARAMETERS: 868 - * ip - inode to be freed. 868 + * ip - inode to be freed. 869 869 * 870 870 * RETURN VALUES: 871 871 * 0 - success 872 - * -EIO - i/o error. 872 + * -EIO - i/o error. 873 873 */ 874 874 int diFree(struct inode *ip) 875 875 { ··· 898 898 */ 899 899 iagno = INOTOIAG(inum); 900 900 901 - /* make sure that the iag is contained within 901 + /* make sure that the iag is contained within 902 902 * the map. 903 903 */ 904 904 if (iagno >= imap->im_nextiag) { ··· 1013 1013 1014 1014 /* update the free inode summary map for the extent if 1015 1015 * freeing the inode means the extent will now have free 1016 - * inodes (i.e., the inode being freed is the first free 1016 + * inodes (i.e., the inode being freed is the first free 1017 1017 * inode of extent), 1018 1018 */ 1019 1019 if (iagp->wmap[extno] == cpu_to_le32(ONES)) { ··· 1204 1204 iagp->inofreefwd = iagp->inofreeback = cpu_to_le32(-1); 1205 1205 } 1206 1206 1207 - /* update the inode extent address and working map 1207 + /* update the inode extent address and working map 1208 1208 * to reflect the free extent. 1209 - * the permanent map should have been updated already 1209 + * the permanent map should have been updated already 1210 1210 * for the inode being freed. 1211 1211 */ 1212 1212 if (iagp->pmap[extno] != 0) { ··· 1218 1218 1219 1219 /* update the free extent and free inode summary maps 1220 1220 * to reflect the freed extent. 1221 - * the inode summary map is marked to indicate no inodes 1221 + * the inode summary map is marked to indicate no inodes 1222 1222 * available for the freed extent. 1223 1223 */ 1224 1224 sword = extno >> L2EXTSPERSUM; ··· 1255 1255 * start transaction to update block allocation map 1256 1256 * for the inode extent freed; 1257 1257 * 1258 - * N.B. AG_LOCK is released and iag will be released below, and 1258 + * N.B. AG_LOCK is released and iag will be released below, and 1259 1259 * other thread may allocate inode from/reusing the ixad freed 1260 - * BUT with new/different backing inode extent from the extent 1261 - * to be freed by the transaction; 1260 + * BUT with new/different backing inode extent from the extent 1261 + * to be freed by the transaction; 1262 1262 */ 1263 1263 tid = txBegin(ipimap->i_sb, COMMIT_FORCE); 1264 1264 mutex_lock(&JFS_IP(ipimap)->commit_mutex); 1265 1265 1266 - /* acquire tlock of the iag page of the freed ixad 1266 + /* acquire tlock of the iag page of the freed ixad 1267 1267 * to force the page NOHOMEOK (even though no data is 1268 - * logged from the iag page) until NOREDOPAGE|FREEXTENT log 1268 + * logged from the iag page) until NOREDOPAGE|FREEXTENT log 1269 1269 * for the free of the extent is committed; 1270 1270 * write FREEXTENT|NOREDOPAGE log record 1271 1271 * N.B. linelock is overlaid as freed extent descriptor; ··· 1284 1284 * logredo needs the IAG number and IAG extent index in order 1285 1285 * to ensure that the IMap is consistent. The least disruptive 1286 1286 * way to pass these values through to the transaction manager 1287 - * is in the iplist array. 1288 - * 1287 + * is in the iplist array. 1288 + * 1289 1289 * It's not pretty, but it works. 1290 1290 */ 1291 1291 iplist[1] = (struct inode *) (size_t)iagno; ··· 1340 1340 /* 1341 1341 * NAME: diAlloc(pip,dir,ip) 1342 1342 * 1343 - * FUNCTION: allocate a disk inode from the inode working map 1343 + * FUNCTION: allocate a disk inode from the inode working map 1344 1344 * for a fileset or aggregate. 1345 1345 * 1346 1346 * PARAMETERS: 1347 - * pip - pointer to incore inode for the parent inode. 1348 - * dir - 'true' if the new disk inode is for a directory. 1349 - * ip - pointer to a new inode 1347 + * pip - pointer to incore inode for the parent inode. 1348 + * dir - 'true' if the new disk inode is for a directory. 1349 + * ip - pointer to a new inode 1350 1350 * 1351 1351 * RETURN VALUES: 1352 1352 * 0 - success. 1353 1353 * -ENOSPC - insufficient disk resources. 1354 - * -EIO - i/o error. 1354 + * -EIO - i/o error. 1355 1355 */ 1356 1356 int diAlloc(struct inode *pip, bool dir, struct inode *ip) 1357 1357 { ··· 1372 1372 JFS_IP(ip)->ipimap = ipimap; 1373 1373 JFS_IP(ip)->fileset = FILESYSTEM_I; 1374 1374 1375 - /* for a directory, the allocation policy is to start 1375 + /* for a directory, the allocation policy is to start 1376 1376 * at the ag level using the preferred ag. 1377 1377 */ 1378 1378 if (dir) { ··· 1435 1435 /* 1436 1436 * try to allocate from the IAG 1437 1437 */ 1438 - /* check if the inode may be allocated from the iag 1438 + /* check if the inode may be allocated from the iag 1439 1439 * (i.e. the inode has free inodes or new extent can be added). 1440 1440 */ 1441 1441 if (iagp->nfreeinos || addext) { ··· 1490 1490 * hint or, if appropriate (i.e. addext is true), allocate 1491 1491 * an extent of free inodes at or following the extent 1492 1492 * containing the hint. 1493 - * 1493 + * 1494 1494 * the free inode and free extent summary maps are used 1495 1495 * here, so determine the starting summary map position 1496 1496 * and the number of words we'll have to examine. again, ··· 1641 1641 * inodes should be added for the allocation group, with 1642 1642 * the current request satisfied from this extent. if this 1643 1643 * is the case, an attempt will be made to do just that. if 1644 - * this attempt fails or it has been determined that a new 1644 + * this attempt fails or it has been determined that a new 1645 1645 * extent should not be added, an attempt is made to satisfy 1646 1646 * the request by allocating an existing (backed) free inode 1647 1647 * from the allocation group. ··· 1649 1649 * PRE CONDITION: Already have the AG lock for this AG. 1650 1650 * 1651 1651 * PARAMETERS: 1652 - * imap - pointer to inode map control structure. 1653 - * agno - allocation group to allocate from. 1654 - * dir - 'true' if the new disk inode is for a directory. 1655 - * ip - pointer to the new inode to be filled in on successful return 1652 + * imap - pointer to inode map control structure. 1653 + * agno - allocation group to allocate from. 1654 + * dir - 'true' if the new disk inode is for a directory. 1655 + * ip - pointer to the new inode to be filled in on successful return 1656 1656 * with the disk inode number allocated, its extent address 1657 1657 * and the start of the ag. 1658 1658 * 1659 1659 * RETURN VALUES: 1660 1660 * 0 - success. 1661 1661 * -ENOSPC - insufficient disk resources. 1662 - * -EIO - i/o error. 1662 + * -EIO - i/o error. 1663 1663 */ 1664 1664 static int 1665 1665 diAllocAG(struct inomap * imap, int agno, bool dir, struct inode *ip) 1666 1666 { 1667 1667 int rc, addext, numfree, numinos; 1668 1668 1669 - /* get the number of free and the number of backed disk 1669 + /* get the number of free and the number of backed disk 1670 1670 * inodes currently within the ag. 1671 1671 */ 1672 1672 numfree = imap->im_agctl[agno].numfree; ··· 1719 1719 * specified primary group. 1720 1720 * 1721 1721 * PARAMETERS: 1722 - * imap - pointer to inode map control structure. 1723 - * agno - primary allocation group (to avoid). 1724 - * dir - 'true' if the new disk inode is for a directory. 1725 - * ip - pointer to a new inode to be filled in on successful return 1722 + * imap - pointer to inode map control structure. 1723 + * agno - primary allocation group (to avoid). 1724 + * dir - 'true' if the new disk inode is for a directory. 1725 + * ip - pointer to a new inode to be filled in on successful return 1726 1726 * with the disk inode number allocated, its extent address 1727 1727 * and the start of the ag. 1728 1728 * 1729 1729 * RETURN VALUES: 1730 1730 * 0 - success. 1731 1731 * -ENOSPC - insufficient disk resources. 1732 - * -EIO - i/o error. 1732 + * -EIO - i/o error. 1733 1733 */ 1734 1734 static int 1735 1735 diAllocAny(struct inomap * imap, int agno, bool dir, struct inode *ip) ··· 1738 1738 int maxag = JFS_SBI(imap->im_ipimap->i_sb)->bmap->db_maxag; 1739 1739 1740 1740 1741 - /* try to allocate from the ags following agno up to 1741 + /* try to allocate from the ags following agno up to 1742 1742 * the maximum ag number. 1743 1743 */ 1744 1744 for (ag = agno + 1; ag <= maxag; ag++) { ··· 1780 1780 * 1781 1781 * allocation occurs from the first iag on the list using 1782 1782 * the iag's free inode summary map to find the leftmost 1783 - * free inode in the iag. 1784 - * 1783 + * free inode in the iag. 1784 + * 1785 1785 * PRE CONDITION: Already have AG lock for this AG. 1786 - * 1786 + * 1787 1787 * PARAMETERS: 1788 - * imap - pointer to inode map control structure. 1789 - * agno - allocation group. 1790 - * ip - pointer to new inode to be filled in on successful return 1788 + * imap - pointer to inode map control structure. 1789 + * agno - allocation group. 1790 + * ip - pointer to new inode to be filled in on successful return 1791 1791 * with the disk inode number allocated, its extent address 1792 1792 * and the start of the ag. 1793 1793 * 1794 1794 * RETURN VALUES: 1795 1795 * 0 - success. 1796 1796 * -ENOSPC - insufficient disk resources. 1797 - * -EIO - i/o error. 1797 + * -EIO - i/o error. 1798 1798 */ 1799 1799 static int diAllocIno(struct inomap * imap, int agno, struct inode *ip) 1800 1800 { ··· 1867 1867 return -EIO; 1868 1868 } 1869 1869 1870 - /* compute the inode number within the iag. 1870 + /* compute the inode number within the iag. 1871 1871 */ 1872 1872 ino = (extno << L2INOSPEREXT) + rem; 1873 1873 ··· 1892 1892 /* 1893 1893 * NAME: diAllocExt(imap,agno,ip) 1894 1894 * 1895 - * FUNCTION: add a new extent of free inodes to an iag, allocating 1896 - * an inode from this extent to satisfy the current allocation 1897 - * request. 1898 - * 1895 + * FUNCTION: add a new extent of free inodes to an iag, allocating 1896 + * an inode from this extent to satisfy the current allocation 1897 + * request. 1898 + * 1899 1899 * this routine first tries to find an existing iag with free 1900 1900 * extents through the ag free extent list. if list is not 1901 1901 * empty, the head of the list will be selected as the home 1902 1902 * of the new extent of free inodes. otherwise (the list is 1903 1903 * empty), a new iag will be allocated for the ag to contain 1904 1904 * the extent. 1905 - * 1905 + * 1906 1906 * once an iag has been selected, the free extent summary map 1907 1907 * is used to locate a free extent within the iag and diNewExt() 1908 1908 * is called to initialize the extent, with initialization ··· 1910 1910 * for the purpose of satisfying this request. 1911 1911 * 1912 1912 * PARAMETERS: 1913 - * imap - pointer to inode map control structure. 1914 - * agno - allocation group number. 1915 - * ip - pointer to new inode to be filled in on successful return 1913 + * imap - pointer to inode map control structure. 1914 + * agno - allocation group number. 1915 + * ip - pointer to new inode to be filled in on successful return 1916 1916 * with the disk inode number allocated, its extent address 1917 1917 * and the start of the ag. 1918 1918 * 1919 1919 * RETURN VALUES: 1920 1920 * 0 - success. 1921 1921 * -ENOSPC - insufficient disk resources. 1922 - * -EIO - i/o error. 1922 + * -EIO - i/o error. 1923 1923 */ 1924 1924 static int diAllocExt(struct inomap * imap, int agno, struct inode *ip) 1925 1925 { ··· 2012 2012 /* 2013 2013 * NAME: diAllocBit(imap,iagp,ino) 2014 2014 * 2015 - * FUNCTION: allocate a backed inode from an iag. 2015 + * FUNCTION: allocate a backed inode from an iag. 2016 2016 * 2017 2017 * this routine performs the mechanics of allocating a 2018 2018 * specified inode from a backed extent. ··· 2025 2025 * in the face of updates to multiple buffers. under this 2026 2026 * approach, all required buffers are obtained before making 2027 2027 * any updates and are held all are updates are complete. 2028 - * 2028 + * 2029 2029 * PRE CONDITION: Already have buffer lock on iagp. Already have AG lock on 2030 2030 * this AG. Must have read lock on imap inode. 2031 2031 * 2032 2032 * PARAMETERS: 2033 - * imap - pointer to inode map control structure. 2034 - * iagp - pointer to iag. 2035 - * ino - inode number to be allocated within the iag. 2033 + * imap - pointer to inode map control structure. 2034 + * iagp - pointer to iag. 2035 + * ino - inode number to be allocated within the iag. 2036 2036 * 2037 2037 * RETURN VALUES: 2038 2038 * 0 - success. 2039 2039 * -ENOSPC - insufficient disk resources. 2040 - * -EIO - i/o error. 2040 + * -EIO - i/o error. 2041 2041 */ 2042 2042 static int diAllocBit(struct inomap * imap, struct iag * iagp, int ino) 2043 2043 { ··· 2172 2172 * buffers. under this approach, all required buffers are 2173 2173 * obtained before making any updates and are held until all 2174 2174 * updates are complete. 2175 - * 2175 + * 2176 2176 * PRE CONDITION: Already have buffer lock on iagp. Already have AG lock on 2177 2177 * this AG. Must have read lock on imap inode. 2178 2178 * 2179 2179 * PARAMETERS: 2180 - * imap - pointer to inode map control structure. 2181 - * iagp - pointer to iag. 2182 - * extno - extent number. 2180 + * imap - pointer to inode map control structure. 2181 + * iagp - pointer to iag. 2182 + * extno - extent number. 2183 2183 * 2184 2184 * RETURN VALUES: 2185 2185 * 0 - success. 2186 2186 * -ENOSPC - insufficient disk resources. 2187 - * -EIO - i/o error. 2187 + * -EIO - i/o error. 2188 2188 */ 2189 2189 static int diNewExt(struct inomap * imap, struct iag * iagp, int extno) 2190 2190 { ··· 2432 2432 /* 2433 2433 * NAME: diNewIAG(imap,iagnop,agno) 2434 2434 * 2435 - * FUNCTION: allocate a new iag for an allocation group. 2436 - * 2437 - * first tries to allocate the iag from the inode map 2438 - * iagfree list: 2439 - * if the list has free iags, the head of the list is removed 2435 + * FUNCTION: allocate a new iag for an allocation group. 2436 + * 2437 + * first tries to allocate the iag from the inode map 2438 + * iagfree list: 2439 + * if the list has free iags, the head of the list is removed 2440 2440 * and returned to satisfy the request. 2441 2441 * if the inode map's iag free list is empty, the inode map 2442 2442 * is extended to hold a new iag. this new iag is initialized 2443 2443 * and returned to satisfy the request. 2444 2444 * 2445 2445 * PARAMETERS: 2446 - * imap - pointer to inode map control structure. 2447 - * iagnop - pointer to an iag number set with the number of the 2446 + * imap - pointer to inode map control structure. 2447 + * iagnop - pointer to an iag number set with the number of the 2448 2448 * newly allocated iag upon successful return. 2449 - * agno - allocation group number. 2449 + * agno - allocation group number. 2450 2450 * bpp - Buffer pointer to be filled in with new IAG's buffer 2451 2451 * 2452 2452 * RETURN VALUES: 2453 2453 * 0 - success. 2454 2454 * -ENOSPC - insufficient disk resources. 2455 - * -EIO - i/o error. 2455 + * -EIO - i/o error. 2456 2456 * 2457 - * serialization: 2457 + * serialization: 2458 2458 * AG lock held on entry/exit; 2459 2459 * write lock on the map is held inside; 2460 2460 * read lock on the map is held on successful completion; 2461 2461 * 2462 - * note: new iag transaction: 2462 + * note: new iag transaction: 2463 2463 * . synchronously write iag; 2464 2464 * . write log of xtree and inode of imap; 2465 2465 * . commit; ··· 2494 2494 /* acquire the free iag lock */ 2495 2495 IAGFREE_LOCK(imap); 2496 2496 2497 - /* if there are any iags on the inode map free iag list, 2497 + /* if there are any iags on the inode map free iag list, 2498 2498 * allocate the iag from the head of the list. 2499 2499 */ 2500 2500 if (imap->im_freeiag >= 0) { ··· 2618 2618 flush_metapage(mp); 2619 2619 2620 2620 /* 2621 - * txCommit(COMMIT_FORCE) will synchronously write address 2622 - * index pages and inode after commit in careful update order 2621 + * txCommit(COMMIT_FORCE) will synchronously write address 2622 + * index pages and inode after commit in careful update order 2623 2623 * of address index pages (right to left, bottom up); 2624 2624 */ 2625 2625 iplist[0] = ipimap; ··· 2678 2678 * 2679 2679 * FUNCTION: get the buffer for the specified iag within a fileset 2680 2680 * or aggregate inode map. 2681 - * 2681 + * 2682 2682 * PARAMETERS: 2683 - * imap - pointer to inode map control structure. 2684 - * iagno - iag number. 2685 - * bpp - point to buffer pointer to be filled in on successful 2683 + * imap - pointer to inode map control structure. 2684 + * iagno - iag number. 2685 + * bpp - point to buffer pointer to be filled in on successful 2686 2686 * exit. 2687 2687 * 2688 2688 * SERIALIZATION: ··· 2692 2692 * 2693 2693 * RETURN VALUES: 2694 2694 * 0 - success. 2695 - * -EIO - i/o error. 2695 + * -EIO - i/o error. 2696 2696 */ 2697 2697 static int diIAGRead(struct inomap * imap, int iagno, struct metapage ** mpp) 2698 2698 { ··· 2718 2718 * the specified bit position. 2719 2719 * 2720 2720 * PARAMETERS: 2721 - * word - word to be examined. 2722 - * start - starting bit position. 2721 + * word - word to be examined. 2722 + * start - starting bit position. 2723 2723 * 2724 2724 * RETURN VALUES: 2725 2725 * bit position of first free bit in the word or 32 if ··· 2740 2740 2741 2741 /* 2742 2742 * NAME: diUpdatePMap() 2743 - * 2744 - * FUNCTION: Update the persistent map in an IAG for the allocation or 2743 + * 2744 + * FUNCTION: Update the persistent map in an IAG for the allocation or 2745 2745 * freeing of the specified inode. 2746 - * 2746 + * 2747 2747 * PRE CONDITIONS: Working map has already been updated for allocate. 2748 2748 * 2749 2749 * PARAMETERS: ··· 2752 2752 * is_free - If 'true' indicates inode should be marked freed, otherwise 2753 2753 * indicates inode should be marked allocated. 2754 2754 * 2755 - * RETURN VALUES: 2755 + * RETURN VALUES: 2756 2756 * 0 for success 2757 2757 */ 2758 2758 int ··· 2793 2793 extno = ino >> L2INOSPEREXT; 2794 2794 bitno = ino & (INOSPEREXT - 1); 2795 2795 mask = HIGHORDER >> bitno; 2796 - /* 2796 + /* 2797 2797 * mark the inode free in persistent map: 2798 2798 */ 2799 2799 if (is_free) { ··· 2803 2803 * of last reference release; 2804 2804 */ 2805 2805 if (!(le32_to_cpu(iagp->wmap[extno]) & mask)) { 2806 - jfs_error(ipimap->i_sb, 2806 + jfs_error(ipimap->i_sb, 2807 2807 "diUpdatePMap: inode %ld not marked as " 2808 2808 "allocated in wmap!", inum); 2809 2809 } ··· 2877 2877 * diExtendFS() 2878 2878 * 2879 2879 * function: update imap for extendfs(); 2880 - * 2881 - * note: AG size has been increased s.t. each k old contiguous AGs are 2880 + * 2881 + * note: AG size has been increased s.t. each k old contiguous AGs are 2882 2882 * coalesced into a new AG; 2883 2883 */ 2884 2884 int diExtendFS(struct inode *ipimap, struct inode *ipbmap) ··· 2897 2897 atomic_read(&imap->im_numfree)); 2898 2898 2899 2899 /* 2900 - * reconstruct imap 2900 + * reconstruct imap 2901 2901 * 2902 2902 * coalesce contiguous k (newAGSize/oldAGSize) AGs; 2903 2903 * i.e., (AGi, ..., AGj) where i = k*n and j = k*(n+1) - 1 to AGn; ··· 2931 2931 } 2932 2932 2933 2933 /* leave free iag in the free iag list */ 2934 - if (iagp->nfreeexts == cpu_to_le32(EXTSPERIAG)) { 2934 + if (iagp->nfreeexts == cpu_to_le32(EXTSPERIAG)) { 2935 2935 release_metapage(bp); 2936 2936 continue; 2937 2937 }
+7 -7
fs/jfs/jfs_imap.h
··· 1 1 /* 2 - * Copyright (c) International Business Machines Corp., 2000-2002 2 + * Copyright (C) International Business Machines Corp., 2000-2002 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18 #ifndef _H_JFS_IMAP ··· 45 45 /* get the starting block number of the 4K page of an inode extent 46 46 * that contains ino. 47 47 */ 48 - #define INOPBLK(pxd,ino,l2nbperpg) (addressPXD((pxd)) + \ 48 + #define INOPBLK(pxd,ino,l2nbperpg) (addressPXD((pxd)) + \ 49 49 ((((ino) & (INOSPEREXT-1)) >> L2INOSPERPAGE) << (l2nbperpg))) 50 50 51 51 /* 52 52 * inode allocation map: 53 - * 54 - * inode allocation map consists of 53 + * 54 + * inode allocation map consists of 55 55 * . the inode map control page and 56 56 * . inode allocation group pages (per 4096 inodes) 57 57 * which are addressed by standard JFS xtree.
+4 -4
fs/jfs/jfs_incore.h
··· 4 4 * 5 5 * This program is free software; you can redistribute it and/or modify 6 6 * it under the terms of the GNU General Public License as published by 7 - * the Free Software Foundation; either version 2 of the License, or 7 + * the Free Software Foundation; either version 2 of the License, or 8 8 * (at your option) any later version. 9 - * 9 + * 10 10 * This program is distributed in the hope that it will be useful, 11 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 13 13 * the GNU General Public License for more details. 14 14 * 15 15 * You should have received a copy of the GNU General Public License 16 - * along with this program; if not, write to the Free Software 16 + * along with this program; if not, write to the Free Software 17 17 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 - */ 18 + */ 19 19 #ifndef _H_JFS_INCORE 20 20 #define _H_JFS_INCORE 21 21
+3 -3
fs/jfs/jfs_inode.c
··· 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18
+3 -3
fs/jfs/jfs_inode.h
··· 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18 #ifndef _H_JFS_INODE
+5 -5
fs/jfs/jfs_lock.h
··· 1 1 /* 2 - * Copyright (c) International Business Machines Corp., 2000-2001 3 - * Portions Copyright (c) Christoph Hellwig, 2001-2002 2 + * Copyright (C) International Business Machines Corp., 2000-2001 3 + * Portions Copyright (C) Christoph Hellwig, 2001-2002 4 4 * 5 5 * This program is free software; you can redistribute it and/or modify 6 6 * it under the terms of the GNU General Public License as published by 7 - * the Free Software Foundation; either version 2 of the License, or 7 + * the Free Software Foundation; either version 2 of the License, or 8 8 * (at your option) any later version. 9 - * 9 + * 10 10 * This program is distributed in the hope that it will be useful, 11 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 13 13 * the GNU General Public License for more details. 14 14 * 15 15 * You should have received a copy of the GNU General Public License 16 - * along with this program; if not, write to the Free Software 16 + * along with this program; if not, write to the Free Software 17 17 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 18 */ 19 19 #ifndef _H_JFS_LOCK
+19 -19
fs/jfs/jfs_logmgr.c
··· 4 4 * 5 5 * This program is free software; you can redistribute it and/or modify 6 6 * it under the terms of the GNU General Public License as published by 7 - * the Free Software Foundation; either version 2 of the License, or 7 + * the Free Software Foundation; either version 2 of the License, or 8 8 * (at your option) any later version. 9 - * 9 + * 10 10 * This program is distributed in the hope that it will be useful, 11 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 13 13 * the GNU General Public License for more details. 14 14 * 15 15 * You should have received a copy of the GNU General Public License 16 - * along with this program; if not, write to the Free Software 16 + * along with this program; if not, write to the Free Software 17 17 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 18 */ 19 19 ··· 337 337 * PARAMETER: cd - commit descriptor 338 338 * 339 339 * RETURN: end-of-log address 340 - * 340 + * 341 341 * serialization: LOG_LOCK() held on entry/exit 342 342 */ 343 343 static int ··· 554 554 * PARAMETER: log 555 555 * 556 556 * RETURN: 0 557 - * 557 + * 558 558 * serialization: LOG_LOCK() held on entry/exit 559 559 */ 560 560 static int lmNextPage(struct jfs_log * log) ··· 656 656 * page number - redrive pageout of the page at the head of 657 657 * pageout queue until full page has been written. 658 658 * 659 - * RETURN: 659 + * RETURN: 660 660 * 661 661 * NOTE: 662 662 * LOGGC_LOCK serializes log group commit queue, and ··· 920 920 * this code is called again. 921 921 * 922 922 * PARAMETERS: log - log structure 923 - * hard_sync - 1 to force all metadata to be written 923 + * hard_sync - 1 to force all metadata to be written 924 924 * 925 925 * RETURN: 0 926 - * 926 + * 927 927 * serialization: LOG_LOCK() held on entry/exit 928 928 */ 929 929 static int lmLogSync(struct jfs_log * log, int hard_sync) ··· 1052 1052 * FUNCTION: write log SYNCPT record for specified log 1053 1053 * 1054 1054 * PARAMETERS: log - log structure 1055 - * hard_sync - set to 1 to force metadata to be written 1055 + * hard_sync - set to 1 to force metadata to be written 1056 1056 */ 1057 1057 void jfs_syncpt(struct jfs_log *log, int hard_sync) 1058 1058 { LOG_LOCK(log); ··· 1067 1067 * insert filesystem in the active list of the log. 1068 1068 * 1069 1069 * PARAMETER: ipmnt - file system mount inode 1070 - * iplog - log inode (out) 1070 + * iplog - log inode (out) 1071 1071 * 1072 1072 * RETURN: 1073 1073 * ··· 1082 1082 1083 1083 if (sbi->flag & JFS_NOINTEGRITY) 1084 1084 return open_dummy_log(sb); 1085 - 1085 + 1086 1086 if (sbi->mntflag & JFS_INLINELOG) 1087 1087 return open_inline_log(sb); 1088 1088 ··· 1131 1131 1132 1132 log->bdev = bdev; 1133 1133 memcpy(log->uuid, sbi->loguuid, sizeof(log->uuid)); 1134 - 1134 + 1135 1135 /* 1136 1136 * initialize log: 1137 1137 */ ··· 1253 1253 * initialize the log from log superblock. 1254 1254 * set the log state in the superblock to LOGMOUNT and 1255 1255 * write SYNCPT log record. 1256 - * 1256 + * 1257 1257 * PARAMETER: log - log structure 1258 1258 * 1259 1259 * RETURN: 0 - if ok 1260 1260 * -EINVAL - bad log magic number or superblock dirty 1261 1261 * error returned from logwait() 1262 - * 1262 + * 1263 1263 * serialization: single first open thread 1264 1264 */ 1265 1265 int lmLogInit(struct jfs_log * log) ··· 1297 1297 1298 1298 if (!test_bit(log_INLINELOG, &log->flag)) 1299 1299 log->l2bsize = L2LOGPSIZE; 1300 - 1300 + 1301 1301 /* check for disabled journaling to disk */ 1302 1302 if (log->no_integrity) { 1303 1303 /* ··· 1651 1651 * PARAMETER: log - log inode 1652 1652 * 1653 1653 * RETURN: 0 - success 1654 - * 1654 + * 1655 1655 * serialization: single last close thread 1656 1656 */ 1657 1657 int lmLogShutdown(struct jfs_log * log) ··· 1677 1677 lrd.type = cpu_to_le16(LOG_SYNCPT); 1678 1678 lrd.length = 0; 1679 1679 lrd.log.syncpt.sync = 0; 1680 - 1680 + 1681 1681 lsn = lmWriteRecord(log, NULL, &lrd, NULL); 1682 1682 bp = log->bp; 1683 1683 lp = (struct logpage *) bp->l_ldata; ··· 1703 1703 jfs_info("lmLogShutdown: lsn:0x%x page:%d eor:%d", 1704 1704 lsn, log->page, log->eor); 1705 1705 1706 - out: 1706 + out: 1707 1707 /* 1708 1708 * shutdown per log i/o 1709 1709 */ ··· 1769 1769 lbmFree(bpsuper); 1770 1770 return -EIO; 1771 1771 } 1772 - 1772 + 1773 1773 } 1774 1774 1775 1775 /*
+37 -39
fs/jfs/jfs_logmgr.h
··· 4 4 * 5 5 * This program is free software; you can redistribute it and/or modify 6 6 * it under the terms of the GNU General Public License as published by 7 - * the Free Software Foundation; either version 2 of the License, or 7 + * the Free Software Foundation; either version 2 of the License, or 8 8 * (at your option) any later version. 9 - * 9 + * 10 10 * This program is distributed in the hope that it will be useful, 11 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 13 13 * the GNU General Public License for more details. 14 14 * 15 15 * You should have received a copy of the GNU General Public License 16 - * along with this program; if not, write to the Free Software 16 + * along with this program; if not, write to the Free Software 17 17 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 18 */ 19 19 #ifndef _H_JFS_LOGMGR ··· 35 35 /* 36 36 * log logical volume 37 37 * 38 - * a log is used to make the commit operation on journalled 38 + * a log is used to make the commit operation on journalled 39 39 * files within the same logical volume group atomic. 40 40 * a log is implemented with a logical volume. 41 - * there is one log per logical volume group. 41 + * there is one log per logical volume group. 42 42 * 43 43 * block 0 of the log logical volume is not used (ipl etc). 44 44 * block 1 contains a log "superblock" and is used by logFormat(), 45 - * lmLogInit(), lmLogShutdown(), and logRedo() to record status 46 - * of the log but is not otherwise used during normal processing. 45 + * lmLogInit(), lmLogShutdown(), and logRedo() to record status 46 + * of the log but is not otherwise used during normal processing. 47 47 * blocks 2 - (N-1) are used to contain log records. 48 48 * 49 - * when a volume group is varied-on-line, logRedo() must have 50 - * been executed before the file systems (logical volumes) in 49 + * when a volume group is varied-on-line, logRedo() must have 50 + * been executed before the file systems (logical volumes) in 51 51 * the volume group can be mounted. 52 52 */ 53 53 /* ··· 97 97 * log logical page 98 98 * 99 99 * (this comment should be rewritten !) 100 - * the header and trailer structures (h,t) will normally have 100 + * the header and trailer structures (h,t) will normally have 101 101 * the same page and eor value. 102 - * An exception to this occurs when a complete page write is not 102 + * An exception to this occurs when a complete page write is not 103 103 * accomplished on a power failure. Since the hardware may "split write" 104 - * sectors in the page, any out of order sequence may occur during powerfail 104 + * sectors in the page, any out of order sequence may occur during powerfail 105 105 * and needs to be recognized during log replay. The xor value is 106 106 * an "exclusive or" of all log words in the page up to eor. This 107 107 * 32 bit eor is stored with the top 16 bits in the header and the 108 108 * bottom 16 bits in the trailer. logredo can easily recognize pages 109 - * that were not completed by reconstructing this eor and checking 109 + * that were not completed by reconstructing this eor and checking 110 110 * the log page. 111 111 * 112 - * Previous versions of the operating system did not allow split 113 - * writes and detected partially written records in logredo by 114 - * ordering the updates to the header, trailer, and the move of data 115 - * into the logdata area. The order: (1) data is moved (2) header 116 - * is updated (3) trailer is updated. In logredo, when the header 117 - * differed from the trailer, the header and trailer were reconciled 118 - * as follows: if h.page != t.page they were set to the smaller of 119 - * the two and h.eor and t.eor set to 8 (i.e. empty page). if (only) 112 + * Previous versions of the operating system did not allow split 113 + * writes and detected partially written records in logredo by 114 + * ordering the updates to the header, trailer, and the move of data 115 + * into the logdata area. The order: (1) data is moved (2) header 116 + * is updated (3) trailer is updated. In logredo, when the header 117 + * differed from the trailer, the header and trailer were reconciled 118 + * as follows: if h.page != t.page they were set to the smaller of 119 + * the two and h.eor and t.eor set to 8 (i.e. empty page). if (only) 120 120 * h.eor != t.eor they were set to the smaller of their two values. 121 121 */ 122 122 struct logpage { ··· 147 147 * in a page, pages are written to temporary paging space if 148 148 * if they must be written to disk before commit, and i/o is 149 149 * scheduled for modified pages to their home location after 150 - * the log records containing the after values and the commit 150 + * the log records containing the after values and the commit 151 151 * record is written to the log on disk, undo discards the copy 152 152 * in main-memory.) 153 153 * 154 - * a log record consists of a data area of variable length followed by 154 + * a log record consists of a data area of variable length followed by 155 155 * a descriptor of fixed size LOGRDSIZE bytes. 156 - * the data area is rounded up to an integral number of 4-bytes and 156 + * the data area is rounded up to an integral number of 4-bytes and 157 157 * must be no longer than LOGPSIZE. 158 - * the descriptor is of size of multiple of 4-bytes and aligned on a 159 - * 4-byte boundary. 158 + * the descriptor is of size of multiple of 4-bytes and aligned on a 159 + * 4-byte boundary. 160 160 * records are packed one after the other in the data area of log pages. 161 - * (sometimes a DUMMY record is inserted so that at least one record ends 161 + * (sometimes a DUMMY record is inserted so that at least one record ends 162 162 * on every page or the longest record is placed on at most two pages). 163 - * the field eor in page header/trailer points to the byte following 163 + * the field eor in page header/trailer points to the byte following 164 164 * the last record on a page. 165 165 */ 166 166 ··· 270 270 /* 271 271 * NOREDOINOEXT: the inode extent is freed 272 272 * 273 - * do not apply after-image records which precede this 274 - * record in the log with the any of the 4 page block 275 - * numbers in this inode extent. 276 - * 277 - * NOTE: The fileset and pxd fields MUST remain in 273 + * do not apply after-image records which precede this 274 + * record in the log with the any of the 4 page block 275 + * numbers in this inode extent. 276 + * 277 + * NOTE: The fileset and pxd fields MUST remain in 278 278 * the same fields in the REDOPAGE record format. 279 279 * 280 280 */ ··· 319 319 * do not apply records which precede this record in the log 320 320 * with the same inode number. 321 321 * 322 - * NOREDILE must be the first to be written at commit 322 + * NOREDOFILE must be the first to be written at commit 323 323 * (last to be read in logredo()) - it prevents 324 324 * replay of preceding updates of all preceding generations 325 - * of the inumber esp. the on-disk inode itself, 326 - * but does NOT prevent 327 - * replay of the 325 + * of the inumber esp. the on-disk inode itself. 328 326 */ 329 327 struct { 330 328 __le32 fileset; /* 4: fileset number */ ··· 330 332 } noredofile; 331 333 332 334 /* 333 - * ? NEWPAGE: 335 + * ? NEWPAGE: 334 336 * 335 337 * metadata type dependent 336 338 */ ··· 462 464 s64 l_blkno; /* 8: log page block number */ 463 465 caddr_t l_ldata; /* 4: data page */ 464 466 struct page *l_page; /* The page itself */ 465 - uint l_offset; /* Offset of l_ldata within the page */ 467 + uint l_offset; /* Offset of l_ldata within the page */ 466 468 467 469 wait_queue_head_t l_ioevent; /* 4: i/o done event */ 468 470 };
+6 -6
fs/jfs/jfs_metapage.c
··· 4 4 * 5 5 * This program is free software; you can redistribute it and/or modify 6 6 * it under the terms of the GNU General Public License as published by 7 - * the Free Software Foundation; either version 2 of the License, or 7 + * the Free Software Foundation; either version 2 of the License, or 8 8 * (at your option) any later version. 9 - * 9 + * 10 10 * This program is distributed in the hope that it will be useful, 11 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 13 13 * the GNU General Public License for more details. 14 14 * 15 15 * You should have received a copy of the GNU General Public License 16 - * along with this program; if not, write to the Free Software 16 + * along with this program; if not, write to the Free Software 17 17 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 18 */ 19 19 ··· 461 461 goto add_failed; 462 462 if (!bio->bi_size) 463 463 goto dump_bio; 464 - 464 + 465 465 submit_bio(WRITE, bio); 466 466 } 467 467 if (redirty) ··· 648 648 jfs_err("logical_size = %d, size = %d", 649 649 mp->logical_size, size); 650 650 dump_stack(); 651 - goto unlock; 651 + goto unlock; 652 652 } 653 653 mp->count++; 654 654 lock_metapage(mp); ··· 658 658 "__get_metapage: using a " 659 659 "discarded metapage"); 660 660 discard_metapage(mp); 661 - goto unlock; 661 + goto unlock; 662 662 } 663 663 clear_bit(META_discard, &mp->flag); 664 664 }
+4 -4
fs/jfs/jfs_metapage.h
··· 4 4 * 5 5 * This program is free software; you can redistribute it and/or modify 6 6 * it under the terms of the GNU General Public License as published by 7 - * the Free Software Foundation; either version 2 of the License, or 7 + * the Free Software Foundation; either version 2 of the License, or 8 8 * (at your option) any later version. 9 - * 9 + * 10 10 * This program is distributed in the hope that it will be useful, 11 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 13 13 * the GNU General Public License for more details. 14 14 * 15 15 * You should have received a copy of the GNU General Public License 16 - * along with this program; if not, write to the Free Software 16 + * along with this program; if not, write to the Free Software 17 17 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 18 */ 19 19 #ifndef _H_JFS_METAPAGE ··· 33 33 unsigned long flag; /* See Below */ 34 34 unsigned long count; /* Reference count */ 35 35 void *data; /* Data pointer */ 36 - sector_t index; /* block address of page */ 36 + sector_t index; /* block address of page */ 37 37 wait_queue_head_t wait; 38 38 39 39 /* implementation */
+17 -17
fs/jfs/jfs_mount.c
··· 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18 ··· 21 21 * 22 22 * note: file system in transition to aggregate/fileset: 23 23 * 24 - * file system mount is interpreted as the mount of aggregate, 25 - * if not already mounted, and mount of the single/only fileset in 24 + * file system mount is interpreted as the mount of aggregate, 25 + * if not already mounted, and mount of the single/only fileset in 26 26 * the aggregate; 27 27 * 28 28 * a file system/aggregate is represented by an internal inode 29 29 * (aka mount inode) initialized with aggregate superblock; 30 - * each vfs represents a fileset, and points to its "fileset inode 30 + * each vfs represents a fileset, and points to its "fileset inode 31 31 * allocation map inode" (aka fileset inode): 32 - * (an aggregate itself is structured recursively as a filset: 33 - * an internal vfs is constructed and points to its "fileset inode 34 - * allocation map inode" (aka aggregate inode) where each inode 35 - * represents a fileset inode) so that inode number is mapped to 32 + * (an aggregate itself is structured recursively as a filset: 33 + * an internal vfs is constructed and points to its "fileset inode 34 + * allocation map inode" (aka aggregate inode) where each inode 35 + * represents a fileset inode) so that inode number is mapped to 36 36 * on-disk inode in uniform way at both aggregate and fileset level; 37 37 * 38 38 * each vnode/inode of a fileset is linked to its vfs (to facilitate ··· 41 41 * per aggregate information, e.g., block size, etc.) as well as 42 42 * its file set inode. 43 43 * 44 - * aggregate 44 + * aggregate 45 45 * ipmnt 46 46 * mntvfs -> fileset ipimap+ -> aggregate ipbmap -> aggregate ipaimap; 47 47 * fileset vfs -> vp(1) <-> ... <-> vp(n) <->vproot; ··· 88 88 struct inode *ipbmap = NULL; 89 89 90 90 /* 91 - * read/validate superblock 91 + * read/validate superblock 92 92 * (initialize mount inode from the superblock) 93 93 */ 94 94 if ((rc = chkSuper(sb))) { ··· 238 238 */ 239 239 int jfs_mount_rw(struct super_block *sb, int remount) 240 240 { 241 - struct jfs_sb_info *sbi = JFS_SBI(sb); 241 + struct jfs_sb_info *sbi = JFS_SBI(sb); 242 242 int rc; 243 243 244 244 /* ··· 291 291 /* 292 292 * chkSuper() 293 293 * 294 - * validate the superblock of the file system to be mounted and 294 + * validate the superblock of the file system to be mounted and 295 295 * get the file system parameters. 296 296 * 297 297 * returns ··· 426 426 jfs_err("updateSuper: bad state"); 427 427 } else if (sbi->state == FM_DIRTY) 428 428 return 0; 429 - 429 + 430 430 if ((rc = readSuper(sb, &bh))) 431 431 return rc; 432 432 ··· 486 486 * for this file system past this point in log. 487 487 * it is harmless if mount fails. 488 488 * 489 - * note: MOUNT record is at aggregate level, not at fileset level, 489 + * note: MOUNT record is at aggregate level, not at fileset level, 490 490 * since log records of previous mounts of a fileset 491 - * (e.g., AFTER record of extent allocation) have to be processed 491 + * (e.g., AFTER record of extent allocation) have to be processed 492 492 * to update block allocation map at aggregate level. 493 493 */ 494 494 static int logMOUNT(struct super_block *sb)
+11 -11
fs/jfs/jfs_superblock.h
··· 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18 #ifndef _H_JFS_SUPERBLOCK ··· 21 21 /* 22 22 * make the magic number something a human could read 23 23 */ 24 - #define JFS_MAGIC "JFS1" /* Magic word */ 24 + #define JFS_MAGIC "JFS1" /* Magic word */ 25 25 26 26 #define JFS_VERSION 2 /* Version number: Version 2 */ 27 27 28 28 #define LV_NAME_SIZE 11 /* MUST BE 11 for OS/2 boot sector */ 29 29 30 - /* 31 - * aggregate superblock 30 + /* 31 + * aggregate superblock 32 32 * 33 33 * The name superblock is too close to super_block, so the name has been 34 34 * changed to jfs_superblock. The utilities are still using the old name. ··· 40 40 __le64 s_size; /* 8: aggregate size in hardware/LVM blocks; 41 41 * VFS: number of blocks 42 42 */ 43 - __le32 s_bsize; /* 4: aggregate block size in bytes; 43 + __le32 s_bsize; /* 4: aggregate block size in bytes; 44 44 * VFS: fragment size 45 45 */ 46 46 __le16 s_l2bsize; /* 2: log2 of s_bsize */ ··· 54 54 __le32 s_flag; /* 4: aggregate attributes: 55 55 * see jfs_filsys.h 56 56 */ 57 - __le32 s_state; /* 4: mount/unmount/recovery state: 57 + __le32 s_state; /* 4: mount/unmount/recovery state: 58 58 * see jfs_filsys.h 59 59 */ 60 60 __le32 s_compress; /* 4: > 0 if data compression */ ··· 75 75 struct timestruc_t s_time; /* 8: time last updated */ 76 76 77 77 __le32 s_fsckloglen; /* 4: Number of filesystem blocks reserved for 78 - * the fsck service log. 78 + * the fsck service log. 79 79 * N.B. These blocks are divided among the 80 80 * versions kept. This is not a per 81 81 * version size. 82 - * N.B. These blocks are included in the 82 + * N.B. These blocks are included in the 83 83 * length field of s_fsckpxd. 84 84 */ 85 85 s8 s_fscklog; /* 1: which fsck service log is most recent ··· 87 87 * 1 => the first one 88 88 * 2 => the 2nd one 89 89 */ 90 - char s_fpack[11]; /* 11: file system volume name 90 + char s_fpack[11]; /* 11: file system volume name 91 91 * N.B. This must be 11 bytes to 92 92 * conform with the OS/2 BootSector 93 93 * requirements
+3 -3
fs/jfs/jfs_txnmgr.c
··· 4 4 * 5 5 * This program is free software; you can redistribute it and/or modify 6 6 * it under the terms of the GNU General Public License as published by 7 - * the Free Software Foundation; either version 2 of the License, or 7 + * the Free Software Foundation; either version 2 of the License, or 8 8 * (at your option) any later version. 9 - * 9 + * 10 10 * This program is distributed in the hope that it will be useful, 11 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 13 13 * the GNU General Public License for more details. 14 14 * 15 15 * You should have received a copy of the GNU General Public License 16 - * along with this program; if not, write to the Free Software 16 + * along with this program; if not, write to the Free Software 17 17 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 18 */ 19 19
+6 -6
fs/jfs/jfs_txnmgr.h
··· 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18 #ifndef _H_JFS_TXNMGR ··· 179 179 /* (8) */ 180 180 181 181 struct lv lv[20]; /* 40: */ 182 - }; /* (48) */ 182 + }; /* (48) */ 183 183 184 184 #define dt_lock linelock 185 185 ··· 211 211 * at tlock.lock/linelock: watch for alignment; 212 212 * N.B. next field may be set by linelock, and should not 213 213 * be modified by maplock; 214 - * N.B. index of the first pxdlock specifies index of next 215 - * free maplock (i.e., number of maplock) in the tlock; 214 + * N.B. index of the first pxdlock specifies index of next 215 + * free maplock (i.e., number of maplock) in the tlock; 216 216 */ 217 217 struct maplock { 218 218 lid_t next; /* 2: */
+12 -12
fs/jfs/jfs_umount.c
··· 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18 ··· 22 22 * note: file system in transition to aggregate/fileset: 23 23 * (ref. jfs_mount.c) 24 24 * 25 - * file system unmount is interpreted as mount of the single/only 26 - * fileset in the aggregate and, if unmount of the last fileset, 25 + * file system unmount is interpreted as mount of the single/only 26 + * fileset in the aggregate and, if unmount of the last fileset, 27 27 * as unmount of the aggerate; 28 28 */ 29 29 ··· 60 60 jfs_info("UnMount JFS: sb:0x%p", sb); 61 61 62 62 /* 63 - * update superblock and close log 63 + * update superblock and close log 64 64 * 65 65 * if mounted read-write and log based recovery was enabled 66 66 */ 67 67 if ((log = sbi->log)) 68 68 /* 69 - * Wait for outstanding transactions to be written to log: 69 + * Wait for outstanding transactions to be written to log: 70 70 */ 71 71 jfs_flush_journal(log, 2); 72 72 ··· 112 112 113 113 /* 114 114 * ensure all file system file pages are propagated to their 115 - * home blocks on disk (and their in-memory buffer pages are 115 + * home blocks on disk (and their in-memory buffer pages are 116 116 * invalidated) BEFORE updating file system superblock state 117 - * (to signify file system is unmounted cleanly, and thus in 118 - * consistent state) and log superblock active file system 117 + * (to signify file system is unmounted cleanly, and thus in 118 + * consistent state) and log superblock active file system 119 119 * list (to signify skip logredo()). 120 120 */ 121 121 if (log) { /* log = NULL if read-only mount */ 122 122 updateSuper(sb, FM_CLEAN); 123 123 124 124 /* 125 - * close log: 125 + * close log: 126 126 * 127 127 * remove file system from log active file system list. 128 128 */ ··· 142 142 return 0; 143 143 144 144 /* 145 - * close log: 145 + * close log: 146 146 * 147 147 * remove file system from log active file system list. 148 148 */
+5 -5
fs/jfs/jfs_unicode.c
··· 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18 ··· 57 57 warn--; 58 58 warn_again--; 59 59 printk(KERN_ERR 60 - "non-latin1 character 0x%x found in JFS file name\n", 61 - le16_to_cpu(from[i])); 60 + "non-latin1 character 0x%x found in JFS file name\n", 61 + le16_to_cpu(from[i])); 62 62 printk(KERN_ERR 63 63 "mount with iocharset=utf8 to access\n"); 64 64 }
+5 -5
fs/jfs/jfs_unicode.h
··· 1 1 /* 2 - * Copyright (c) International Business Machines Corp., 2000-2002 3 - * Portions Copyright (c) Christoph Hellwig, 2001-2002 2 + * Copyright (C) International Business Machines Corp., 2000-2002 3 + * Portions Copyright (C) Christoph Hellwig, 2001-2002 4 4 * 5 5 * This program is free software; you can redistribute it and/or modify 6 6 * it under the terms of the GNU General Public License as published by 7 - * the Free Software Foundation; either version 2 of the License, or 7 + * the Free Software Foundation; either version 2 of the License, or 8 8 * (at your option) any later version. 9 - * 9 + * 10 10 * This program is distributed in the hope that it will be useful, 11 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 13 13 * the GNU General Public License for more details. 14 14 * 15 15 * You should have received a copy of the GNU General Public License 16 - * along with this program; if not, write to the Free Software 16 + * along with this program; if not, write to the Free Software 17 17 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 18 */ 19 19 #ifndef _H_JFS_UNICODE
+4 -4
fs/jfs/jfs_uniupr.c
··· 1 1 /* 2 - * Copyright (c) International Business Machines Corp., 2000-2002 2 + * Copyright (C) International Business Machines Corp., 2000-2002 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18
+1 -1
fs/jfs/jfs_xattr.h
··· 1 1 /* 2 - * Copyright (c) International Business Machines Corp., 2000-2002 2 + * Copyright (C) International Business Machines Corp., 2000-2002 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by
+6 -6
fs/jfs/jfs_xtree.c
··· 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18 /* ··· 2428 2428 * return: 2429 2429 */ 2430 2430 int xtAppend(tid_t tid, /* transaction id */ 2431 - struct inode *ip, int xflag, s64 xoff, s32 maxblocks, 2431 + struct inode *ip, int xflag, s64 xoff, s32 maxblocks, 2432 2432 s32 * xlenp, /* (in/out) */ 2433 2433 s64 * xaddrp, /* (in/out) */ 2434 2434 int flag) ··· 2499 2499 pxdlist.maxnpxd = pxdlist.npxd = 0; 2500 2500 pxd = &pxdlist.pxd[0]; 2501 2501 nblocks = JFS_SBI(ip->i_sb)->nbperpage; 2502 - for (; nsplit > 0; nsplit--, pxd++, xaddr += nblocks, maxblocks -= nblocks) { 2502 + for (; nsplit > 0; nsplit--, pxd++, xaddr += nblocks, maxblocks -= nblocks) { 2503 2503 if ((rc = dbAllocBottomUp(ip, xaddr, (s64) nblocks)) == 0) { 2504 2504 PXDaddress(pxd, xaddr); 2505 2505 PXDlength(pxd, nblocks); ··· 2514 2514 goto out; 2515 2515 } 2516 2516 2517 - xlen = min(xlen, maxblocks); 2517 + xlen = min(xlen, maxblocks); 2518 2518 2519 2519 /* 2520 2520 * allocate data extent requested
+4 -4
fs/jfs/jfs_xtree.h
··· 1 1 /* 2 - * Copyright (c) International Business Machines Corp., 2000-2002 2 + * Copyright (C) International Business Machines Corp., 2000-2002 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18 #ifndef _H_JFS_XTREE
+25 -25
fs/jfs/namei.c
··· 4 4 * 5 5 * This program is free software; you can redistribute it and/or modify 6 6 * it under the terms of the GNU General Public License as published by 7 - * the Free Software Foundation; either version 2 of the License, or 7 + * the Free Software Foundation; either version 2 of the License, or 8 8 * (at your option) any later version. 9 - * 9 + * 10 10 * This program is distributed in the hope that it will be useful, 11 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 13 13 * the GNU General Public License for more details. 14 14 * 15 15 * You should have received a copy of the GNU General Public License 16 - * along with this program; if not, write to the Free Software 16 + * along with this program; if not, write to the Free Software 17 17 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 18 */ 19 19 ··· 41 41 /* 42 42 * NAME: free_ea_wmap(inode) 43 43 * 44 - * FUNCTION: free uncommitted extended attributes from working map 44 + * FUNCTION: free uncommitted extended attributes from working map 45 45 * 46 46 */ 47 47 static inline void free_ea_wmap(struct inode *inode) ··· 62 62 * FUNCTION: create a regular file in the parent directory <dip> 63 63 * with name = <from dentry> and mode = <mode> 64 64 * 65 - * PARAMETER: dip - parent directory vnode 65 + * PARAMETER: dip - parent directory vnode 66 66 * dentry - dentry of new file 67 67 * mode - create mode (rwxrwxrwx). 68 68 * nd- nd struct ··· 190 190 * FUNCTION: create a child directory in the parent directory <dip> 191 191 * with name = <from dentry> and mode = <mode> 192 192 * 193 - * PARAMETER: dip - parent directory vnode 193 + * PARAMETER: dip - parent directory vnode 194 194 * dentry - dentry of child directory 195 195 * mode - create mode (rwxrwxrwx). 196 196 * ··· 324 324 * 325 325 * FUNCTION: remove a link to child directory 326 326 * 327 - * PARAMETER: dip - parent inode 327 + * PARAMETER: dip - parent inode 328 328 * dentry - child directory dentry 329 329 * 330 330 * RETURN: -EINVAL - if name is . or .. ··· 332 332 * errors from subroutines 333 333 * 334 334 * note: 335 - * if other threads have the directory open when the last link 336 - * is removed, the "." and ".." entries, if present, are removed before 337 - * rmdir() returns and no new entries may be created in the directory, 338 - * but the directory is not removed until the last reference to 335 + * if other threads have the directory open when the last link 336 + * is removed, the "." and ".." entries, if present, are removed before 337 + * rmdir() returns and no new entries may be created in the directory, 338 + * but the directory is not removed until the last reference to 339 339 * the directory is released (cf.unlink() of regular file). 340 340 */ 341 341 static int jfs_rmdir(struct inode *dip, struct dentry *dentry) ··· 446 446 /* 447 447 * NAME: jfs_unlink(dip, dentry) 448 448 * 449 - * FUNCTION: remove a link to object <vp> named by <name> 449 + * FUNCTION: remove a link to object <vp> named by <name> 450 450 * from parent directory <dvp> 451 451 * 452 - * PARAMETER: dip - inode of parent directory 453 - * dentry - dentry of object to be removed 452 + * PARAMETER: dip - inode of parent directory 453 + * dentry - dentry of object to be removed 454 454 * 455 455 * RETURN: errors from subroutines 456 456 * ··· 598 598 * 599 599 * FUNCTION: for non-directory, called by jfs_remove(), 600 600 * truncate a regular file, directory or symbolic 601 - * link to zero length. return 0 if type is not 601 + * link to zero length. return 0 if type is not 602 602 * one of these. 603 603 * 604 604 * if the file is currently associated with a VM segment ··· 608 608 * map by ctrunc1. 609 609 * if there is no VM segment on entry, the resources are 610 610 * freed in both work and permanent map. 611 - * (? for temporary file - memory object is cached even 611 + * (? for temporary file - memory object is cached even 612 612 * after no reference: 613 613 * reference count > 0 - ) 614 614 * ··· 662 662 663 663 /* 664 664 * free xtree/data (truncate to zero length): 665 - * free xtree/data pages from cache if COMMIT_PWMAP, 665 + * free xtree/data pages from cache if COMMIT_PWMAP, 666 666 * free xtree/data blocks from persistent block map, and 667 667 * free xtree/data blocks from working block map if COMMIT_PWMAP; 668 668 */ ··· 677 677 * NAME: jfs_free_zero_link() 678 678 * 679 679 * FUNCTION: for non-directory, called by iClose(), 680 - * free resources of a file from cache and WORKING map 680 + * free resources of a file from cache and WORKING map 681 681 * for a file previously committed with zero link count 682 682 * while associated with a pager object, 683 683 * ··· 762 762 * FUNCTION: create a link to <vp> by the name = <name> 763 763 * in the parent directory <dvp> 764 764 * 765 - * PARAMETER: vp - target object 765 + * PARAMETER: vp - target object 766 766 * dvp - parent directory of new link 767 767 * name - name of new link to target object 768 768 * crp - credential ··· 858 858 * in directory <dip> 859 859 * 860 860 * PARAMETER: dip - parent directory vnode 861 - * dentry - dentry of symbolic link 862 - * name - the path name of the existing object 861 + * dentry - dentry of symbolic link 862 + * name - the path name of the existing object 863 863 * that will be the source of the link 864 864 * 865 865 * RETURN: errors from subroutines ··· 926 926 tblk->u.ixpxd = JFS_IP(ip)->ixpxd; 927 927 928 928 /* fix symlink access permission 929 - * (dir_create() ANDs in the u.u_cmask, 929 + * (dir_create() ANDs in the u.u_cmask, 930 930 * but symlinks really need to be 777 access) 931 931 */ 932 932 ip->i_mode |= 0777; ··· 967 967 ip->i_mapping->a_ops = &jfs_aops; 968 968 969 969 /* 970 - * even though the data of symlink object (source 970 + * even though the data of symlink object (source 971 971 * path name) is treated as non-journaled user data, 972 972 * it is read/written thru buffer cache for performance. 973 973 */ ··· 1175 1175 /* free block resources */ 1176 1176 if ((new_size = commitZeroLink(tid, new_ip)) < 0) { 1177 1177 txAbort(tid, 1); /* Marks FS Dirty */ 1178 - rc = new_size; 1178 + rc = new_size; 1179 1179 goto out4; 1180 1180 } 1181 1181 tblk = tid_to_tblock(tid); ··· 1291 1291 new_size = xtTruncate_pmap(tid, new_ip, new_size); 1292 1292 if (new_size < 0) { 1293 1293 txAbort(tid, 1); 1294 - rc = new_size; 1294 + rc = new_size; 1295 1295 } else 1296 1296 rc = txCommit(tid, 1, &new_ip, COMMIT_SYNC); 1297 1297 txEnd(tid);
+3 -3
fs/jfs/resize.c
··· 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18
+5 -5
fs/jfs/super.c
··· 4 4 * 5 5 * This program is free software; you can redistribute it and/or modify 6 6 * it under the terms of the GNU General Public License as published by 7 - * the Free Software Foundation; either version 2 of the License, or 7 + * the Free Software Foundation; either version 2 of the License, or 8 8 * (at your option) any later version. 9 - * 9 + * 10 10 * This program is distributed in the hope that it will be useful, 11 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 13 13 * the GNU General Public License for more details. 14 14 * 15 15 * You should have received a copy of the GNU General Public License 16 - * along with this program; if not, write to the Free Software 16 + * along with this program; if not, write to the Free Software 17 17 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 18 */ 19 19 ··· 82 82 "as read-only\n", 83 83 sb->s_id); 84 84 sb->s_flags |= MS_RDONLY; 85 - } 85 + } 86 86 87 87 /* nothing is done for continue beyond marking the superblock dirty */ 88 88 } ··· 775 775 int rc; 776 776 777 777 jfs_inode_cachep = 778 - kmem_cache_create("jfs_ip", sizeof(struct jfs_inode_info), 0, 778 + kmem_cache_create("jfs_ip", sizeof(struct jfs_inode_info), 0, 779 779 SLAB_RECLAIM_ACCOUNT|SLAB_MEM_SPREAD, 780 780 init_once, NULL); 781 781 if (jfs_inode_cachep == NULL)
+3 -3
fs/jfs/symlink.c
··· 3 3 * 4 4 * This program is free software; you can redistribute it and/or modify 5 5 * it under the terms of the GNU General Public License as published by 6 - * the Free Software Foundation; either version 2 of the License, or 6 + * the Free Software Foundation; either version 2 of the License, or 7 7 * (at your option) any later version. 8 - * 8 + * 9 9 * This program is distributed in the hope that it will be useful, 10 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 12 12 * the GNU General Public License for more details. 13 13 * 14 14 * You should have received a copy of the GNU General Public License 15 - * along with this program; if not, write to the Free Software 15 + * along with this program; if not, write to the Free Software 16 16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 17 */ 18 18
+19 -19
fs/jfs/xattr.c
··· 4 4 * 5 5 * This program is free software; you can redistribute it and/or modify 6 6 * it under the terms of the GNU General Public License as published by 7 - * the Free Software Foundation; either version 2 of the License, or 7 + * the Free Software Foundation; either version 2 of the License, or 8 8 * (at your option) any later version. 9 - * 9 + * 10 10 * This program is distributed in the hope that it will be useful, 11 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See 13 13 * the GNU General Public License for more details. 14 14 * 15 15 * You should have received a copy of the GNU General Public License 16 - * along with this program; if not, write to the Free Software 16 + * along with this program; if not, write to the Free Software 17 17 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 18 18 */ 19 19 ··· 57 57 * 58 58 * 0 4 4 + EA_SIZE(ea1) 59 59 * +------------+-------------------+--------------------+----- 60 - * | Overall EA | First FEA Element | Second FEA Element | ..... 60 + * | Overall EA | First FEA Element | Second FEA Element | ..... 61 61 * | List Size | | | 62 62 * +------------+-------------------+--------------------+----- 63 63 * ··· 155 155 156 156 /* 157 157 * NAME: ea_write_inline 158 - * 158 + * 159 159 * FUNCTION: Attempt to write an EA inline if area is available 160 - * 160 + * 161 161 * PRE CONDITIONS: 162 162 * Already verified that the specified EA is small enough to fit inline 163 163 * ··· 216 216 217 217 /* 218 218 * NAME: ea_write 219 - * 219 + * 220 220 * FUNCTION: Write an EA for an inode 221 - * 222 - * PRE CONDITIONS: EA has been verified 221 + * 222 + * PRE CONDITIONS: EA has been verified 223 223 * 224 224 * PARAMETERS: 225 225 * ip - Inode pointer ··· 340 340 341 341 /* 342 342 * NAME: ea_read_inline 343 - * 343 + * 344 344 * FUNCTION: Read an inlined EA into user's buffer 345 - * 345 + * 346 346 * PARAMETERS: 347 347 * ip - Inode pointer 348 348 * ealist - Pointer to buffer to fill in with EA ··· 372 372 373 373 /* 374 374 * NAME: ea_read 375 - * 375 + * 376 376 * FUNCTION: copy EA data into user's buffer 377 - * 377 + * 378 378 * PARAMETERS: 379 379 * ip - Inode pointer 380 380 * ealist - Pointer to buffer to fill in with EA ··· 406 406 return -EIO; 407 407 } 408 408 409 - /* 409 + /* 410 410 * Figure out how many blocks were allocated when this EA list was 411 411 * originally written to disk. 412 412 */ ··· 443 443 444 444 /* 445 445 * NAME: ea_get 446 - * 446 + * 447 447 * FUNCTION: Returns buffer containing existing extended attributes. 448 448 * The size of the buffer will be the larger of the existing 449 449 * attributes size, or min_size. 450 450 * 451 451 * The buffer, which may be inlined in the inode or in the 452 - * page cache must be release by calling ea_release or ea_put 453 - * 452 + * page cache must be release by calling ea_release or ea_put 453 + * 454 454 * PARAMETERS: 455 455 * inode - Inode pointer 456 456 * ea_buf - Structure to be populated with ealist and its metadata ··· 1054 1054 1055 1055 /* compute required size of list */ 1056 1056 for (ea = FIRST_EA(ealist); ea < END_EALIST(ealist); ea = NEXT_EA(ea)) { 1057 - if (can_list(ea)) 1057 + if (can_list(ea)) 1058 1058 size += name_size(ea) + 1; 1059 1059 } 1060 1060 ··· 1069 1069 /* Copy attribute names to buffer */ 1070 1070 buffer = data; 1071 1071 for (ea = FIRST_EA(ealist); ea < END_EALIST(ealist); ea = NEXT_EA(ea)) { 1072 - if (can_list(ea)) { 1072 + if (can_list(ea)) { 1073 1073 int namelen = copy_name(buffer, ea); 1074 1074 buffer += namelen + 1; 1075 1075 }