of_path: Fix bug with partitions, simply code
In commit 75b6827 using a path that
has a partition description broke.

Fix this and simpfy the code some.

There is no need to loop over each string in the path property:  it's
defined to have at most one parition description, no extant dts has
more than one, and how it would handle more than one didn't make sense
anyway.

Once not looping, __of_find_path() just needs the partition
description text, not both the original node and property name to look
it up from.

When using a partition description, don't lookup the cdev of the node
just to replace it with the partition's cdev.

Signed-off-by: Trent Piepho <tpiepho@kymetacorp.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
1 parent 91adf62 commit 51e97d11dc81e12c2d8bddc1e79f6d40de49f3de
@Trent Piepho Trent Piepho authored on 16 Dec 2015
Sascha Hauer committed on 8 Jan 2016
Showing 1 changed file
View
drivers/of/of_path.c