/* * netsniff-ng - the packet sniffing beast * Copyright 2009, 2010 Daniel Borkmann. * Subject to the GPL, version 2. */ #ifndef RX_RING_H #define RX_RING_H #include #include "ring.h" #include "built_in.h" extern void destroy_rx_ring(int sock, struct ring *ring); extern void create_rx_ring(int sock, struct ring *ring, int verbose); extern void mmap_rx_ring(int sock, struct ring *ring); extern void alloc_rx_ring_frames(int sock, struct ring *ring); extern void bind_rx_ring(int sock, struct ring *ring, int ifindex); extern void setup_rx_ring_layout(int sock, struct ring *ring, unsigned int size, bool jumbo_support, bool v3); extern void sock_rx_net_stats(int sock); static inline int user_may_pull_from_rx(struct tpacket2_hdr *hdr) { return ((hdr->tp_status & TP_STATUS_USER) == TP_STATUS_USER); } static inline int user_may_pull_from_rx_block(struct block_desc *pbd) { return ((pbd->h1.block_status & TP_STATUS_USER) == TP_STATUS_USER); } static inline void kernel_may_pull_from_rx(struct tpacket2_hdr *hdr) { hdr->tp_status = TP_STATUS_KERNEL; } static inline void kernel_may_pull_from_rx_block(struct block_desc *pbd) { pbd->h1.block_status = TP_STATUS_KERNEL; } #endif /* RX_RING_H */ ' selected='selected'>packet-loop-back net-next plumbingsTobias Klauser
summaryrefslogtreecommitdiff
path: root/fs
diff options
context:
space:
mode:
authorDeepa Dinamani <deepa.kernel@gmail.com>2016-12-12 16:41:26 -0800
committerLinus Torvalds <torvalds@linux-foundation.org>2016-12-12 18:55:06 -0800
commitc62c38f6b91b87a013bccd3637c2a1850d8e590c (patch)
tree5e76cc9fdd96e0db768bf77727b3d8fec4f8168f /fs
parent395627b0718b6d4252c451c766cfc00ec155ddaf (diff)
ocfs2: replace CURRENT_TIME macro
CURRENT_TIME is not y2038 safe. Use y2038 safe ktime_get_real_seconds() here for timestamps. struct heartbeat_block's hb_seq and deletetion time are already 64 bits wide and accommodate times beyond y2038. Also use y2038 safe ktime_get_real_ts64() for on disk inode timestamps. These are also wide enough to accommodate time64_t. Link: http://lkml.kernel.org/r/1475365298-29236-1-git-send-email-deepa.kernel@gmail.com Signed-off-by: Deepa Dinamani <deepa.kernel@gmail.com> Reviewed-by: Arnd Bergmann <arnd@arndb.de> Cc: Mark Fasheh <mfasheh@versity.com> Cc: Joel Becker <jlbec@evilplan.org> Cc: Junxiao Bi <junxiao.bi@oracle.com> Cc: Joseph Qi <jiangqi903@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs')