VIDEOS 》 Linux Kernel struct tcphdr data-structure
Refer: Kernel Doc printk-formats.txt - http://elixir.free-electrons.com/linux/latest/source/Documentation/printk-formats.txt
Here is the screenshot of my Sample Example Code discussed in the video above:
Refer:
struct tcphdr data-structure - http://elixir.free-electrons.com/linux/latest/source/include/uapi/linux/tcp.h#L24
sk_buff to tcphdr APIs - http://elixir.free-electrons.com/linux/latest/source/include/linux/tcp.h
Definitions for the TCP module - http://elixir.free-electrons.com/linux/latest/source/include/net/tcp.h
And here is the copy paste of struct tcp data-structure
(/include/uapi/linux/tcp.h)
from the Kernel-source version 4.13 for quick reference:
struct tcphdr { __be16 source; __be16 dest; __be32 seq; __be32 ack_seq; #if defined(__LITTLE_ENDIAN_BITFIELD) __u16 res1:4, doff:4, fin:1, syn:1, rst:1, psh:1, ack:1, urg:1, ece:1, cwr:1; #elif defined(__BIG_ENDIAN_BITFIELD) __u16 doff:4, res1:4, cwr:1, ece:1, urg:1, ack:1, psh:1, rst:1, syn:1, fin:1; #else #error "Adjust yourdefines" #endif __be16 window; __sum16 check; __be16 urg_ptr; };
Suggested Topics:
Video Episodes :: Linux Kernel programming
Saturday' 13-Mar-2021
Wednesday' 18-May-2022
Saturday' 13-Mar-2021
Wednesday' 18-May-2022
Saturday' 14-May-2022
Saturday' 13-Mar-2021
Join The Linux Channel :: Facebook Group ↗
Visit The Linux Channel :: on Youtube ↗
💗 Help shape the future: Sponsor/Donate
Recommended Topics:
Featured Video:
Saturday' 13-Mar-2021
Trending Video:
Saturday' 13-Mar-2021
Recommended Video: