diff options
author | Tom Gundersen <teg@jklm.no> | 2014-07-21 20:54:09 +0200 |
---|---|---|
committer | Tom Gundersen <teg@jklm.no> | 2014-07-21 20:54:09 +0200 |
commit | c9e738b91199475c88a2f89da448a026e9186058 (patch) | |
tree | 5e3dcc2fae7bdf7275961585c8bc50ac50b67d01 | |
parent | d9c52fa045d53e2b802102114e9c557c43024eb5 (diff) |
networkd: bridge - use USEC_PER_MSEC macros
Lennart said:
> We have these nice USEC_PER_MSEC-style macro definitions which make it a
> little bit clearer what we are converting here from what into
> what... please use that instead of writing "1000"...
>
> (we stole those from gstreamer btw)
-rw-r--r-- | src/network/networkd-netdev-bond.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/network/networkd-netdev-bond.c b/src/network/networkd-netdev-bond.c index 1f57083626..46408213b7 100644 --- a/src/network/networkd-netdev-bond.c +++ b/src/network/networkd-netdev-bond.c @@ -146,7 +146,7 @@ static int netdev_bond_fill_message_create(NetDev *netdev, Link *link, sd_rtnl_m } if (b->miimon != 0) { - r = sd_rtnl_message_append_u32(m, IFLA_BOND_MIIMON, b->miimon / 1000); + r = sd_rtnl_message_append_u32(m, IFLA_BOND_MIIMON, b->miimon / USEC_PER_MSEC); if (r < 0) { log_error_netdev(netdev, "Could not append IFLA_BOND_BOND_MIIMON attribute: %s", @@ -156,7 +156,7 @@ static int netdev_bond_fill_message_create(NetDev *netdev, Link *link, sd_rtnl_m } if (b->downdelay != 0) { - r = sd_rtnl_message_append_u32(m, IFLA_BOND_DOWNDELAY, b->downdelay / 1000); + r = sd_rtnl_message_append_u32(m, IFLA_BOND_DOWNDELAY, b->downdelay / USEC_PER_MSEC); if (r < 0) { log_error_netdev(netdev, "Could not append IFLA_BOND_DOWNDELAY attribute: %s", @@ -166,7 +166,7 @@ static int netdev_bond_fill_message_create(NetDev *netdev, Link *link, sd_rtnl_m } if (b->updelay != 0) { - r = sd_rtnl_message_append_u32(m, IFLA_BOND_UPDELAY, b->updelay / 1000); + r = sd_rtnl_message_append_u32(m, IFLA_BOND_UPDELAY, b->updelay / USEC_PER_MSEC); if (r < 0) { log_error_netdev(netdev, "Could not append IFLA_BOND_UPDELAY attribute: %s", |