diff options
author | 2010-06-21 19:56:42 +0000 | |
---|---|---|
committer | 2010-06-21 19:56:42 +0000 | |
commit | f2b96a87470bba45d636974b110bf42442f24aad (patch) | |
tree | cce865ba6ff64fc28c26b9b99b2cdc7fe6ddc7bd | |
parent | Implement PA linearization on adapters with digital predistorters (diff) | |
download | wireguard-openbsd-f2b96a87470bba45d636974b110bf42442f24aad.tar.xz wireguard-openbsd-f2b96a87470bba45d636974b110bf42442f24aad.zip |
use LE_READ_4/LE_READ_2 instead of hardcoding
-rw-r--r-- | sys/dev/ic/athn.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/dev/ic/athn.c b/sys/dev/ic/athn.c index ffff833c5a5..80165cfeb1b 100644 --- a/sys/dev/ic/athn.c +++ b/sys/dev/ic/athn.c @@ -1,4 +1,4 @@ -/* $OpenBSD: athn.c,v 1.52 2010/06/21 19:46:50 damien Exp $ */ +/* $OpenBSD: athn.c,v 1.53 2010/06/21 19:56:42 damien Exp $ */ /*- * Copyright (c) 2009 Damien Bergamini <damien.bergamini@free.fr> @@ -1013,8 +1013,8 @@ athn_set_key(struct ieee80211com *ic, struct ieee80211_node *ni, if (!(k->k_flags & IEEE80211_KEY_GROUP)) { addr = ni->ni_macaddr; - lo = addr[0] | addr[1] << 8 | addr[2] << 16 | addr[3] << 24; - hi = addr[4] | addr[5] << 8; + lo = LE_READ_4(&addr[0]); + hi = LE_READ_2(&addr[4]); lo = lo >> 1 | hi << 31; hi = hi >> 1; } else |