)]}'
{
  "commit": "8d0c4697534a739725e429ff062dea393d8860d1",
  "tree": "ee28163a6c53e0131fd2d3d626d02b0610eaed2b",
  "parents": [
    "f51a5e82ea9aaf05106c00d976e772ca384a9199",
    "fbe3310840c65f3cf97dd90d23e177d061c376f2"
  ],
  "author": {
    "name": "David S. Miller",
    "email": "davem@davemloft.net",
    "time": "Fri Dec 05 21:47:48 2014 -0800"
  },
  "committer": {
    "name": "David S. Miller",
    "email": "davem@davemloft.net",
    "time": "Fri Dec 05 21:47:48 2014 -0800"
  },
  "message": "Merge branch \u0027ebpf-next\u0027\n\nAlexei Starovoitov says:\n\n\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\nallow eBPF programs to be attached to sockets\n\nV1-\u003eV2:\n\nfixed comments in sample code to state clearly that packet data is accessed\nwith LD_ABS instructions and not internal skb fields.\nAlso replaced constants in:\nBPF_LD_ABS(BPF_B, 14 + 9 /* R0 \u003d ip-\u003eproto */),\nwith:\nBPF_LD_ABS(BPF_B, ETH_HLEN + offsetof(struct iphdr, protocol) /* R0 \u003d ip-\u003eproto */),\n\nV1 cover:\n\nIntroduce BPF_PROG_TYPE_SOCKET_FILTER type of eBPF programs that can be\nattached to sockets with setsockopt().\nAllow such programs to access maps via lookup/update/delete helpers.\n\nThis feature was previewed by bpf manpage in commit b4fc1a460f30(\"Merge branch \u0027bpf-next\u0027\")\nNow it can actually run.\n\n1st patch adds LD_ABS/LD_IND instruction verification and\n2nd patch adds new setsockopt() flag.\nPatches 3-6 are examples in assembler and in C.\n\nThough native eBPF programs are way more powerful than classic filters\n(attachable through similar setsockopt() call), they don\u0027t have skb field\naccessors yet. Like skb-\u003epkt_type, skb-\u003edev-\u003eifindex are not accessible.\nThere are sevaral ways to achieve that. That will be in the next set of patches.\nSo in this set native eBPF programs can only read data from packet and\naccess maps.\n\nThe most powerful example is sockex2_kern.c from patch 6 where ~200 lines of C\nare compiled into ~300 of eBPF instructions.\nIt shows how quite complex packet parsing can be done.\n\nLLVM used to build examples is at https://github.com/iovisor/llvm\nwhich is fork of llvm trunk that I\u0027m cleaning up for upstreaming.\n\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\n\nSigned-off-by: David S. Miller \u003cdavem@davemloft.net\u003e\n",
  "tree_diff": []
}
