Skip to content

Commit

Permalink
6lowpan: iphc: fix SAM/DAM bit comment
Browse files Browse the repository at this point in the history
This patch fixes the comments for SAM/DAM value.

Signed-off-by: Alexander Aring <[email protected]>
Signed-off-by: Marcel Holtmann <[email protected]>
  • Loading branch information
Alexander Aring authored and holtmann committed Mar 10, 2016
1 parent 6aaf37b commit 24c4a81
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions net/6lowpan/iphc.c
Original file line number Diff line number Diff line change
Expand Up @@ -788,7 +788,7 @@ static u8 lowpan_compress_ctx_addr(u8 **hc_ptr, const struct in6_addr *ipaddr,
}

memset(&tmp, 0, sizeof(tmp));
/* check for SAM/DAM = 01 */
/* check for SAM/DAM = 10 */
tmp.s6_addr[11] = 0xFF;
tmp.s6_addr[12] = 0xFE;
memcpy(&tmp.s6_addr[14], &ipaddr->s6_addr[14], 2);
Expand All @@ -801,7 +801,7 @@ static u8 lowpan_compress_ctx_addr(u8 **hc_ptr, const struct in6_addr *ipaddr,
}

memset(&tmp, 0, sizeof(tmp));
/* check for SAM/DAM = 10, should always match */
/* check for SAM/DAM = 01, should always match */
memcpy(&tmp.s6_addr[8], &ipaddr->s6_addr[8], 8);
/* context information are always used */
ipv6_addr_prefix_copy(&tmp, &ctx->pfx, ctx->plen);
Expand Down

0 comments on commit 24c4a81

Please sign in to comment.