)]}'
{
  "commit": "e53d9ec7ccc2dbb9378353fe2a89ebdca5cd7015",
  "tree": "c1d4f919afe118f85e16def690352e38c1e9d2b3",
  "parents": [
    "bdebcb49f459237c094a5b9cb084515cfe05e1bc"
  ],
  "author": {
    "name": "Daniel Borkmann",
    "email": "daniel@iogearbox.net",
    "time": "Fri Jul 11 11:44:16 2025 +0200"
  },
  "committer": {
    "name": "Jason Wang",
    "email": "jasowang@redhat.com",
    "time": "Tue Jul 15 10:26:55 2025 +0800"
  },
  "message": "net/af-xdp: Support pinned map path for AF_XDP sockets\n\nExtend \u0027inhibit\u003don\u0027 setting with the option to specify a pinned XSK map\npath along with a starting index (default 0) to push the created XSK\nsockets into. Example usage:\n\n  # ./build/qemu-system-x86_64 [...] \\\n   -netdev af-xdp,ifname\u003denp2s0f0np0,id\u003dnet0,mode\u003dnative,queues\u003d2,start-queue\u003d14,inhibit\u003don,map-path\u003d/sys/fs/bpf/xsks_map,map-start-index\u003d14 \\\n   -device virtio-net-pci,netdev\u003dnet0 [...]\n\nThis is useful for the case where an existing XDP program with XSK map\nis present on the AF_XDP supported phys device and the XSK map is not\nyet populated. For example, the former could have been pre-loaded onto\nthe netdevice by a control plane, which later launches QEMU to populate\nit with XSK sockets.\n\nNormally, the main idea behind \u0027inhibit\u003don\u0027 is that the QEMU instance\ndoesn\u0027t need to have a lot of privileges to use the pre-loaded program\nand the pre-created sockets, but this mentioned use-case here is different\nwhere QEMU still needs privileges to create the sockets.\n\nThe \u0027map-start-index\u0027 parameter is optional and defaults to 0. It allows\nflexible placement of the XSK sockets, and is up to the user to specify\nwhen the XDP program with XSK map was already preloaded. In the simplest\ncase the queue-to-map-slot mapping is just 1:1 based on ctx-\u003erx_queue_index\nbut the user might as well have a different scheme (or smaller map size,\ne.g. ctx-\u003erx_queue_index % max_size) to push the inbound traffic to one\nof the XSK sockets.\n\nNote that the bpf_xdp_query_id() is now only tested for \u0027inhibit\u003doff\u0027\nsince only in the latter case the libxdp takes care of installing the\nXDP program which was installed based on the s-\u003exdp_flags pointing to\neither driver or skb mode. For \u0027inhibit\u003don\u0027 we don\u0027t make any assumptions\nand neither go down the path of probing all possible options in which\nway the user installed the XDP program.\n\nReviewed-by: Ilya Maximets \u003ci.maximets@ovn.org\u003e\nSigned-off-by: Daniel Borkmann \u003cdaniel@iogearbox.net\u003e\nCc: Ilya Maximets \u003ci.maximets@ovn.org\u003e\nCc: Jason Wang \u003cjasowang@redhat.com\u003e\nCc: Anton Protopopov \u003caspsk@isovalent.com\u003e\nSigned-off-by: Jason Wang \u003cjasowang@redhat.com\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "cbe1cae700c99441851eb4a66be5e52432039e1d",
      "old_mode": 33188,
      "old_path": "net/af-xdp.c",
      "new_id": "14f302ea2150fe143963b6304d29401b0e3d5695",
      "new_mode": 33188,
      "new_path": "net/af-xdp.c"
    },
    {
      "type": "modify",
      "old_id": "0f766041a33d09946b57ba0c72ad83cb1397eada",
      "old_mode": 33188,
      "old_path": "qapi/net.json",
      "new_id": "1f40bf46bb0e55631598c60eb3b7af13f3cca7d6",
      "new_mode": 33188,
      "new_path": "qapi/net.json"
    },
    {
      "type": "modify",
      "old_id": "a3c066c67832761fe8d798f4d2ab0ccd67203506",
      "old_mode": 33188,
      "old_path": "qemu-options.hx",
      "new_id": "bf19987cb063a868b6f0a0abc091f67ce00c0862",
      "new_mode": 33188,
      "new_path": "qemu-options.hx"
    }
  ]
}
