When the partition name already starts with "devname." skip this when adding the partition. Signed-off-by: Sascha Hauer <s.hauer@xxxxxxxxxxxxxx> --- lib/cmdlinepart.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/cmdlinepart.c b/lib/cmdlinepart.c index df6f17a..d7d4441 100644 --- a/lib/cmdlinepart.c +++ b/lib/cmdlinepart.c @@ -61,7 +61,8 @@ int cmdlinepart_do_parse_one(const char *devname, const char *partstr, return -EINVAL; } - if (partition_flags & CMDLINEPART_ADD_DEVNAME) + if ((partition_flags & CMDLINEPART_ADD_DEVNAME) && + strncmp(devname, partstr, strlen(devname))) sprintf(buf, "%s.", devname); memcpy(buf + strlen(buf), partstr, end - partstr); -- 2.1.4 _______________________________________________ barebox mailing list barebox@xxxxxxxxxxxxxxxxxxx http://lists.infradead.org/mailman/listinfo/barebox