fragments: &fragments
  - &frag-lkft-base https://gitlab.com/Linaro/lkft/kernel-fragments/-/raw/main/lkft.config
  - &frag-lkft-crypto https://gitlab.com/Linaro/lkft/kernel-fragments/-/raw/main/lkft-crypto.config
  - &frag-lkft-distro https://gitlab.com/Linaro/lkft/kernel-fragments/-/raw/main/distro-overrides.config
  - &frag-lkft-netdev https://gitlab.com/Linaro/lkft/kernel-fragments/-/raw/main/netdev.config
  - &frag-lkft-systemd https://gitlab.com/Linaro/lkft/kernel-fragments/-/raw/main/systemd.config
  - &frag-lkft-virtio https://gitlab.com/Linaro/lkft/kernel-fragments/-/raw/main/virtio.config
  - &frag-lkft-xfstests https://gitlab.com/Linaro/lkft/kernel-fragments/-/raw/add-xfstests/xfstests.config

lava-job-priority: &lava-job-priority 77
lava-job-priority-sanity: &lava-job-priority-sanity 80

run-xfstests: &run-xfstests "https://people.linaro.org/~anders.roxell/run-xfstests.sh"

# debian rootfs
rootfs-debian-testing-arm: &rootfs-debian-testing-arm https://storage.tuxboot.com/debian/bookworm/armhf/rootfs.ext4.xz
rootfs-debian-testing-arm-tar: &rootfs-debian-testing-arm-tar https://storage.tuxboot.com/debian/bookworm/armhf/rootfs.tar.xz
rootfs-debian-testing-arm64: &rootfs-debian-testing-arm64 https://storage.tuxboot.com/debian/bookworm/arm64/rootfs.ext4.xz
rootfs-debian-testing-arm64-tar: &rootfs-debian-testing-arm64-tar https://storage.tuxboot.com/debian/bookworm/arm64/rootfs.tar.xz
rootfs-debian-testing-i386: &rootfs-debian-testing-i386 https://storage.tuxboot.com/debian/bookworm/i386/rootfs.ext4.xz
rootfs-debian-testing-i386-tar: &rootfs-debian-testing-i386-tar https://storage.tuxboot.com/debian/bookworm/i386/rootfs.tar.xz
rootfs-debian-testing-x86_64: &rootfs-debian-testing-x86_64 https://storage.tuxboot.com/debian/bookworm/amd64/rootfs.ext4.xz
rootfs-debian-testing-x86_64-tar: &rootfs-debian-testing-x86_64-tar https://storage.tuxboot.com/debian/bookworm/amd64/rootfs.tar.xz

# debian-kvm rootfs
rootfs-debian-kvm-testing-arm: &rootfs-debian-kvm-testing-arm https://storage.tuxboot.com/debian-kvm/bookworm/armhf/rootfs.ext4.xz
rootfs-debian-kvm-testing-arm64: &rootfs-debian-kvm-testing-arm64 https://storage.tuxboot.com/debian-kvm/bookworm/arm64/rootfs.ext4.xz
rootfs-debian-kvm-testing-arm64-tar: &rootfs-debian-kvm-testing-arm64-tar https://storage.tuxboot.com/debian-kvm/bookworm/arm64/rootfs.tar.xz
rootfs-debian-kvm-testing-i386: &rootfs-debian-kvm-testing-i386 https://storage.tuxboot.com/debian-kvm/bookworm/i386/rootfs.ext4.xz
rootfs-debian-kvm-testing-x86_64: &rootfs-debian-kvm-testing-x86_64 https://storage.tuxboot.com/debian-kvm/bookworm/amd64/rootfs.ext4.xz

# debian-xfstests rootfs
rootfs-debian-xfstests-testing-arm64: &rootfs-debian-xfstests-testing-arm64 https://storage.tuxboot.com/debian-xfstests/bookworm/arm64/rootfs.ext4.xz
rootfs-debian-xfstests-testing-arm64-tar: &rootfs-debian-xfstests-testing-arm64-tar https://storage.tuxboot.com/debian-xfstests/bookworm/arm64/rootfs.tar.xz

xfstests-debian-bookworm-arm64: &xfstests-debian-bookworm-arm64 https://storage.dev.tuxboot.com/overlays/debian/bookworm/arm64/xfstests/master/xfstests.tar.xz

kvm-unit-tests-debian-bookworm-arm: &kvm-unit-tests-debian-bookworm-arm https://storage.tuxboot.com/overlays/debian/bookworm/armhf/kvm-unit-tests/master/kvm-unit-tests.tar.xz
kvm-unit-tests-debian-bookworm-arm64: &kvm-unit-tests-debian-bookworm-arm64 https://storage.dev.tuxboot.com/overlays/debian/bookworm/arm64/kvm-unit-tests/master/kvm-unit-tests.tar.xz
kvm-unit-tests-debian-bookworm-i386: &kvm-unit-tests-debian-bookworm-i386 https://storage.tuxboot.com/overlays/debian/bookworm/i386/kvm-unit-tests/master/kvm-unit-tests.tar.xz
kvm-unit-tests-debian-bookworm-x86_64: &kvm-unit-tests-debian-bookworm-x86_64 https://storage.tuxboot.com/overlays/debian/bookworm/amd64/kvm-unit-tests/master/kvm-unit-tests.tar.xz

libgpiod-debian-bookworm-arm: &libgpiod-debian-bookworm-arm https://storage.tuxboot.com/overlays/debian/bookworm/armhf/libgpiod/v2.0.1/libgpiod.tar.xz
libgpiod-debian-bookworm-arm64: &libgpiod-debian-bookworm-arm64 https://storage.dev.tuxboot.com/overlays/debian/bookworm/arm64/libgpiod/v2.0.1/libgpiod.tar.xz
libgpiod-debian-bookworm-i386: &libgpiod-debian-bookworm-i386 https://storage.tuxboot.com/overlays/debian/bookworm/i386/libgpiod/v2.0.1/libgpiod.tar.xz
libgpiod-debian-bookworm-x86_64: &libgpiod-debian-bookworm-x86_64 https://storage.tuxboot.com/overlays/debian/bookworm/amd64/libgpiod/v2.0.1/libgpiod.tar.xz

ltp-debian-bookworm-arm: &ltp-debian-bookworm-arm https://storage.tuxboot.com/overlays/debian/bookworm/armhf/ltp/20240129/ltp.tar.xz
ltp-debian-bookworm-arm64: &ltp-debian-bookworm-arm64 https://storage.tuxboot.com/overlays/debian/bookworm/arm64/ltp/20240129/ltp.tar.xz
ltp-debian-bookworm-i386: &ltp-debian-bookworm-i386 https://storage.tuxboot.com/overlays/debian/bookworm/i386/ltp/20240129/ltp.tar.xz
ltp-debian-bookworm-x86_64: &ltp-debian-bookworm-x86_64 https://storage.tuxboot.com/overlays/debian/bookworm/amd64/ltp/20240129/ltp.tar.xz

boot-timeout-arm: &boot-timeout-arm 30
boot-timeout-arm64: &boot-timeout-arm64 30
boot-timeout-fvp: &boot-timeout-fvp 60
boot-timeout-i386: &boot-timeout-i386 15
boot-timeout-x86: &boot-timeout-x86 15

kselftest-timeout: &kselftest-timeout 20
kselftest-arm64-timeout: &kselftest-arm64-timeout 60
kselftest-ftrace-timeout: &kselftest-ftrace-timeout 40
kselftest-memfd-timeout: &kselftest-memfd-timeout 30
kselftest-net-timeout: &kselftest-net-timeout 30

kvm-unit-tests-timeout: &kvm-unit-tests-timeout 60
kvm-unit-tests-timeout-fvp: &kvm-unit-tests-timeout-fvp 160

ltp-commands-timeout: &ltp-commands-timeout 40
ltp-containers-timeout: &ltp-containers-timeout 25
ltp-controllers-timeout: &ltp-controllers-timeout 80
ltp-crypto-timeout: &ltp-crypto-timeout 30
ltp-cve-timeout: &ltp-cve-timeout 50
ltp-fs_bind-timeout: &ltp-fs_bind-timeout 40
ltp-fs-timeout: &ltp-fs-timeout 40
ltp-fs_perms_simple-timeout: &ltp-fs_perms_simple-timeout 10
ltp-hugetlb-timeout: &ltp-hugetlb-timeout 20
ltp-math-timeout: &ltp-math-timeout 50
ltp-mm-timeout: &ltp-mm-timeout 40
ltp-pty-timeout: &ltp-pty-timeout 10
ltp-sched-timeout: &ltp-sched-timeout 30
ltp-syscalls-timeout: &ltp-syscalls-timeout 50
ltp-tracing-timeout: &ltp-tracing-timeout 30
ltp-smoke-timeout: &ltp-smoke-timeout 15

perf-timeout: &perf-timeout 60

version: 1
name: full kernel validation for the linux-xfstests
description: Build and test linux kernel with every toolchain
jobs:
  #- name: arm64-xfstests-ext2
  #  builds:
  #    - build_name: gcc-13-xfstests-ext2
  #      target_arch: arm64
  #      toolchain: gcc-13
  #      kconfig: [ defconfig, *frag-lkft-systemd, *frag-lkft-xfstests, CONFIG_EXT2_FS=y, CONFIG_EXT2_FS_XATTR=y, CONFIG_EXT2_FS_POSIX_ACL=y ]
  #  sanity_test:
  #      device: qemu-arm64
  #      boot_args: rw
  #      parameters: {SKIPFILE: "skipfile-lkft.yaml"}
  #      rootfs: *rootfs-debian-testing-arm64
  #      overlay: [ *ltp-debian-bookworm-arm64 ]
  #      tests: [ltp-smoke]
  #      timeouts: { "boot": *boot-timeout-arm64, "ltp-smoke": *ltp-smoke-timeout }
  #  tests:
  #    - device: qemu-arm64
  #      boot_args: rw
  #      parameters: {SKIPFILE: "skipfile-lkft.yaml"}
  #      rootfs: *rootfs-debian-xfstests-testing-arm64
  #      overlay: [ *xfstests-debian-bookworm-arm64, *run-xfstests ]
  #      command_name: xfstests-ext2
  #      commands: [ "bash /run-xfstests.sh ext2" ]
  #      timeouts: { "boot": *boot-timeout-arm64, "commands": 120 }
  #- name: arm64-xfstests-ext3
  #  builds:
  #    - build_name: gcc-13-xfstests-ext3
  #      target_arch: arm64
  #      toolchain: gcc-13
  #      kconfig: [ defconfig, *frag-lkft-systemd, *frag-lkft-xfstests, CONFIG_EXT3_FS=y, CONFIG_EXT4_FS_POSIX_ACL=y ]
  #  sanity_test:
  #      device: qemu-arm64
  #      boot_args: rw
  #      parameters: {SKIPFILE: "skipfile-lkft.yaml"}
  #      rootfs: *rootfs-debian-testing-arm64
  #      overlay: [ *ltp-debian-bookworm-arm64 ]
  #      tests: [ltp-smoke]
  #      timeouts: { "boot": *boot-timeout-arm64, "ltp-smoke": *ltp-smoke-timeout }
  #  tests:
  #    - device: qemu-arm64
  #      boot_args: rw
  #      parameters: {SKIPFILE: "skipfile-lkft.yaml"}
  #      rootfs: *rootfs-debian-xfstests-testing-arm64
  #      overlay: [ *xfstests-debian-bookworm-arm64, *run-xfstests ]
  #      command_name: xfstests-ext3
  #      commands: [ "bash /run-xfstests.sh ext3" ]
  #      timeouts: { "boot": *boot-timeout-arm64, "commands": 120 }
- name: arm64-xfstests-ext4
  builds:
    - build_name: gcc-13-xfstests-ext4
      target_arch: arm64
      toolchain: gcc-13
      kconfig: [ defconfig, *frag-lkft-systemd, *frag-lkft-xfstests, CONFIG_EXT4_FS=y, CONFIG_EXT4_FS_POSIX_ACL=y, CONFIG_EXT4_DEBUG=y, CONFIG_QUOTA=y ]
  sanity_test:
      device: qemu-arm64
      boot_args: rw
      parameters: {SKIPFILE: "skipfile-lkft.yaml"}
      rootfs: *rootfs-debian-testing-arm64
      overlay: [ *ltp-debian-bookworm-arm64 ]
      tests: [ltp-smoke]
      timeouts: { "boot": *boot-timeout-arm64, "ltp-smoke": *ltp-smoke-timeout }
  tests:
    - device: qemu-arm64
      boot_args: rw
      parameters: {SKIPFILE: "skipfile-lkft.yaml"}
      rootfs: *rootfs-debian-xfstests-testing-arm64
      overlay: [ *xfstests-debian-bookworm-arm64, *run-xfstests ]
      command_name: xfstests-ext4
      commands: [ "bash /run-xfstests.sh ext4" ]
      timeouts: { "boot": *boot-timeout-arm64, "commands": 120 }
        #- name: arm64-xfstests-btrfs
        #  builds:
        #    - build_name: gcc-13-xfstests-btrfs
        #      target_arch: arm64
        #      toolchain: gcc-13
        #      kconfig: [ defconfig, *frag-lkft-systemd, *frag-lkft-xfstests, CONFIG_BTRFS_FS=y, CONFIG_BTRFS_FS_POSIX_ACL=y, CONFIG_BTRFS_FS_CHECK_INTEGRITY=y, CONFIG_BTRFS_FS_RUN_SANITY_TESTS=y, CONFIG_BTRFS_DEBUG=y, CONFIG_BTRFS_ASSERT=y, CONFIG_BTRFS_FS_REF_VERIFY=y ]
        #  sanity_test:
        #      device: qemu-arm64
        #      boot_args: rw
        #      parameters: {SKIPFILE: "skipfile-lkft.yaml"}
        #      rootfs: *rootfs-debian-testing-arm64
        #      overlay: [ *ltp-debian-bookworm-arm64 ]
        #      tests: [ltp-smoke]
        #      timeouts: { "boot": *boot-timeout-arm64, "ltp-smoke": *ltp-smoke-timeout }
        #  tests:
        #    - device: qemu-arm64
        #      boot_args: rw
        #      parameters: {SKIPFILE: "skipfile-lkft.yaml"}
        #      rootfs: *rootfs-debian-xfstests-testing-arm64
        #      overlay: [ *xfstests-debian-bookworm-arm64, *run-xfstests ]
        #      command_name: xfstests-btrfs
        #      commands: [ "bash /run-xfstests.sh btrfs" ]
        #      timeouts: { "boot": *boot-timeout-arm64, "commands": 120 }
        #- name: arm64-xfstests-jfs
        #  builds:
        #    - build_name: gcc-13-xfstests-jfs
        #      target_arch: arm64
        #      toolchain: gcc-13
        #      kconfig: [ defconfig, *frag-lkft-systemd, *frag-lkft-xfstests, CONFIG_JFS_FS=y, CONFIG_JFS_POSIX_ACL=y, CONFIG_JFS_DEBUG=y, CONFIG_QUOTA=y ]
        #  sanity_test:
        #      device: qemu-arm64
        #      boot_args: rw
        #      parameters: {SKIPFILE: "skipfile-lkft.yaml"}
        #      rootfs: *rootfs-debian-testing-arm64
        #      overlay: [ *ltp-debian-bookworm-arm64 ]
        #      tests: [ltp-smoke]
        #      timeouts: { "boot": *boot-timeout-arm64, "ltp-smoke": *ltp-smoke-timeout }
        #  tests:
        #    - device: qemu-arm64
        #      boot_args: rw
        #      parameters: {SKIPFILE: "skipfile-lkft.yaml"}
        #      rootfs: *rootfs-debian-xfstests-testing-arm64
        #      overlay: [ *xfstests-debian-bookworm-arm64, *run-xfstests ]
        #      command_name: xfstests-jfs
        #      commands: [ "bash /run-xfstests.sh jfs" ]
        #      timeouts: { "boot": *boot-timeout-arm64, "commands": 120 }
        #- name: arm64-xfstests-f2fs
        #  builds:
        #    - build_name: gcc-13-xfstests-f2fs
        #      target_arch: arm64
        #      toolchain: gcc-13
        #      kconfig: [ defconfig, *frag-lkft-systemd, *frag-lkft-xfstests, CONFIG_F2FS_FS=y, CONFIG_F2FS_STAT_FS=y, CONFIG_F2FS_FS_XATTR=y, CONFIG_F2FS_FS_POSIX_ACL=y, CONFIG_F2FS_CHECK_FS=y, CONFIG_F2FS_FAULT_INJECTION=y ]
        #  sanity_test:
        #      device: qemu-arm64
        #      boot_args: rw
        #      parameters: {SKIPFILE: "skipfile-lkft.yaml"}
        #      rootfs: *rootfs-debian-testing-arm64
        #      overlay: [ *ltp-debian-bookworm-arm64 ]
        #      tests: [ltp-smoke]
        #      timeouts: { "boot": *boot-timeout-arm64, "ltp-smoke": *ltp-smoke-timeout }
        #  tests:
        #    - device: qemu-arm64
        #      boot_args: rw
        #      parameters: {SKIPFILE: "skipfile-lkft.yaml"}
        #      rootfs: *rootfs-debian-xfstests-testing-arm64
        #      overlay: [ *xfstests-debian-bookworm-arm64, *run-xfstests ]
        #      command_name: xfstests-f2fs
        #      commands: [ "bash /run-xfstests.sh f2fs" ]
        #      timeouts: { "boot": *boot-timeout-arm64, "commands": 120 }
        #- name: arm64-xfstests-minixfs
        #  builds:
        #    - build_name: gcc-13-xfstests-minixfs
        #      target_arch: arm64
        #      toolchain: gcc-13
        #      kconfig: [ defconfig, *frag-lkft-systemd, *frag-lkft-xfstests, CONFIG_EXT4_FS=y, CONFIG_EXT4_FS_POSIX_ACL=y, CONFIG_EXT4_DEBUG=y, CONFIG_QUOTA=y ]
        #  sanity_test:
        #      device: qemu-arm64
        #      boot_args: rw
        #      parameters: {SKIPFILE: "skipfile-lkft.yaml"}
        #      rootfs: *rootfs-debian-testing-arm64
        #      overlay: [ *ltp-debian-bookworm-arm64 ]
        #      tests: [ltp-smoke]
        #      timeouts: { "boot": *boot-timeout-arm64, "ltp-smoke": *ltp-smoke-timeout }
        #  tests:
        #    - device: qemu-arm64
        #      boot_args: rw
        #      parameters: {SKIPFILE: "skipfile-lkft.yaml"}
        #      rootfs: *rootfs-debian-xfstests-testing-arm64
        #      overlay: [ *xfstests-debian-bookworm-arm64, *run-xfstests ]
        #      command_name: xfstests-minixfs
        #      commands: [ "bash /run-xfstests.sh minixfs" ]
        #      timeouts: { "boot": *boot-timeout-arm64, "commands": 120 }
        #- name: arm64-xfstests-nilfs2
        #  builds:
        #    - build_name: gcc-13-xfstests-nilfs2
        #      target_arch: arm64
        #      toolchain: gcc-13
        #      kconfig: [ defconfig, *frag-lkft-systemd, *frag-lkft-xfstests, CONFIG_NILFS2_FS=y ]
        #  sanity_test:
        #      device: qemu-arm64
        #      boot_args: rw
        #      parameters: {SKIPFILE: "skipfile-lkft.yaml"}
        #      rootfs: *rootfs-debian-testing-arm64
        #      overlay: [ *ltp-debian-bookworm-arm64 ]
        #      tests: [ltp-smoke]
        #      timeouts: { "boot": *boot-timeout-arm64, "ltp-smoke": *ltp-smoke-timeout }
        #  tests:
        #    - device: qemu-arm64
        #      boot_args: rw
        #      parameters: {SKIPFILE: "skipfile-lkft.yaml"}
        #      rootfs: *rootfs-debian-xfstests-testing-arm64
        #      overlay: [ *xfstests-debian-bookworm-arm64, *run-xfstests ]
        #      command_name: xfstests-nilfs2
        #      commands: [ "bash /run-xfstests.sh nilfs2" ]
        #      timeouts: { "boot": *boot-timeout-arm64, "commands": 120 }
        #- name: arm64-xfstests-xfs
        #  builds:
        #    - build_name: gcc-13-xfstests-xfs
        #      target_arch: arm64
        #      toolchain: gcc-13
        #      kconfig: [ defconfig, *frag-lkft-systemd, *frag-lkft-xfstests ]
        #  sanity_test:
        #      device: qemu-arm64
        #      boot_args: rw
        #      parameters: {SKIPFILE: "skipfile-lkft.yaml"}
        #      rootfs: *rootfs-debian-testing-arm64
        #      overlay: [ *ltp-debian-bookworm-arm64 ]
        #      tests: [ltp-smoke]
        #      timeouts: { "boot": *boot-timeout-arm64, "ltp-smoke": *ltp-smoke-timeout }
        #  tests:
        #    - device: qemu-arm64
        #      boot_args: rw
        #      parameters: {SKIPFILE: "skipfile-lkft.yaml"}
        #      rootfs: *rootfs-debian-xfstests-testing-arm64
        #      overlay: [ *xfstests-debian-bookworm-arm64, *run-xfstests ]
        #      command_name: xfstests-xfs
        #      commands: [ "bash /run-xfstests.sh xfs" ]
        #      timeouts: { "boot": *boot-timeout-arm64, "commands": 120 }
