|
|
|
Re: Question about tlv message support | |
| [Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] | |
On Tue, Apr 17, 2012 at 2:36 AM, NorthPole <morfeas3000@xxxxxxxxx> wrote: > @JAYESH TANK > thank you very much :-) that was a very good starting poind :D > > > @Javier > you are right, so here is something more specific > > I want to add a framework for tlv message construction and parsing in > a wireless mesh routing protocol so as it can have the advantages of > the tlv way of communication (one of which is backwards compatibility) > > afaik tlvs are used in many places in the kernel and as Jayesh stated > there are no ready made apis. > So if I want to do that I have to copy someone else's code and modify > it accordingly > Hi, Netlink has some sort of TLV: nla_put_string(), nla_put_u32(), nla_put_u8(), etc. But use a socket buffer (struct sk_buff) to store this data. Since you will use to store and retrieve this info for a networking protocol (mesh routing), it probably makes sense to reuse Netlink functions. Take a look to: include/net/netlink.h Hope it helps, -- Javier Martínez Canillas (+34) 682 39 81 69 Barcelona, Spain _______________________________________________ Kernelnewbies mailing list Kernelnewbies@xxxxxxxxxxxxxxxxx http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies
[Newbies FAQ] [Linux Kernel Development] [IETF Annouce] [Git] [Networking] [Security] [Bugtraq] [Photo] [Yosemite] [MIPS Linux] [ARM Linux] [Linux Security] [Linux Networking] [Linux RAID] [Linux SCSI] [Linux ACPI]
![]() |
![]() |