Skip to contentSkip to conversation

dtc: remove extra parentheses to pass clang check

PATCH New Mike Frysinger 1 participant 1 message Dec 19, 2013

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 dtc: remove extra parentheses to pass clang check

From: Yunlian Jiang <[email protected]>

When building with clang, we get warnings like:
checks.c:623:32: error: equality comparison with extraneous parentheses

                        [-Werror,-Wparentheses-equality]
	if ((node->parent->addr_cells == -1))

URL: http://crbug.com/230457

---
 checks.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
checks.c +2 -2
index ee96a25..e66d55c 100644
@@ -624,11 +624,11 @@ static void check_avoid_default_addr_size(struct check *c, struct node *dt,
 	if (!reg && !ranges)
 		return;
 
-	if ((node->parent->addr_cells == -1))
+	if (node->parent->addr_cells == -1)
 		FAIL(c, "Relying on default #address-cells value for %s",
 		     node->fullpath);
 
-	if ((node->parent->size_cells == -1))
+	if (node->parent->size_cells == -1)
 		FAIL(c, "Relying on default #size-cells value for %s",
 		     node->fullpath);
 }
Signature · 6 lines
1.8.4.3

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html