summaryrefslogtreecommitdiffstats
path: root/net/sched
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2016-03-01 23:44:59 +0100
committerDavid S. Miller <davem@davemloft.net>2016-03-01 23:44:59 +0100
commit241deec94425b5e962e2bf8a929d563afda045f7 (patch)
tree7d9e24145da8527a0868f27af05753f5fb514b08 /net/sched
parentof_mdio: kill useless variable in of_mdiobus_register() (diff)
downloadlinux-241deec94425b5e962e2bf8a929d563afda045f7.tar.xz
linux-241deec94425b5e962e2bf8a929d563afda045f7.zip
sch_mqprio: Fix build with older gcc.
CC [M] net/sched/sch_mqprio.o net/sched/sch_mqprio.c: In function ?mqprio_init?: net/sched/sch_mqprio.c:145: error: unknown field ?tc? specified in initializer net/sched/sch_mqprio.c:145: warning: missing braces around initializer net/sched/sch_mqprio.c:145: warning: (near initialization for ?tc.<anonymous>?) make[2]: *** [net/sched/sch_mqprio.o] Error 1 make[1]: *** [net/sched] Error 2 make: *** [net] Error 2 Several people reported this, surround the unnamed union member initialization with braces to fix. Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/sched')
-rw-r--r--net/sched/sch_mqprio.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/sched/sch_mqprio.c b/net/sched/sch_mqprio.c
index f9947d1f4952..02ffb3fbbc20 100644
--- a/net/sched/sch_mqprio.c
+++ b/net/sched/sch_mqprio.c
@@ -142,7 +142,7 @@ static int mqprio_init(struct Qdisc *sch, struct nlattr *opt)
*/
if (qopt->hw) {
struct tc_to_netdev tc = {.type = TC_SETUP_MQPRIO,
- .tc = qopt->num_tc};
+ { .tc = qopt->num_tc }};
priv->hw_owned = 1;
err = dev->netdev_ops->ndo_setup_tc(dev, sch->handle, 0, &tc);