projects
/
platform
/
upstream
/
systemd.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c8ec393
)
ethtool: Fix speed in 593022fa377d40d9a645919759b04c53cf4eace8
author
Susant Sahani
<susant@redhat.com>
Mon, 26 Jun 2017 13:07:38 +0000
(18:37 +0530)
committer
Susant Sahani
<susant@redhat.com>
Mon, 26 Jun 2017 13:07:38 +0000
(18:37 +0530)
We should use the DIV_ROUND_UP
src/udev/net/ethtool-util.c
patch
|
blob
|
history
diff --git
a/src/udev/net/ethtool-util.c
b/src/udev/net/ethtool-util.c
index
19f5f04
..
201fc23
100644
(file)
--- a/
src/udev/net/ethtool-util.c
+++ b/
src/udev/net/ethtool-util.c
@@
-527,7
+527,7
@@
int ethtool_set_glinksettings(int *fd, const char *ifname, struct link_config *l
}
if (link->speed)
- u->base.speed =
link->speed
;
+ u->base.speed =
DIV_ROUND_UP(link->speed, 1000000)
;
if (link->duplex != _DUP_INVALID)
u->base.duplex = link->duplex;