netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* i386 vs x86_64 struct tpacket_hdr layout
@ 2013-12-20 13:30 Norbert van Bolhuis
  2013-12-20 18:38 ` David Miller
  2014-01-06 22:58 ` single process receives own frames due to PACKET_MMAP Norbert van Bolhuis
  0 siblings, 2 replies; 17+ messages in thread
From: Norbert van Bolhuis @ 2013-12-20 13:30 UTC (permalink / raw)
  To: netdev, linux-net


I'm compiling my 32bit application with -m32 on a x86_64 system/kernel.

Things aren't working because for my application tp_len is at offset 4
but for the kernel it is at offset 8.

struct tpacket_hdr {
         unsigned long   tp_status;
         unsigned int    tp_len;
         unsigned int    tp_snaplen;
         unsigned short  tp_mac;
         unsigned short  tp_net;
         unsigned int    tp_sec;
         unsigned int    tp_usec;
};

How is this suppose to work ?

thanks,
Norbert van Bolhuis

^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2014-01-08 14:38 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-12-20 13:30 i386 vs x86_64 struct tpacket_hdr layout Norbert van Bolhuis
2013-12-20 18:38 ` David Miller
2013-12-20 18:45   ` Daniel Borkmann
2013-12-20 21:22     ` Norbert van Bolhuis
2014-01-06 22:58 ` single process receives own frames due to PACKET_MMAP Norbert van Bolhuis
2014-01-07  9:32   ` Daniel Borkmann
2014-01-07 10:06     ` Jesper Dangaard Brouer
2014-01-07 13:16       ` Norbert van Bolhuis
2014-01-07 13:47         ` Daniel Borkmann
2014-01-07 14:09         ` Jesper Dangaard Brouer
2014-01-07 15:16           ` Norbert van Bolhuis
2014-01-07 15:26             ` Daniel Borkmann
2014-01-07 15:46               ` Norbert van Bolhuis
2014-01-07 15:57                 ` Daniel Borkmann
2014-01-08 14:18                   ` Norbert van Bolhuis
2014-01-08 14:24                     ` Daniel Borkmann
2014-01-08 14:36                       ` Norbert van Bolhuis

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).