From 1194e279d6bb68250fbf8c1dc8dcd961523c1352 Mon Sep 17 00:00:00 2001 From: Juergen Beisert Date: Tue, 15 Feb 2011 14:49:32 +0100 Subject: Generic environment: Fix assembling of the 'mtdparts' variable The semicolon is a delimiter, not an end marker. With a trailing semicolon the kernel give the confusing message: mtd: no mtd-id With this patch, a semicolon gets added on demand only. Signed-off-by: Juergen Beisert Signed-off-by: Sascha Hauer --- defaultenv/bin/boot | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'defaultenv') diff --git a/defaultenv/bin/boot b/defaultenv/bin/boot index 788a781159..7497791c0b 100644 --- a/defaultenv/bin/boot +++ b/defaultenv/bin/boot @@ -46,11 +46,14 @@ else fi if [ -n $nor_parts ]; then - mtdparts="${mtdparts}physmap-flash.0:${nor_parts};" + mtdparts="${mtdparts}physmap-flash.0:${nor_parts}" fi if [ -n $nand_parts ]; then - mtdparts="${mtdparts}${nand_device}:${nand_parts};" + if [ -n ${mtdparts} ]; then + mtdparts="${mtdparts};" + fi + mtdparts="${mtdparts}${nand_device}:${nand_parts}" fi if [ -n $mtdparts ]; then -- cgit v1.2.3