/* * netsniff-ng - the packet sniffing beast * Copyright (C) 2009, 2010 Daniel Borkmann * Copyright (C) 2012 Christoph Jaeger * Subject to the GPL, version 2. */ #ifndef PROTO_H #define PROTO_H #include #include #include "hash.h" #include "tprintf.h" struct pkt_buff; struct protocol { /* Needs to be filled out by user */ unsigned int key; void (*print_full)(struct pkt_buff *pkt); void (*print_less)(struct pkt_buff *pkt); /* Used by program logic */ struct protocol *next; void (*process) (struct pkt_buff *pkt); }; extern void empty(struct pkt_buff *pkt); extern void hex(struct pkt_buff *pkt); extern void ascii(struct pkt_buff *pkt); extern void hex_ascii(struct pkt_buff *pkt); #endif /* PROTO_H */ ='/cgit.cgi/'>index : net-next.git
net-next plumbingsTobias Klauser
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSuresh Warrier <warrier@linux.vnet.ibm.com>2016-08-19 15:35:55 +1000
committerPaul Mackerras <paulus@ozlabs.org>2016-09-12 10:12:23 +1000
commit366274f59c4de018f72ab44bb41ccaf3d657eb52 (patch)
treee4dae5bc867ae5d73a2e04dd16db9f66c3da5e68
parent644abbb254b1ab171f777431b23e6fb5879599d0 (diff)
KVM: PPC: Book3S HV: Update irq stats for IRQs handled in real mode
When a passthrough IRQ is handled completely within KVM real mode code, it has to also update the IRQ stats since this does not go through the generic IRQ handling code. However, the per CPU kstat_irqs field is an allocated (not static) field and so cannot be directly accessed in real mode safely. The function this_cpu_inc_rm() is introduced to safely increment per CPU fields (currently coded for unsigned integers only) that are allocated and could thus be vmalloced also. Signed-off-by: Suresh Warrier <warrier@linux.vnet.ibm.com> Signed-off-by: Paul Mackerras <paulus@ozlabs.org>