Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 280128
b: refs/heads/master
c: 88af7f5
h: refs/heads/master
v: v3
  • Loading branch information
Benoit Cousson authored and Rob Herring committed Dec 19, 2011
1 parent 6503821 commit 0a67f24
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 44ad56b7df54cbc8063b46883d183e4e2f09f831
refs/heads/master: 88af7f58c6f1fa28d617392c791f11317bcb590d
8 changes: 3 additions & 5 deletions trunk/drivers/of/base.c
Original file line number Diff line number Diff line change
Expand Up @@ -752,7 +752,7 @@ int of_property_read_string_index(struct device_node *np, const char *propname,

for (i = 0; total < prop->length; total += l, p += l) {
l = strlen(p) + 1;
if ((*p != 0) && (i++ == index)) {
if (i++ == index) {
*output = p;
return 0;
}
Expand Down Expand Up @@ -790,11 +790,9 @@ int of_property_count_strings(struct device_node *np, const char *propname)

p = prop->value;

for (i = 0; total < prop->length; total += l, p += l) {
for (i = 0; total < prop->length; total += l, p += l, i++)
l = strlen(p) + 1;
if (*p != 0)
i++;
}

return i;
}
EXPORT_SYMBOL_GPL(of_property_count_strings);
Expand Down

0 comments on commit 0a67f24

Please sign in to comment.