)]}'
{
  "commit": "e80c3533c354ede56146ab0e4fbb8304d0c1209f",
  "tree": "3dec2ab9d805b27f778518e9defcd2ee4d07217e",
  "parents": [
    "1c9424a765afa20c023d42018d1f5c3d9158a9c3"
  ],
  "author": {
    "name": "Daniel Borkmann",
    "email": "daniel@iogearbox.net",
    "time": "Tue Sep 07 16:16:58 2021 +0300"
  },
  "committer": {
    "name": "Greg Kroah-Hartman",
    "email": "gregkh@linuxfoundation.org",
    "time": "Wed Sep 15 09:47:38 2021 +0200"
  },
  "message": "bpf: Introduce BPF nospec instruction for mitigating Spectre v4\n\ncommit f5e81d1117501546b7be050c5fbafa6efd2c722c upstream.\n\nIn case of JITs, each of the JIT backends compiles the BPF nospec instruction\n/either/ to a machine instruction which emits a speculation barrier /or/ to\n/no/ machine instruction in case the underlying architecture is not affected\nby Speculative Store Bypass or has different mitigations in place already.\n\nThis covers both x86 and (implicitly) arm64: In case of x86, we use \u0027lfence\u0027\ninstruction for mitigation. In case of arm64, we rely on the firmware mitigation\nas controlled via the ssbd kernel parameter. Whenever the mitigation is enabled,\nit works for all of the kernel code with no need to provide any additional\ninstructions here (hence only comment in arm64 JIT). Other archs can follow\nas needed. The BPF nospec instruction is specifically targeting Spectre v4\nsince i) we don\u0027t use a serialization barrier for the Spectre v1 case, and\nii) mitigation instructions for v1 and v4 might be different on some archs.\n\nThe BPF nospec is required for a future commit, where the BPF verifier does\nannotate intermediate BPF programs with speculation barriers.\n\nCo-developed-by: Piotr Krysiuk \u003cpiotras@gmail.com\u003e\nCo-developed-by: Benedict Schlueter \u003cbenedict.schlueter@rub.de\u003e\nSigned-off-by: Daniel Borkmann \u003cdaniel@iogearbox.net\u003e\nSigned-off-by: Piotr Krysiuk \u003cpiotras@gmail.com\u003e\nSigned-off-by: Benedict Schlueter \u003cbenedict.schlueter@rub.de\u003e\nAcked-by: Alexei Starovoitov \u003cast@kernel.org\u003e\nSigned-off-by: Sasha Levin \u003csashal@kernel.org\u003e\n[OP: - adjusted context for 5.4\n     - apply riscv changes to /arch/riscv/net/bpf_jit_comp.c]\nSigned-off-by: Ovidiu Panait \u003covidiu.panait@windriver.com\u003e\nSigned-off-by: Greg Kroah-Hartman \u003cgregkh@linuxfoundation.org\u003e\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "7216653424fd67ff078d7458678c8fd1ce352aba",
      "old_mode": 33188,
      "old_path": "arch/arm/net/bpf_jit_32.c",
      "new_id": "b51a8c7b01114ab051caf3723f428f1f12f8f056",
      "new_mode": 33188,
      "new_path": "arch/arm/net/bpf_jit_32.c"
    },
    {
      "type": "modify",
      "old_id": "945e5f690edec834af55e6311b6b2805895131df",
      "old_mode": 33188,
      "old_path": "arch/arm64/net/bpf_jit_comp.c",
      "new_id": "afc7d41347f73e40f97eaa45a8c23213ca5ec752",
      "new_mode": 33188,
      "new_path": "arch/arm64/net/bpf_jit_comp.c"
    },
    {
      "type": "modify",
      "old_id": "561154cbcc401eb8e5eee381af4873f638583fc1",
      "old_mode": 33188,
      "old_path": "arch/mips/net/ebpf_jit.c",
      "new_id": "b31b91e57c34128d363a8076290d081edbe3b3b6",
      "new_mode": 33188,
      "new_path": "arch/mips/net/ebpf_jit.c"
    },
    {
      "type": "modify",
      "old_id": "be3517ef0574d0911f6d63b530b33954c8ca343d",
      "old_mode": 33188,
      "old_path": "arch/powerpc/net/bpf_jit_comp64.c",
      "new_id": "20bfd753bcba6812788ec7d3deb1280bbfd94c11",
      "new_mode": 33188,
      "new_path": "arch/powerpc/net/bpf_jit_comp64.c"
    },
    {
      "type": "modify",
      "old_id": "e2279fed8f5641ef4834a9f90d4be0bd4f1e5e4f",
      "old_mode": 33188,
      "old_path": "arch/riscv/net/bpf_jit_comp.c",
      "new_id": "0eefe6193253ba5c6aef9dcb94eadc077e66f4d4",
      "new_mode": 33188,
      "new_path": "arch/riscv/net/bpf_jit_comp.c"
    },
    {
      "type": "modify",
      "old_id": "e160f4650f8e4ed83df7fa597fa9974cb015dc00",
      "old_mode": 33188,
      "old_path": "arch/s390/net/bpf_jit_comp.c",
      "new_id": "3e6612d8b921c32cec9fa1a7f854f21a394be295",
      "new_mode": 33188,
      "new_path": "arch/s390/net/bpf_jit_comp.c"
    },
    {
      "type": "modify",
      "old_id": "3364e2a009899c39860e902627b62ee2d07ad2b9",
      "old_mode": 33188,
      "old_path": "arch/sparc/net/bpf_jit_comp_64.c",
      "new_id": "fef734473c0f38f3bac21e61900880f1a34de5ef",
      "new_mode": 33188,
      "new_path": "arch/sparc/net/bpf_jit_comp_64.c"
    },
    {
      "type": "modify",
      "old_id": "6e884f17634fea73c77edb5eb2d99c55fdd0a7e2",
      "old_mode": 33188,
      "old_path": "arch/x86/net/bpf_jit_comp.c",
      "new_id": "55f62dca28aa2b4d1b74b588f73b83038de24581",
      "new_mode": 33188,
      "new_path": "arch/x86/net/bpf_jit_comp.c"
    },
    {
      "type": "modify",
      "old_id": "0fcba32077c87705accd544d511395dca8eeae58",
      "old_mode": 33188,
      "old_path": "arch/x86/net/bpf_jit_comp32.c",
      "new_id": "2914f900034e052c3791d6a8d6e7d23cd3e52298",
      "new_mode": 33188,
      "new_path": "arch/x86/net/bpf_jit_comp32.c"
    },
    {
      "type": "modify",
      "old_id": "c53e2fe3c8f7fe0e845e1d7f5bc70b54096be0c1",
      "old_mode": 33188,
      "old_path": "include/linux/filter.h",
      "new_id": "c4f89340f49867ec21f52993c467cc871ee2bf78",
      "new_mode": 33188,
      "new_path": "include/linux/filter.h"
    },
    {
      "type": "modify",
      "old_id": "323913ba13b38b6626b168e1226b8817b3ac567c",
      "old_mode": 33188,
      "old_path": "kernel/bpf/core.c",
      "new_id": "d9a3d995bd96639b76a49cc6cc2a09b51b01ef65",
      "new_mode": 33188,
      "new_path": "kernel/bpf/core.c"
    },
    {
      "type": "modify",
      "old_id": "b44d8c447afd1d699b27e152e5bf06a24dff80f0",
      "old_mode": 33188,
      "old_path": "kernel/bpf/disasm.c",
      "new_id": "ff1dd7d45b58ab00d0f3ea5b317ed3b9bd6e6e8f",
      "new_mode": 33188,
      "new_path": "kernel/bpf/disasm.c"
    }
  ]
}
