Commit 97c20ea8 authored by Rahul Lakkireddy's avatar Rahul Lakkireddy Committed by David S. Miller

cxgb4: fix 64-bit division on i386

Fix following compile error on i386 architecture.

ERROR: "__udivdi3" [drivers/net/ethernet/chelsio/cxgb4/cxgb4.ko] undefined!

Fixes: 0e395b3c ("cxgb4: add FLOWC based QoS offload")
Reported-by: default avatarkbuild test robot <lkp@intel.com>
Signed-off-by: default avatarRahul Lakkireddy <rahul.lakkireddy@chelsio.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 5bd2ce6a
...@@ -307,8 +307,8 @@ static int cxgb4_mqprio_alloc_tc(struct net_device *dev, ...@@ -307,8 +307,8 @@ static int cxgb4_mqprio_alloc_tc(struct net_device *dev,
p.u.params.channel = pi->tx_chan; p.u.params.channel = pi->tx_chan;
for (i = 0; i < mqprio->qopt.num_tc; i++) { for (i = 0; i < mqprio->qopt.num_tc; i++) {
/* Convert from bytes per second to Kbps */ /* Convert from bytes per second to Kbps */
p.u.params.minrate = mqprio->min_rate[i] * 8 / 1000; p.u.params.minrate = div_u64(mqprio->min_rate[i] * 8, 1000);
p.u.params.maxrate = mqprio->max_rate[i] * 8 / 1000; p.u.params.maxrate = div_u64(mqprio->max_rate[i] * 8, 1000);
e = cxgb4_sched_class_alloc(dev, &p); e = cxgb4_sched_class_alloc(dev, &p);
if (!e) { if (!e) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment