aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/rb532-2.6/patches/130-custom_partitions.patch
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2006-06-16 05:27:39 +0000
committerFelix Fietkau <nbd@openwrt.org>2006-06-16 05:27:39 +0000
commitdf81d443a47bcffaecff793919843e39b4b71bd4 (patch)
treee591f0e3826b53cb5efbd3622cbf2a33982387b6 /target/linux/rb532-2.6/patches/130-custom_partitions.patch
parentc40693e00d85a4ce40e5631247f0716f123ca5b1 (diff)
downloadmaster-187ad058-df81d443a47bcffaecff793919843e39b4b71bd4.tar.gz
master-187ad058-df81d443a47bcffaecff793919843e39b4b71bd4.tar.bz2
master-187ad058-df81d443a47bcffaecff793919843e39b4b71bd4.zip
put a size limit on rb532 cf partitions
git-svn-id: svn://svn.openwrt.org/openwrt/branches/buildroot-ng/openwrt@3960 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/rb532-2.6/patches/130-custom_partitions.patch')
-rw-r--r--target/linux/rb532-2.6/patches/130-custom_partitions.patch5
1 files changed, 4 insertions, 1 deletions
diff --git a/target/linux/rb532-2.6/patches/130-custom_partitions.patch b/target/linux/rb532-2.6/patches/130-custom_partitions.patch
index 8aabd66d0c..e4b332703a 100644
--- a/target/linux/rb532-2.6/patches/130-custom_partitions.patch
+++ b/target/linux/rb532-2.6/patches/130-custom_partitions.patch
@@ -49,7 +49,7 @@ diff -urN linux.old/fs/partitions/Makefile linux.dev/fs/partitions/Makefile
diff -urN linux.old/fs/partitions/openwrt.c linux.dev/fs/partitions/openwrt.c
--- linux.old/fs/partitions/openwrt.c 1970-01-01 01:00:00.000000000 +0100
+++ linux.dev/fs/partitions/openwrt.c 2006-06-15 01:27:17.000000000 +0200
-@@ -0,0 +1,246 @@
+@@ -0,0 +1,249 @@
+/*
+ * fs/partitions/openwrt.c
+ *
@@ -285,6 +285,8 @@ diff -urN linux.old/fs/partitions/openwrt.c linux.dev/fs/partitions/openwrt.c
+ printk(" >");
+ continue;
+ }
++ if ((start + size) > get_capacity(bdev->bd_disk))
++ size = get_capacity(bdev->bd_disk) - start;
+ last_block = start + size;
+ put_partition(state, slot, start, size);
+ }
@@ -296,6 +298,7 @@ diff -urN linux.old/fs/partitions/openwrt.c linux.dev/fs/partitions/openwrt.c
+ put_dev_sector(sect);
+ return 1;
+}
++
diff -urN linux.old/fs/partitions/openwrt.h linux.dev/fs/partitions/openwrt.h
--- linux.old/fs/partitions/openwrt.h 1970-01-01 01:00:00.000000000 +0100
+++ linux.dev/fs/partitions/openwrt.h 2006-06-15 01:27:17.000000000 +0200