Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit fdc0ad80 authored by Linus Torvalds's avatar Linus Torvalds
Browse files

Merge branch 'for-linus' of git://git.infradead.org/ubi-2.6

* 'for-linus' of git://git.infradead.org/ubi-2.6:
  UBIFS: fix assertion warning and refine comments
  UBIFS: kill CONFIG_UBIFS_FS_DEBUG_CHKS
  UBIFS: use GFP_NOFS properly
  UBI: use GFP_NOFS properly
parents dc87c551 6ed09c34
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -1345,7 +1345,7 @@ int ubi_dbg_check_write(struct ubi_device *ubi, const void *buf, int pnum,
	if (!(ubi_chk_flags & UBI_CHK_IO))
		return 0;

	buf1 = __vmalloc(len, GFP_KERNEL | GFP_NOFS, PAGE_KERNEL);
	buf1 = __vmalloc(len, GFP_NOFS, PAGE_KERNEL);
	if (!buf1) {
		ubi_err("cannot allocate memory to check writes");
		return 0;
@@ -1409,7 +1409,7 @@ int ubi_dbg_check_all_ff(struct ubi_device *ubi, int pnum, int offset, int len)
	if (!(ubi_chk_flags & UBI_CHK_IO))
		return 0;

	buf = __vmalloc(len, GFP_KERNEL | GFP_NOFS, PAGE_KERNEL);
	buf = __vmalloc(len, GFP_NOFS, PAGE_KERNEL);
	if (!buf) {
		ubi_err("cannot allocate memory to check for 0xFFs");
		return 0;
+0 −9
Original line number Diff line number Diff line
@@ -58,12 +58,3 @@ config UBIFS_FS_DEBUG
	  down UBIFS. You can then further enable / disable individual  debugging
	  features using UBIFS module parameters and the corresponding sysfs
	  interfaces.

config UBIFS_FS_DEBUG_CHKS
	bool "Enable extra checks"
	depends on UBIFS_FS_DEBUG
	help
	  If extra checks are enabled UBIFS will check the consistency of its
	  internal data structures during operation. However, UBIFS performance
	  is dramatically slower when this option is selected especially if the
	  file system is large.
+1 −1
Original line number Diff line number Diff line
@@ -818,7 +818,7 @@ void dbg_dump_leb(const struct ubifs_info *c, int lnum)
	printk(KERN_DEBUG "(pid %d) start dumping LEB %d\n",
	       current->pid, lnum);

	buf = __vmalloc(c->leb_size, GFP_KERNEL | GFP_NOFS, PAGE_KERNEL);
	buf = __vmalloc(c->leb_size, GFP_NOFS, PAGE_KERNEL);
	if (!buf) {
		ubifs_err("cannot allocate memory for dumping LEB %d", lnum);
		return;
+7 −4
Original line number Diff line number Diff line
@@ -448,10 +448,12 @@ static int ubifs_write_begin(struct file *file, struct address_space *mapping,
		if (!(pos & ~PAGE_CACHE_MASK) && len == PAGE_CACHE_SIZE) {
			/*
			 * We change whole page so no need to load it. But we
			 * have to set the @PG_checked flag to make the further
			 * code know that the page is new. This might be not
			 * true, but it is better to budget more than to read
			 * the page from the media.
			 * do not know whether this page exists on the media or
			 * not, so we assume the latter because it requires
			 * larger budget. The assumption is that it is better
			 * to budget a bit more than to read the page from the
			 * media. Thus, we are setting the @PG_checked flag
			 * here.
			 */
			SetPageChecked(page);
			skipped_read = 1;
@@ -559,6 +561,7 @@ static int ubifs_write_end(struct file *file, struct address_space *mapping,
		dbg_gen("copied %d instead of %d, read page and repeat",
			copied, len);
		cancel_budget(c, page, ui, appending);
		ClearPageChecked(page);

		/*
		 * Return 0 to force VFS to repeat the whole operation, or the
+1 −1
Original line number Diff line number Diff line
@@ -1094,7 +1094,7 @@ static int scan_check_cb(struct ubifs_info *c,
		}
	}

	buf = __vmalloc(c->leb_size, GFP_KERNEL | GFP_NOFS, PAGE_KERNEL);
	buf = __vmalloc(c->leb_size, GFP_NOFS, PAGE_KERNEL);
	if (!buf) {
		ubifs_err("cannot allocate memory to scan LEB %d", lnum);
		goto out;
Loading