net: mscc: ocelot: add missed parentheses around macro argument
authorColin Foster <colin.foster@in-advantage.com>
Sat, 30 Apr 2022 23:23:27 +0000 (16:23 -0700)
committerJakub Kicinski <kuba@kernel.org>
Mon, 2 May 2022 21:04:17 +0000 (14:04 -0700)
Commit 2f187bfa6f35 ("net: ethernet: ocelot: remove the need for num_stats
initializer") added a macro that patchwork warned it lacked parentheses
around an argument. Correct this mistake.

Fixes: 2f187bfa6f35 ("net: ethernet: ocelot: remove the need for num_stats initializer")
Signed-off-by: Colin Foster <colin.foster@in-advantage.com>
Reviewed-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Tested-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
include/soc/mscc/ocelot.h

index 75739766244bb185d385b1c0a78e229b40b34b09..8d8d46778f7e64b9039854b5671fe61c59fe2f35 100644 (file)
 #define REG_RESERVED(reg)              REG(reg, REG_RESERVED_ADDR)
 
 #define for_each_stat(ocelot, stat)                            \
-       for ((stat) = ocelot->stats_layout;                     \
+       for ((stat) = (ocelot)->stats_layout;                   \
             ((stat)->name[0] != '\0');                         \
             (stat)++)