Skip to content

Commit aaf68ba

Browse files
lunngregkh
authored andcommitted
net: dsa: mv88e6xxx: Fix u64 statistics
[ Upstream commit 6e46e2d ] The switch maintains u64 counters for the number of octets sent and received. These are kept as two u32's which need to be combined. Fix the combing, which wrongly worked on u16's. Fixes: 80c4627 ("dsa: mv88x6xxx: Refactor getting a single statistic") Reported-by: Chris Healy <Chris.Healy@zii.aero> Signed-off-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent dc18101 commit aaf68ba

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

drivers/net/dsa/mv88e6xxx.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -712,7 +712,7 @@ static uint64_t _mv88e6xxx_get_ethtool_stat(struct dsa_switch *ds,
712712
if (s->sizeof_stat == 8)
713713
_mv88e6xxx_stats_read(ds, s->reg + 1, &high);
714714
}
715-
value = (((u64)high) << 16) | low;
715+
value = (((u64)high) << 32) | low;
716716
return value;
717717
}
718718

0 commit comments

Comments
 (0)