Merge branch 'for-linus' of git://ftp.arm.linux.org.uk/~rmk/linux-arm
[sfrench/cifs-2.6.git] / net / 6lowpan / nhc_dest.c
1 /*
2  *      6LoWPAN IPv6 Destination Options Header compression according to
3  *      RFC6282
4  *
5  *      This program is free software; you can redistribute it and/or
6  *      modify it under the terms of the GNU General Public License
7  *      as published by the Free Software Foundation; either version
8  *      2 of the License, or (at your option) any later version.
9  */
10
11 #include "nhc.h"
12
13 #define LOWPAN_NHC_DEST_IDLEN   1
14 #define LOWPAN_NHC_DEST_ID_0    0xe6
15 #define LOWPAN_NHC_DEST_MASK_0  0xfe
16
17 static void dest_nhid_setup(struct lowpan_nhc *nhc)
18 {
19         nhc->id[0] = LOWPAN_NHC_DEST_ID_0;
20         nhc->idmask[0] = LOWPAN_NHC_DEST_MASK_0;
21 }
22
23 LOWPAN_NHC(nhc_dest, "RFC6282 Destination Options", NEXTHDR_DEST, 0,
24            dest_nhid_setup, LOWPAN_NHC_DEST_IDLEN, NULL, NULL);
25
26 module_lowpan_nhc(nhc_dest);
27 MODULE_DESCRIPTION("6LoWPAN next header RFC6282 Destination Options compression");
28 MODULE_LICENSE("GPL");