android_kernel_xiaomi_sdm845/fs/xfs
Nathan Scott 0e1edbd999 [XFS] Fix xfs_free_extent related NULL pointer dereference.
We recently fixed an out-of-space deadlock in XFS, and part of that fix
involved the addition of the XFS_ALLOC_FLAG_FREEING flag to some of the
space allocator calls to indicate they're freeing space, not allocating
it. There was a missed xfs_alloc_fix_freelist condition test that did not
correctly test "flags". The same test would also test an uninitialised
structure field (args->userdata) and depending on its value either would
or would not return early with a critical buffer pointer set to NULL.

This fixes that up, adds asserts to several places to catch future botches
of this nature, and skips sections of xfs_alloc_fix_freelist that are
irrelevent for the space-freeing case.

SGI-PV: 955303
SGI-Modid: xfs-linux-melb:xfs-kern:26743a

Signed-off-by: Nathan Scott <nathans@sgi.com>
2006-08-10 14:40:41 +10:00
..
linux-2.6 [XFS] Fix a barrier related forced shutdown on mounts with quota enabled. 2006-07-28 17:05:13 +10:00
quota [XFS] All xfs_disk_dquot_t values are (as the name says) disk endian. 2006-07-28 17:04:26 +10:00
support
Kbuild
Kconfig
Makefile
Makefile-linux-2.6 [XFS] Remove files from the build that are now unused. 2006-06-20 14:53:51 +10:00
xfs_acl.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_acl.h
xfs_ag.h
xfs_alloc_btree.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_alloc_btree.h
xfs_alloc.c [XFS] Fix xfs_free_extent related NULL pointer dereference. 2006-08-10 14:40:41 +10:00
xfs_alloc.h
xfs_arch.h
xfs_attr_leaf.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_attr_leaf.h
xfs_attr_sf.h
xfs_attr.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_attr.h
xfs_behavior.c
xfs_behavior.h [XFS] remove unused behaviour lock - shrink XFS vnode as a side effect. 2006-06-27 16:12:15 +10:00
xfs_bit.c
xfs_bit.h
xfs_bmap_btree.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_bmap_btree.h
xfs_bmap.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_bmap.h
xfs_btree.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_btree.h
xfs_buf_item.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_buf_item.h
xfs_cap.h
xfs_clnt.h
xfs_da_btree.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_da_btree.h [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_dfrag.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_dfrag.h
xfs_dinode.h [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_dir2_block.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_dir2_block.h
xfs_dir2_data.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_dir2_data.h
xfs_dir2_leaf.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_dir2_leaf.h
xfs_dir2_node.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_dir2_node.h
xfs_dir2_sf.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_dir2_sf.h
xfs_dir2_trace.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_dir2_trace.h
xfs_dir2.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_dir2.h [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_dmapi.h
xfs_dmops.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_error.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_error.h
xfs_extfree_item.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_extfree_item.h
xfs_fs.h
xfs_fsops.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_fsops.h
xfs_ialloc_btree.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_ialloc_btree.h
xfs_ialloc.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_ialloc.h
xfs_iget.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_imap.h
xfs_inode_item.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_inode_item.h
xfs_inode.c [XFS] Ensure bulkstat from an invalid inode number gets caught always with 2006-07-28 17:05:51 +10:00
xfs_inode.h
xfs_inum.h
xfs_iocore.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_iomap.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_iomap.h
xfs_itable.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_itable.h
xfs_log_priv.h
xfs_log_recover.c [XFS] Rework code snippets slightly to remove remaining recent-gcc 2006-06-28 10:13:52 +10:00
xfs_log_recover.h
xfs_log.c [XFS] Fix remount vs no/barrier options by ensuring we clear unwanted 2006-07-28 17:04:44 +10:00
xfs_log.h
xfs_mac.h
xfs_mount.c Merge git://oss.sgi.com:8090/nathans/xfs-2.6 2006-06-27 19:09:16 -07:00
xfs_mount.h [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_qmops.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_quota.h
xfs_refcache.h
xfs_rename.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_rtalloc.c [XFS] Fix realtime subvolume expansion, a porting bug b0rked it. Coverity 2006-06-28 08:42:26 +10:00
xfs_rtalloc.h
xfs_rw.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_rw.h
xfs_sb.h
xfs_trans_ail.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_trans_buf.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_trans_extfree.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_trans_inode.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_trans_item.c
xfs_trans_priv.h
xfs_trans_space.h [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_trans.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_trans.h [XFS] Reduce size of xfs_trans_t structure. * remove ->t_forw, ->t_back -- 2006-06-27 16:12:40 +10:00
xfs_types.h
xfs_utils.c [XFS] Remove version 1 directory code. Never functioned on Linux, just 2006-06-20 13:04:51 +10:00
xfs_utils.h
xfs_vfsops.c [XFS] Fix a barrier related forced shutdown on mounts with quota enabled. 2006-07-28 17:05:13 +10:00
xfs_vnodeops.c [XFS] link(2) on directory is banned in VFS. 2006-06-27 12:45:17 +10:00
xfs.h