Commit 9fe19046 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull isofs, udf, and quota updates from Jan Kara:
 "Several udf, isofs, and quota fixes"

* tag 'fs_for_v5.12-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/jack/linux-fs:
  parser: Fix kernel-doc markups
  udf: handle large user and group ID
  isofs: handle large user and group ID
  parser: add unsigned int parser
  udf: fix silent AED tagLocation corruption
  isofs: release buffer head before return
  quota: Fix memory leak when handling corrupted quota file
parents db990385 b9bffa10
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -152,6 +152,7 @@ static int do_isofs_readdir(struct inode *inode, struct file *file,
			printk(KERN_NOTICE "iso9660: Corrupted directory entry"
			       " in block %lu of inode %lu\n", block,
			       inode->i_ino);
			brelse(bh);
			return -EIO;
		}

+5 −4
Original line number Diff line number Diff line
@@ -339,6 +339,7 @@ static int parse_options(char *options, struct iso9660_options *popt)
{
	char *p;
	int option;
	unsigned int uv;

	popt->map = 'n';
	popt->rock = 1;
@@ -434,17 +435,17 @@ static int parse_options(char *options, struct iso9660_options *popt)
		case Opt_ignore:
			break;
		case Opt_uid:
			if (match_int(&args[0], &option))
			if (match_uint(&args[0], &uv))
				return 0;
			popt->uid = make_kuid(current_user_ns(), option);
			popt->uid = make_kuid(current_user_ns(), uv);
			if (!uid_valid(popt->uid))
				return 0;
			popt->uid_set = 1;
			break;
		case Opt_gid:
			if (match_int(&args[0], &option))
			if (match_uint(&args[0], &uv))
				return 0;
			popt->gid = make_kgid(current_user_ns(), option);
			popt->gid = make_kgid(current_user_ns(), uv);
			if (!gid_valid(popt->gid))
				return 0;
			popt->gid_set = 1;
+1 −0
Original line number Diff line number Diff line
@@ -102,6 +102,7 @@ isofs_find_entry(struct inode *dir, struct dentry *dentry,
			printk(KERN_NOTICE "iso9660: Corrupted directory entry"
			       " in block %lu of inode %lu\n", block,
			       dir->i_ino);
			brelse(bh);
			return 0;
		}

+8 −3
Original line number Diff line number Diff line
@@ -164,19 +164,24 @@ static int v2_read_file_info(struct super_block *sb, int type)
		quota_error(sb, "Number of blocks too big for quota file size (%llu > %llu).",
		    (loff_t)qinfo->dqi_blocks << qinfo->dqi_blocksize_bits,
		    i_size_read(sb_dqopt(sb)->files[type]));
		goto out;
		goto out_free;
	}
	if (qinfo->dqi_free_blk >= qinfo->dqi_blocks) {
		quota_error(sb, "Free block number too big (%u >= %u).",
			    qinfo->dqi_free_blk, qinfo->dqi_blocks);
		goto out;
		goto out_free;
	}
	if (qinfo->dqi_free_entry >= qinfo->dqi_blocks) {
		quota_error(sb, "Block with free entry too big (%u >= %u).",
			    qinfo->dqi_free_entry, qinfo->dqi_blocks);
		goto out;
		goto out_free;
	}
	ret = 0;
out_free:
	if (ret) {
		kfree(info->dqi_priv);
		info->dqi_priv = NULL;
	}
out:
	up_read(&dqopt->dqio_sem);
	return ret;
+6 −3
Original line number Diff line number Diff line
@@ -544,10 +544,13 @@ static int udf_do_extend_file(struct inode *inode,

		udf_write_aext(inode, last_pos, &last_ext->extLocation,
				last_ext->extLength, 1);

		/*
		 * We've rewritten the last extent but there may be empty
		 * indirect extent after it - enter it.
		 * We've rewritten the last extent. If we are going to add
		 * more extents, we may need to enter possible following
		 * empty indirect extent.
		 */
		if (new_block_bytes || prealloc_len)
			udf_next_aext(inode, last_pos, &tmploc, &tmplen, 0);
	}

Loading