Files
kernel_arpi/include/uapi/linux
Daniel Borkmann 045efa82ff cls_bpf: introduce integrated actions
Often cls_bpf classifier is used with single action drop attached.
Optimize this use case and let cls_bpf return both classid and action.
For backwards compatibility reasons enable this feature under
TCA_BPF_FLAG_ACT_DIRECT flag.

Then more interesting programs like the following are easier to write:
int cls_bpf_prog(struct __sk_buff *skb)
{
  /* classify arp, ip, ipv6 into different traffic classes
   * and drop all other packets
   */
  switch (skb->protocol) {
  case htons(ETH_P_ARP):
    skb->tc_classid = 1;
    break;
  case htons(ETH_P_IP):
    skb->tc_classid = 2;
    break;
  case htons(ETH_P_IPV6):
    skb->tc_classid = 3;
    break;
  default:
    return TC_ACT_SHOT;
  }

  return TC_ACT_OK;
}

Joint work with Daniel Borkmann.

Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Signed-off-by: Alexei Starovoitov <ast@plumgrid.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2015-09-17 21:09:06 -07:00
..
2015-05-23 10:49:55 +01:00
2015-04-21 16:16:02 -04:00
2015-02-23 09:59:07 -06:00
2015-09-15 21:53:24 -07:00
2015-09-17 21:09:06 -07:00
2015-08-25 14:41:50 -05:00
2015-04-12 21:25:13 -04:00
2015-07-01 16:26:08 +02:00
2015-05-25 13:25:35 -04:00
2015-09-04 16:54:41 -07:00
2015-02-17 14:34:51 -08:00
2015-02-03 12:48:40 -05:00
2015-08-03 17:30:00 -07:00
2015-07-21 10:39:05 -07:00
2015-05-05 13:40:44 -06:00
2015-02-02 18:46:51 -08:00
2015-08-27 19:44:53 -04:00
2015-04-23 15:16:14 -04:00
2015-07-20 14:58:46 -04:00
2015-08-18 11:56:13 -06:00
2015-08-04 10:16:57 +02:00
2015-09-04 16:54:41 -07:00
2015-03-05 22:08:42 -05:00
2015-05-24 12:49:16 -07:00
2015-06-11 23:37:37 +02:00
2015-06-03 14:17:38 +02:00
2015-03-29 12:13:52 +10:30
2015-03-31 13:58:35 -04:00