diff options
author | Grant Likely <grant.likely@secretlab.ca> | 2013-02-12 12:41:22 -0500 |
---|---|---|
committer | Grant Likely <grant.likely@secretlab.ca> | 2013-02-13 05:05:57 -0500 |
commit | f7f951c29835622d6096530393a8322131059917 (patch) | |
tree | 8514feeca617c2c608c18488791c47f7d02b0fa4 /drivers/of/selftest.c | |
parent | c31a0c052205e3ec24efc3fe18ef70c3e913f2d4 (diff) |
of/selftest: Fix GPIOs selftest to cover the 7th case
The of_gpio_named_count() self test doesn't hit the out-of-range
condition even though it is coded. Fix the bug by increasing the for
loop range by one.
Reported-by: Andreas Larsson <andreas@gaisler.com>
Cc: Rob Herring <rob.herring@calxeda.com>
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Diffstat (limited to 'drivers/of/selftest.c')
-rw-r--r-- | drivers/of/selftest.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/of/selftest.c b/drivers/of/selftest.c index f24ffd7088d2..9f62eb58dbc7 100644 --- a/drivers/of/selftest.c +++ b/drivers/of/selftest.c | |||
@@ -35,7 +35,7 @@ static void __init of_selftest_parse_phandle_with_args(void) | |||
35 | return; | 35 | return; |
36 | } | 36 | } |
37 | 37 | ||
38 | for (i = 0; i < 7; i++) { | 38 | for (i = 0; i < 8; i++) { |
39 | bool passed = true; | 39 | bool passed = true; |
40 | rc = of_parse_phandle_with_args(np, "phandle-list", | 40 | rc = of_parse_phandle_with_args(np, "phandle-list", |
41 | "#phandle-cells", i, &args); | 41 | "#phandle-cells", i, &args); |