diff options
Diffstat (limited to 'net/bridge/br_stp_bpdu.c')
-rw-r--r-- | net/bridge/br_stp_bpdu.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/net/bridge/br_stp_bpdu.c b/net/bridge/br_stp_bpdu.c index 8deab645ef75..ddeb6e5d45d6 100644 --- a/net/bridge/br_stp_bpdu.c +++ b/net/bridge/br_stp_bpdu.c | |||
@@ -58,12 +58,12 @@ static inline void br_set_ticks(unsigned char *dest, int j) | |||
58 | { | 58 | { |
59 | unsigned long ticks = (STP_HZ * j)/ HZ; | 59 | unsigned long ticks = (STP_HZ * j)/ HZ; |
60 | 60 | ||
61 | put_unaligned(htons(ticks), (__be16 *)dest); | 61 | put_unaligned_be16(ticks, dest); |
62 | } | 62 | } |
63 | 63 | ||
64 | static inline int br_get_ticks(const unsigned char *src) | 64 | static inline int br_get_ticks(const unsigned char *src) |
65 | { | 65 | { |
66 | unsigned long ticks = ntohs(get_unaligned((__be16 *)src)); | 66 | unsigned long ticks = get_unaligned_be16(src); |
67 | 67 | ||
68 | return DIV_ROUND_UP(ticks * HZ, STP_HZ); | 68 | return DIV_ROUND_UP(ticks * HZ, STP_HZ); |
69 | } | 69 | } |