forked from luck/tmp_suning_uos_patched
Changes since last update:
- Fix some clang/smatch/sparse warnings about uninitialized variables. - Clean up some typedef usage. -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEUzaAxoMeQq6m2jMV+H93GTRKtOsFAlyH+rEACgkQ+H93GTRK tOsoYA/+MBjGB3rbDAZfY7/tlTnQS4Yc7XsBz9C0SvLul0/CbcTPM1w8CO0clH3d OxemwdqpoxZkcet3Sv1m2/sr6PVM+7r6f2vn0j19iPOI5soF0hX4XLnvkNhFZbm0 cl25rO9GuXcG7U7iLXdjyGrXNc+8Hy5kmZJzx3MA7DPTjkEQGgWrB4XIgvNnv0k9 cIfJtuC9FKFO1/+6oTWid1v+HCPea7m8ORosWgh0q6S9noPAE63vDbesrxHpI3i4 TLu5L3r6IXHzLRuCcDcB7aPu98L9eLhrBSBqEuiFlkf03ASJqAO4jMarV73WSdvO YR1CcWaOGO1W6VRp67N9iLw5WZxplG9n0NaecM1w70g84wSimNmmtBnzHNnfIa8P ZopsLJgflQV18qcmjWTnzeNF5RvAu7tQRLLmzJkLiZjQzmk9mr+t41MeIybho9eZ zDs8ePN56pUJ6xqaLFTx4MdUkJ8LlllOqsKa7tILu1w76ClGEtSGo48Y/eog+aAu MIOAjFY9esUNdVlMu8fsa83DWg31AlwTPYQ5nlrRQ1Xk1GGPAr8lzfQTOG+NI1qo eWM8NRqaFDYI/1Ruy3keOsAfuNQkOiNrLz8ge3xH9Y10+meMejoaOLgWMdnyDlYZ WxmhlYkmVycpZXmm9lR9Dt7qKLg+6texQccbkNUjPwrA8bTs5Ek= =YIiT -----END PGP SIGNATURE----- Merge tag 'xfs-5.1-merge-5' of git://git.kernel.org/pub/scm/fs/xfs/xfs-linux Pull xfs cleanups from Darrick Wong: "Here's a few more cleanups that trickled in for the merge window. It's all fixes for static checker complaints and slowly unwinding typedef usage. The four patches here have gone through a few days worth of fstest runs with no new problems observed. Summary: - Fix some clang/smatch/sparse warnings about uninitialized variables. - Clean up some typedef usage" * tag 'xfs-5.1-merge-5' of git://git.kernel.org/pub/scm/fs/xfs/xfs-linux: xfs: clean up xfs_dir2_leaf_addname xfs: zero initialize highstale and lowstale in xfs_dir2_leaf_addname xfs: clean up xfs_dir2_leafn_add xfs: Zero initialize highstale and lowstale in xfs_dir2_leafn_add
This commit is contained in:
commit
de578188ed
|
@ -563,43 +563,40 @@ xfs_dir3_leaf_find_entry(
|
|||
*/
|
||||
int /* error */
|
||||
xfs_dir2_leaf_addname(
|
||||
xfs_da_args_t *args) /* operation arguments */
|
||||
struct xfs_da_args *args) /* operation arguments */
|
||||
{
|
||||
struct xfs_dir3_icleaf_hdr leafhdr;
|
||||
struct xfs_trans *tp = args->trans;
|
||||
__be16 *bestsp; /* freespace table in leaf */
|
||||
int compact; /* need to compact leaves */
|
||||
xfs_dir2_data_hdr_t *hdr; /* data block header */
|
||||
__be16 *tagp; /* end of data entry */
|
||||
struct xfs_buf *dbp; /* data block buffer */
|
||||
xfs_dir2_data_entry_t *dep; /* data block entry */
|
||||
xfs_inode_t *dp; /* incore directory inode */
|
||||
xfs_dir2_data_unused_t *dup; /* data unused entry */
|
||||
struct xfs_buf *lbp; /* leaf's buffer */
|
||||
struct xfs_dir2_leaf *leaf; /* leaf structure */
|
||||
struct xfs_inode *dp = args->dp; /* incore directory inode */
|
||||
struct xfs_dir2_data_hdr *hdr; /* data block header */
|
||||
struct xfs_dir2_data_entry *dep; /* data block entry */
|
||||
struct xfs_dir2_leaf_entry *lep; /* leaf entry table pointer */
|
||||
struct xfs_dir2_leaf_entry *ents;
|
||||
struct xfs_dir2_data_unused *dup; /* data unused entry */
|
||||
struct xfs_dir2_leaf_tail *ltp; /* leaf tail pointer */
|
||||
struct xfs_dir2_data_free *bf; /* bestfree table */
|
||||
int compact; /* need to compact leaves */
|
||||
int error; /* error return value */
|
||||
int grown; /* allocated new data block */
|
||||
int highstale; /* index of next stale leaf */
|
||||
int highstale = 0; /* index of next stale leaf */
|
||||
int i; /* temporary, index */
|
||||
int index; /* leaf table position */
|
||||
struct xfs_buf *lbp; /* leaf's buffer */
|
||||
xfs_dir2_leaf_t *leaf; /* leaf structure */
|
||||
int length; /* length of new entry */
|
||||
xfs_dir2_leaf_entry_t *lep; /* leaf entry table pointer */
|
||||
int lfloglow; /* low leaf logging index */
|
||||
int lfloghigh; /* high leaf logging index */
|
||||
int lowstale; /* index of prev stale leaf */
|
||||
xfs_dir2_leaf_tail_t *ltp; /* leaf tail pointer */
|
||||
int lowstale = 0; /* index of prev stale leaf */
|
||||
int needbytes; /* leaf block bytes needed */
|
||||
int needlog; /* need to log data header */
|
||||
int needscan; /* need to rescan data free */
|
||||
__be16 *tagp; /* end of data entry */
|
||||
xfs_trans_t *tp; /* transaction pointer */
|
||||
xfs_dir2_db_t use_block; /* data block number */
|
||||
struct xfs_dir2_data_free *bf; /* bestfree table */
|
||||
struct xfs_dir2_leaf_entry *ents;
|
||||
struct xfs_dir3_icleaf_hdr leafhdr;
|
||||
|
||||
trace_xfs_dir2_leaf_addname(args);
|
||||
|
||||
dp = args->dp;
|
||||
tp = args->trans;
|
||||
|
||||
error = xfs_dir3_leaf_read(tp, dp, args->geo->leafblk, -1, &lbp);
|
||||
if (error)
|
||||
return error;
|
||||
|
|
|
@ -426,24 +426,22 @@ xfs_dir2_leaf_to_node(
|
|||
static int /* error */
|
||||
xfs_dir2_leafn_add(
|
||||
struct xfs_buf *bp, /* leaf buffer */
|
||||
xfs_da_args_t *args, /* operation arguments */
|
||||
struct xfs_da_args *args, /* operation arguments */
|
||||
int index) /* insertion pt for new entry */
|
||||
{
|
||||
struct xfs_dir3_icleaf_hdr leafhdr;
|
||||
struct xfs_inode *dp = args->dp;
|
||||
struct xfs_dir2_leaf *leaf = bp->b_addr;
|
||||
struct xfs_dir2_leaf_entry *lep;
|
||||
struct xfs_dir2_leaf_entry *ents;
|
||||
int compact; /* compacting stale leaves */
|
||||
xfs_inode_t *dp; /* incore directory inode */
|
||||
int highstale; /* next stale entry */
|
||||
xfs_dir2_leaf_t *leaf; /* leaf structure */
|
||||
xfs_dir2_leaf_entry_t *lep; /* leaf entry */
|
||||
int highstale = 0; /* next stale entry */
|
||||
int lfloghigh; /* high leaf entry logging */
|
||||
int lfloglow; /* low leaf entry logging */
|
||||
int lowstale; /* previous stale entry */
|
||||
struct xfs_dir3_icleaf_hdr leafhdr;
|
||||
struct xfs_dir2_leaf_entry *ents;
|
||||
int lowstale = 0; /* previous stale entry */
|
||||
|
||||
trace_xfs_dir2_leafn_add(args, index);
|
||||
|
||||
dp = args->dp;
|
||||
leaf = bp->b_addr;
|
||||
dp->d_ops->leaf_hdr_from_disk(&leafhdr, leaf);
|
||||
ents = dp->d_ops->leaf_ents_p(leaf);
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user