aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2008-08-02 09:14:49 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2008-08-02 09:14:49 -0700
commit071f4924844c435a3ae0cdbab7d7df2f1da85713 (patch)
treed7f339e8195c83b5e1aecc68e8173b7085d70e85
parentd9c566198bfdf72a041322a093fdc1a2dc231170 (diff)
parentf1136d022af8f07a97f59c6d07483bdb82ffbd8e (diff)
Merge git://git.infradead.org/users/dwmw2/random-2.6
* git://git.infradead.org/users/dwmw2/random-2.6: [MTD] Fix !CONFIG_BLOCK compile for mtdsuper.c firmware: silence __fw_modbuild and __fw_modinst 'Nothing to be done' messages
-rw-r--r--drivers/mtd/mtdsuper.c17
-rw-r--r--scripts/Makefile.fwinst4
2 files changed, 16 insertions, 5 deletions
diff --git a/drivers/mtd/mtdsuper.c b/drivers/mtd/mtdsuper.c
index 9b6af7e74a6..00d46e137b2 100644
--- a/drivers/mtd/mtdsuper.c
+++ b/drivers/mtd/mtdsuper.c
@@ -125,8 +125,11 @@ int get_sb_mtd(struct file_system_type *fs_type, int flags,
int (*fill_super)(struct super_block *, void *, int),
struct vfsmount *mnt)
{
+#ifdef CONFIG_BLOCK
struct block_device *bdev;
- int mtdnr, ret;
+ int ret, major;
+#endif
+ int mtdnr;
if (!dev_name)
return -EINVAL;
@@ -178,6 +181,7 @@ int get_sb_mtd(struct file_system_type *fs_type, int flags,
}
}
+#ifdef CONFIG_BLOCK
/* try the old way - the hack where we allowed users to mount
* /dev/mtdblock$(n) but didn't actually _use_ the blockdev
*/
@@ -190,22 +194,25 @@ int get_sb_mtd(struct file_system_type *fs_type, int flags,
DEBUG(1, "MTDSB: lookup_bdev() returned 0\n");
ret = -EINVAL;
- if (MAJOR(bdev->bd_dev) != MTD_BLOCK_MAJOR)
- goto not_an_MTD_device;
+ major = MAJOR(bdev->bd_dev);
mtdnr = MINOR(bdev->bd_dev);
bdput(bdev);
+ if (major != MTD_BLOCK_MAJOR)
+ goto not_an_MTD_device;
+
return get_sb_mtd_nr(fs_type, flags, dev_name, data, mtdnr, fill_super,
mnt);
not_an_MTD_device:
+#endif /* CONFIG_BLOCK */
+
if (!(flags & MS_SILENT))
printk(KERN_NOTICE
"MTD: Attempt to mount non-MTD device \"%s\"\n",
dev_name);
- bdput(bdev);
- return ret;
+ return -EINVAL;
}
EXPORT_SYMBOL_GPL(get_sb_mtd);
diff --git a/scripts/Makefile.fwinst b/scripts/Makefile.fwinst
index f63a663de15..6bf8e87f1dc 100644
--- a/scripts/Makefile.fwinst
+++ b/scripts/Makefile.fwinst
@@ -50,8 +50,12 @@ PHONY += __fw_install __fw_modinst FORCE
.PHONY: $(PHONY)
__fw_install: $(installed-fw)
+
__fw_modinst: $(installed-mod-fw)
+ @:
+
__fw_modbuild: $(addprefix $(obj)/,$(mod-fw))
+ @:
FORCE: