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

Merge tag 'jfs-6.6' of github.com:kleikamp/linux-shaggy

Pull jfs updates from Dave Kleikamp:
"A few small fixes"

* tag 'jfs-6.6' of github.com:kleikamp/linux-shaggy:
jfs: validate max amount of blocks before allocation.
jfs: remove redundant initialization to pointer ip
jfs: fix invalid free of JFS_IP(ipimap)->i_imap in diUnmount
FS: JFS: (trivial) Fix grammatical error in extAlloc
fs/jfs: prevent double-free in dbUnmount() after failed jfs_remount()

+9 -2
+1
fs/jfs/jfs_dmap.c
··· 269 269 270 270 /* free the memory for the in-memory bmap. */ 271 271 kfree(bmp); 272 + JFS_SBI(ipbmap->i_sb)->bmap = NULL; 272 273 273 274 return (0); 274 275 }
+6 -1
fs/jfs/jfs_extent.c
··· 166 166 /* 167 167 * COMMIT_SyncList flags an anonymous tlock on page that is on 168 168 * sync list. 169 - * We need to commit the inode to get the page written disk. 169 + * We need to commit the inode to get the page written to the disk. 170 170 */ 171 171 if (test_and_clear_cflag(COMMIT_Synclist,ip)) 172 172 jfs_commit_inode(ip, 0); ··· 311 311 * blocks in the map. in that case, we'll start off with the 312 312 * maximum free. 313 313 */ 314 + 315 + /* give up if no space left */ 316 + if (bmp->db_maxfreebud == -1) 317 + return -ENOSPC; 318 + 314 319 max = (s64) 1 << bmp->db_maxfreebud; 315 320 if (*nblocks >= max && *nblocks > nbperpage) 316 321 nb = nblks = (max > nbperpage) ? max : nbperpage;
+1
fs/jfs/jfs_imap.c
··· 193 193 * free in-memory control structure 194 194 */ 195 195 kfree(imap); 196 + JFS_IP(ipimap)->i_imap = NULL; 196 197 197 198 return (0); 198 199 }
+1 -1
fs/jfs/namei.c
··· 883 883 struct component_name dname; 884 884 u32 ssize; /* source pathname size */ 885 885 struct btstack btstack; 886 - struct inode *ip = d_inode(dentry); 886 + struct inode *ip; 887 887 s64 xlen = 0; 888 888 int bmask = 0, xsize; 889 889 s64 xaddr;