diff options
author | Felix Fietkau <nbd@openwrt.org> | 2006-06-16 05:27:39 +0000 |
---|---|---|
committer | Felix Fietkau <nbd@openwrt.org> | 2006-06-16 05:27:39 +0000 |
commit | 51b6a6f3c86f20c4a2de45321bc119aaa2cf130e (patch) | |
tree | 7030929d01ee8dd1ad4b7b8219ec212d22216e72 /openwrt/target/linux | |
parent | 02e8cd6b156739dcc8e1c1f5df8987f8804c5755 (diff) | |
download | mtk-20170518-51b6a6f3c86f20c4a2de45321bc119aaa2cf130e.zip mtk-20170518-51b6a6f3c86f20c4a2de45321bc119aaa2cf130e.tar.gz mtk-20170518-51b6a6f3c86f20c4a2de45321bc119aaa2cf130e.tar.bz2 |
put a size limit on rb532 cf partitions
SVN-Revision: 3960
Diffstat (limited to 'openwrt/target/linux')
-rw-r--r-- | openwrt/target/linux/rb532-2.6/patches/130-custom_partitions.patch | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/openwrt/target/linux/rb532-2.6/patches/130-custom_partitions.patch b/openwrt/target/linux/rb532-2.6/patches/130-custom_partitions.patch index 8aabd66..e4b3327 100644 --- a/openwrt/target/linux/rb532-2.6/patches/130-custom_partitions.patch +++ b/openwrt/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 |