summaryrefslogtreecommitdiffstats
path: root/net/bridge/br_stp_bpdu.c
diff options
context:
space:
mode:
authorHarvey Harrison <harvey.harrison@gmail.com>2008-05-02 16:26:16 -0700
committerDavid S. Miller <davem@davemloft.net>2008-05-02 16:26:16 -0700
commitd3e2ce3bcdbf4319dea308c79b5f72a8ecc8015c (patch)
treeaa83f30213ecb17a653fe16c55e3bc5449aa2d7c /net/bridge/br_stp_bpdu.c
parent83985319393973f280ca2a797047780a7955cf19 (diff)
downloadblackbird-op-linux-d3e2ce3bcdbf4319dea308c79b5f72a8ecc8015c.tar.gz
blackbird-op-linux-d3e2ce3bcdbf4319dea308c79b5f72a8ecc8015c.zip
net: use get/put_unaligned_* helpers
Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/bridge/br_stp_bpdu.c')
-rw-r--r--net/bridge/br_stp_bpdu.c4
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)
{
unsigned long ticks = (STP_HZ * j)/ HZ;
- put_unaligned(htons(ticks), (__be16 *)dest);
+ put_unaligned_be16(ticks, dest);
}
static inline int br_get_ticks(const unsigned char *src)
{
- unsigned long ticks = ntohs(get_unaligned((__be16 *)src));
+ unsigned long ticks = get_unaligned_be16(src);
return DIV_ROUND_UP(ticks * HZ, STP_HZ);
}
OpenPOWER on IntegriCloud