From ad4d4e5cbad3ad875eaa59e0a919c014dfb6a39e Mon Sep 17 00:00:00 2001 From: Adrian Calianu Date: Wed, 27 Sep 2017 10:37:36 +0200 Subject: add guest features from yocto branch Signed-off-by: Adrian Calianu --- 6lowpan/6lowpan_n.cfg | 1 + 6lowpan/6lowpan_n.scc | 5 + a.sh | 96 +++++++++ bcma/bcma_n.cfg | 9 + bcma/bcma_n.scc | 4 + btrfs/btrfs_n.cfg | 8 + btrfs/btrfs_n.scc | 4 + compilechecks/compilechecks_n.cfg | 6 + compilechecks/compilechecks_n.scc | 4 + cpu_freq/cpu_freq_n.cfg | 1 + cpu_freq/cpu_freq_n.scc | 5 + dmiid/dmiid_n.cfg | 1 + dmiid/dmiid_n.scc | 5 + features/netdevices/netdevices_n.cfg | 5 + features/powermanagement/powermanagement_n.cfg | 1 + hwmon/hwmon_n.cfg | 1 + hwmon/hwmon_n.scc | 5 + i2csupport/i2csupport_n.cfg | 80 ++++++++ i2csupport/i2csupport_n.scc | 4 + intel-e1xxxx/e100_n.cfg | 1 + intel-e1xxxx/e100_n.scc | 5 + intel-e1xxxx/e1xxxx_m.cfg | 3 + intel-e1xxxx/e1xxxx_m.scc | 5 + intel-e1xxxx/e1xxxx_n.cfg | 3 + intel-e1xxxx/e1xxxx_n.scc | 5 + isdn/isdn_n.cfg | 4 + isdn/isdn_n.scc | 4 + ixgbevf/ixgbevf_y.cfg | 1 + ixgbevf/ixgbevf_y.scc | 4 + kvm/guest_kvm_y.cfg | 12 ++ kvm/guest_kvm_y.scc | 4 + kvm/guest_n.cfg | 4 + kvm/guest_n.scc | 5 + kvm/host_n.cfg | 2 + kvm/host_n.scc | 5 + kvm/qemu-kvm_m.cfg | 30 +++ kvm/qemu-kvm_m.scc | 4 + kvm/virtFS_y.cfg | 4 + kvm/virtFS_y.scc | 4 + kvm/virtio_balloon_y.cfg | 2 + kvm/virtio_balloon_y.scc | 4 + kvm/virtio_caif_y.cfg | 5 + kvm/virtio_caif_y.scc | 4 + kvm/virtio_input_y.cfg | 2 + kvm/virtio_input_y.scc | 4 + kvm/virtio_pci_legacy_y.cfg | 3 + kvm/virtio_pci_legacy_y.scc | 4 + kvm/virtio_y.cfg | 28 +++ kvm/virtio_y.scc | 4 + loopdev/loopdev_n.cfg | 2 + loopdev/loopdev_n.scc | 4 + msdos_fat_nt_fs/msdos_fat_nt_fs_n.cfg | 12 ++ msdos_fat_nt_fs/msdos_fat_nt_fs_n.scc | 4 + netblkdev/netblkdev_n.cfg | 1 + netblkdev/netblkdev_n.scc | 4 + netconsole/netconsole_n.cfg | 3 + netconsole/netconsole_n.scc | 4 + netfilter/netfilter_n.cfg | 222 +++++++++++++++++++++ netfilter/netfilter_n.scc | 4 + netfilter/netfilter_y.cfg | 10 + netfilter/netfilter_y.scc | 4 + nfs/nfs_n.cfg | 44 ++++ nfs/nfs_n.scc | 4 + parport/parport_n.cfg | 8 + parport/parport_n.scc | 4 + ...kip-synchronize_rcu-on-single-CPU-systems.patch | 34 ++++ ...kip-synchronize_rcu-if-there-is-no-old-op.patch | 38 ++++ .../0104-fbcon-enable-no-blink-by-default.patch | 26 +++ .../boot_time_opt_guest/0105-vmstats-wakeups.patch | 28 +++ patches/boot_time_opt_guest/0106-pci-probe.patch | 123 ++++++++++++ patches/boot_time_opt_guest/0107-cgroup.patch | 107 ++++++++++ .../0108-smpboot-reuse-timer-calibration.patch | 45 +++++ patches/boot_time_opt_guest/0109-perf.patch | 28 +++ .../0110-pci-probe-identify-known-devices.patch | 190 ++++++++++++++++++ .../0111-init-no-wait-for-the-known-devices.patch | 39 ++++ patches/boot_time_opt_guest/0112-ksm-wakeups.patch | 32 +++ .../0113-init-do_mounts-recreate-dev-root.patch | 42 ++++ ...-setting-user.-attributes-on-symlinks-by-.patch | 56 ++++++ .../0151-mm-Export-do_madvise.patch | 84 ++++++++ ...0152-x86-kvm-Notify-host-to-release-pages.patch | 180 +++++++++++++++++ ...6-Return-memory-from-guest-to-host-kernel.patch | 155 ++++++++++++++ ...54-sysctl-vm-Fine-grained-cache-shrinking.patch | 137 +++++++++++++ .../boot_time_opt_guest/guest_boot_time_opt.scc | 19 ++ pci/pci_iov_m.cfg | 1 + pci/pci_iov_m.scc | 4 + pci/pci_iov_y.cfg | 1 + pci/pci_iov_y.scc | 4 + pcimodules/pcimodules_n.cfg | 19 ++ pcimodules/pcimodules_n.scc | 4 + perf/perf_n.cfg | 2 + perf/perf_n.scc | 4 + power_supply/power_supply_n.cfg | 1 + power_supply/power_supply_n.scc | 5 + ppp/ppp_n.cfg | 10 + ppp/ppp_n.scc | 4 + prockcore/prockcore_n.cfg | 1 + prockcore/prockcore_n.scc | 4 + .../reduced_kernel_footprint_guest.scc | 75 +++++++ serio/serio_n.cfg | 15 ++ serio/serio_n.scc | 4 + slip/slip_n.cfg | 5 + slip/slip_n.scc | 4 + thermal/thermal_n.cfg | 4 + thermal/thermal_n.scc | 5 + udev/udev.cfg | 28 +++ udev/udev.scc | 7 + udev/udev_crypto.cfg | 3 + udev/udev_crypto.scc | 4 + udev/udev_n.cfg | 1 + udev/udev_n.scc | 5 + udev/udev_opt.cfg | 10 + udev/udev_opt.scc | 4 + udev/udev_uefi.cfg | 2 + udev/udev_uefi.scc | 4 + vga/vga_n.cfg | 1 + vga/vga_n.scc | 5 + watchdog/watchdog_n.cfg | 1 + watchdog/watchdog_n.scc | 5 + x86_platform/x86_platform_n.cfg | 1 + x86_platform/x86_platform_n.scc | 5 + 120 files changed, 2373 insertions(+) create mode 100644 6lowpan/6lowpan_n.cfg create mode 100644 6lowpan/6lowpan_n.scc create mode 100644 a.sh create mode 100644 bcma/bcma_n.cfg create mode 100644 bcma/bcma_n.scc create mode 100644 btrfs/btrfs_n.cfg create mode 100644 btrfs/btrfs_n.scc create mode 100644 compilechecks/compilechecks_n.cfg create mode 100644 compilechecks/compilechecks_n.scc create mode 100644 cpu_freq/cpu_freq_n.cfg create mode 100644 cpu_freq/cpu_freq_n.scc create mode 100644 dmiid/dmiid_n.cfg create mode 100644 dmiid/dmiid_n.scc create mode 100644 hwmon/hwmon_n.cfg create mode 100644 hwmon/hwmon_n.scc create mode 100644 i2csupport/i2csupport_n.cfg create mode 100644 i2csupport/i2csupport_n.scc create mode 100644 intel-e1xxxx/e100_n.cfg create mode 100644 intel-e1xxxx/e100_n.scc create mode 100644 intel-e1xxxx/e1xxxx_m.cfg create mode 100644 intel-e1xxxx/e1xxxx_m.scc create mode 100644 intel-e1xxxx/e1xxxx_n.cfg create mode 100644 intel-e1xxxx/e1xxxx_n.scc create mode 100644 isdn/isdn_n.cfg create mode 100644 isdn/isdn_n.scc create mode 100644 ixgbevf/ixgbevf_y.cfg create mode 100644 ixgbevf/ixgbevf_y.scc create mode 100644 kvm/guest_kvm_y.cfg create mode 100644 kvm/guest_kvm_y.scc create mode 100644 kvm/guest_n.cfg create mode 100644 kvm/guest_n.scc create mode 100644 kvm/host_n.cfg create mode 100644 kvm/host_n.scc create mode 100644 kvm/qemu-kvm_m.cfg create mode 100644 kvm/qemu-kvm_m.scc create mode 100644 kvm/virtFS_y.cfg create mode 100644 kvm/virtFS_y.scc create mode 100644 kvm/virtio_balloon_y.cfg create mode 100644 kvm/virtio_balloon_y.scc create mode 100644 kvm/virtio_caif_y.cfg create mode 100644 kvm/virtio_caif_y.scc create mode 100644 kvm/virtio_input_y.cfg create mode 100644 kvm/virtio_input_y.scc create mode 100644 kvm/virtio_pci_legacy_y.cfg create mode 100644 kvm/virtio_pci_legacy_y.scc create mode 100644 kvm/virtio_y.cfg create mode 100644 kvm/virtio_y.scc create mode 100644 loopdev/loopdev_n.cfg create mode 100644 loopdev/loopdev_n.scc create mode 100644 msdos_fat_nt_fs/msdos_fat_nt_fs_n.cfg create mode 100644 msdos_fat_nt_fs/msdos_fat_nt_fs_n.scc create mode 100644 netblkdev/netblkdev_n.cfg create mode 100644 netblkdev/netblkdev_n.scc create mode 100644 netconsole/netconsole_n.cfg create mode 100644 netconsole/netconsole_n.scc create mode 100644 netfilter/netfilter_n.cfg create mode 100644 netfilter/netfilter_n.scc create mode 100644 netfilter/netfilter_y.cfg create mode 100644 netfilter/netfilter_y.scc create mode 100644 nfs/nfs_n.cfg create mode 100644 nfs/nfs_n.scc create mode 100644 parport/parport_n.cfg create mode 100644 parport/parport_n.scc create mode 100644 patches/boot_time_opt_guest/0102-cpuidle-skip-synchronize_rcu-on-single-CPU-systems.patch create mode 100644 patches/boot_time_opt_guest/0103-sysrq-skip-synchronize_rcu-if-there-is-no-old-op.patch create mode 100644 patches/boot_time_opt_guest/0104-fbcon-enable-no-blink-by-default.patch create mode 100644 patches/boot_time_opt_guest/0105-vmstats-wakeups.patch create mode 100644 patches/boot_time_opt_guest/0106-pci-probe.patch create mode 100644 patches/boot_time_opt_guest/0107-cgroup.patch create mode 100644 patches/boot_time_opt_guest/0108-smpboot-reuse-timer-calibration.patch create mode 100644 patches/boot_time_opt_guest/0109-perf.patch create mode 100644 patches/boot_time_opt_guest/0110-pci-probe-identify-known-devices.patch create mode 100644 patches/boot_time_opt_guest/0111-init-no-wait-for-the-known-devices.patch create mode 100644 patches/boot_time_opt_guest/0112-ksm-wakeups.patch create mode 100644 patches/boot_time_opt_guest/0113-init-do_mounts-recreate-dev-root.patch create mode 100644 patches/boot_time_opt_guest/0114-xattr-allow-setting-user.-attributes-on-symlinks-by-.patch create mode 100644 patches/boot_time_opt_guest/0151-mm-Export-do_madvise.patch create mode 100644 patches/boot_time_opt_guest/0152-x86-kvm-Notify-host-to-release-pages.patch create mode 100644 patches/boot_time_opt_guest/0153-x86-Return-memory-from-guest-to-host-kernel.patch create mode 100644 patches/boot_time_opt_guest/0154-sysctl-vm-Fine-grained-cache-shrinking.patch create mode 100644 patches/boot_time_opt_guest/guest_boot_time_opt.scc create mode 100644 pci/pci_iov_m.cfg create mode 100644 pci/pci_iov_m.scc create mode 100644 pci/pci_iov_y.cfg create mode 100644 pci/pci_iov_y.scc create mode 100644 pcimodules/pcimodules_n.cfg create mode 100644 pcimodules/pcimodules_n.scc create mode 100644 perf/perf_n.cfg create mode 100644 perf/perf_n.scc create mode 100644 power_supply/power_supply_n.cfg create mode 100644 power_supply/power_supply_n.scc create mode 100644 ppp/ppp_n.cfg create mode 100644 ppp/ppp_n.scc create mode 100644 prockcore/prockcore_n.cfg create mode 100644 prockcore/prockcore_n.scc create mode 100644 reduced_kernel_footprint_guest/reduced_kernel_footprint_guest.scc create mode 100644 serio/serio_n.cfg create mode 100644 serio/serio_n.scc create mode 100644 slip/slip_n.cfg create mode 100644 slip/slip_n.scc create mode 100644 thermal/thermal_n.cfg create mode 100644 thermal/thermal_n.scc create mode 100644 udev/udev.cfg create mode 100644 udev/udev.scc create mode 100644 udev/udev_crypto.cfg create mode 100644 udev/udev_crypto.scc create mode 100644 udev/udev_n.cfg create mode 100644 udev/udev_n.scc create mode 100644 udev/udev_opt.cfg create mode 100644 udev/udev_opt.scc create mode 100644 udev/udev_uefi.cfg create mode 100644 udev/udev_uefi.scc create mode 100644 vga/vga_n.cfg create mode 100644 vga/vga_n.scc create mode 100644 watchdog/watchdog_n.cfg create mode 100644 watchdog/watchdog_n.scc create mode 100644 x86_platform/x86_platform_n.cfg create mode 100644 x86_platform/x86_platform_n.scc diff --git a/6lowpan/6lowpan_n.cfg b/6lowpan/6lowpan_n.cfg new file mode 100644 index 0000000..1bf0778 --- /dev/null +++ b/6lowpan/6lowpan_n.cfg @@ -0,0 +1 @@ +CONFIG_6LOWPAN=n diff --git a/6lowpan/6lowpan_n.scc b/6lowpan/6lowpan_n.scc new file mode 100644 index 0000000..826fdc2 --- /dev/null +++ b/6lowpan/6lowpan_n.scc @@ -0,0 +1,5 @@ +define KFEATURE_DESCRIPTION "Disable 6LoWPAN support" + +define KFEATURE_COMPATIBILITY all + +kconf hardware 6lowpan_n.cfg diff --git a/a.sh b/a.sh new file mode 100644 index 0000000..7fd0726 --- /dev/null +++ b/a.sh @@ -0,0 +1,96 @@ +A features/6lowpan/6lowpan_n.cfg +A features/6lowpan/6lowpan_n.scc +A features/bcma/bcma_n.cfg +A features/bcma/bcma_n.scc +A features/btrfs/btrfs_n.cfg +A features/btrfs/btrfs_n.scc +A features/compilechecks/compilechecks_n.cfg +A features/compilechecks/compilechecks_n.scc +A features/cpu_freq/cpu_freq_n.cfg +A features/cpu_freq/cpu_freq_n.scc +A features/dmiid/dmiid_n.cfg +A features/dmiid/dmiid_n.scc +A features/hwmon/hwmon_n.cfg +A features/hwmon/hwmon_n.scc +A features/i2csupport/i2csupport_n.cfg +A features/i2csupport/i2csupport_n.scc +A features/intel-e1xxxx/e100_n.cfg +A features/intel-e1xxxx/e100_n.scc +A features/intel-e1xxxx/e1xxxx_n.cfg +A features/intel-e1xxxx/e1xxxx_n.scc +A features/isdn/isdn_n.cfg +A features/isdn/isdn_n.scc +A features/ixgbevf/ixgbevf_y.cfg +A features/ixgbevf/ixgbevf_y.scc +A features/kvm/guest_kvm_y.cfg +A features/kvm/guest_kvm_y.scc +A features/kvm/host_n.cfg +A features/kvm/host_n.scc +A features/kvm/virtFS_y.cfg +A features/kvm/virtFS_y.scc +A features/kvm/virtio_balloon_y.cfg +A features/kvm/virtio_balloon_y.scc +A features/kvm/virtio_caif_y.cfg +A features/kvm/virtio_caif_y.scc +A features/kvm/virtio_input_y.cfg +A features/kvm/virtio_input_y.scc +A features/kvm/virtio_pci_legacy_y.cfg +A features/kvm/virtio_pci_legacy_y.scc +A features/kvm/virtio_y.cfg +A features/kvm/virtio_y.scc +A features/loopdev/loopdev_n.cfg +A features/loopdev/loopdev_n.scc +A features/msdos_fat_nt_fs/msdos_fat_nt_fs_n.cfg +A features/msdos_fat_nt_fs/msdos_fat_nt_fs_n.scc +A features/netblkdev/netblkdev_n.cfg +A features/netblkdev/netblkdev_n.scc +A features/netconsole/netconsole_n.cfg +A features/netconsole/netconsole_n.scc +A features/netfilter/netfilter_n.cfg +A features/netfilter/netfilter_n.scc +A features/nfs/nfs_n.cfg +A features/nfs/nfs_n.scc +A features/parport/parport_n.cfg +A features/parport/parport_n.scc +A features/pci/pci_iov_y.cfg +A features/pci/pci_iov_y.scc +A features/pcimodules/pcimodules_n.cfg +A features/pcimodules/pcimodules_n.scc +A features/perf/perf_n.cfg +A features/perf/perf_n.scc +A features/power_supply/power_supply_n.cfg +A features/power_supply/power_supply_n.scc +A features/ppp/ppp_n.cfg +A features/ppp/ppp_n.scc +A features/prockcore/prockcore_n.cfg +A features/prockcore/prockcore_n.scc +A features/reduced_kernel_footprint_guest/reduced_kernel_footprint_guest.scc +A features/serio/serio_n.cfg +A features/serio/serio_n.scc +A features/slip/slip_n.cfg +A features/slip/slip_n.scc +A features/thermal/thermal_n.cfg +A features/thermal/thermal_n.scc +A features/udev/udev_n.cfg +A features/udev/udev_n.scc +A features/vga/vga_n.cfg +A features/vga/vga_n.scc +A features/watchdog/watchdog_n.cfg +A features/watchdog/watchdog_n.scc +A features/x86_platform/x86_platform_n.cfg +A features/x86_platform/x86_platform_n.scc +A patches/boot_time_opt/0102-cpuidle-skip-synchronize_rcu-on-single-CPU-systems.patch +A patches/boot_time_opt/0103-sysrq-skip-synchronize_rcu-if-there-is-no-old-op.patch +A patches/boot_time_opt/0104-fbcon-enable-no-blink-by-default.patch +A patches/boot_time_opt/0105-vmstats-wakeups.patch +A patches/boot_time_opt/0106-pci-probe.patch +A patches/boot_time_opt/0107-cgroup.patch +A patches/boot_time_opt/0108-smpboot-reuse-timer-calibration.patch +A patches/boot_time_opt/0109-perf.patch +A patches/boot_time_opt/0110-pci-probe-identify-known-devices.patch +A patches/boot_time_opt/0111-init-no-wait-for-the-known-devices.patch +A patches/boot_time_opt/0112-ksm-wakeups.patch +A patches/boot_time_opt/0113-init-do_mounts-recreate-dev-root.patch +A patches/boot_time_opt/0114-xattr-allow-setting-user.-attributes-on-symlinks-by-.patch +A patches/boot_time_opt/guest_boot_time_opt.scc +A patches/kernel_startend_msg/0001-printk-add-Enea-Linux-guest-boot-start-end-messages.patch diff --git a/bcma/bcma_n.cfg b/bcma/bcma_n.cfg new file mode 100644 index 0000000..ad052a3 --- /dev/null +++ b/bcma/bcma_n.cfg @@ -0,0 +1,9 @@ +# +# Broadcom specific AMBA +# +CONFIG_BCMA=n +CONFIG_BCMA_HOST_PCI_POSSIBLE=n +CONFIG_BCMA_HOST_PCI=n +# CONFIG_BCMA_HOST_SOC is not set +CONFIG_BCMA_DRIVER_PCI=n +CONFIG_BCMA_DRIVER_GMAC_CMN=n diff --git a/bcma/bcma_n.scc b/bcma/bcma_n.scc new file mode 100644 index 0000000..9cd6a4b --- /dev/null +++ b/bcma/bcma_n.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Disable bcma support" +define KFEATURE_COMPATIBILITY all + +kconf non-hardware bcma_n.cfg diff --git a/btrfs/btrfs_n.cfg b/btrfs/btrfs_n.cfg new file mode 100644 index 0000000..7322f27 --- /dev/null +++ b/btrfs/btrfs_n.cfg @@ -0,0 +1,8 @@ +CONFIG_BTRFS_FS=n +CONFIG_BTRFS_FS_POSIX_ACL=n +# CONFIG_BTRFS_FS_CHECK_INTEGRITY is not set +# CONFIG_BTRFS_FS_RUN_SANITY_TESTS is not set +# CONFIG_BTRFS_DEBUG is not set +# CONFIG_BTRFS_ASSERT is not set +CONFIG_XOR_BLOCKS=n +CONFIG_RAID6_PQ=n diff --git a/btrfs/btrfs_n.scc b/btrfs/btrfs_n.scc new file mode 100644 index 0000000..638f87f --- /dev/null +++ b/btrfs/btrfs_n.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Disable btrfs support" +define KFEATURE_COMPATIBILITY all + +kconf non-hardware btrfs_n.cfg diff --git a/compilechecks/compilechecks_n.cfg b/compilechecks/compilechecks_n.cfg new file mode 100644 index 0000000..87263f0 --- /dev/null +++ b/compilechecks/compilechecks_n.cfg @@ -0,0 +1,6 @@ +CONFIG_ENABLE_WARN_DEPRECATED=n +CONFIG_ENABLE_MUST_CHECK=n +CONFIG_UNUSED_SYMBOLS=n +CONFIG_DEBUG_FS=n +CONFIG_SECTION_MISMATCH_WARN_ONLY=n +CONFIG_FRAME_POINTER=n diff --git a/compilechecks/compilechecks_n.scc b/compilechecks/compilechecks_n.scc new file mode 100644 index 0000000..cd3c68a --- /dev/null +++ b/compilechecks/compilechecks_n.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Disable compile checks support" +define KFEATURE_COMPATIBILITY all + +kconf non-hardware compilechecks_n.cfg diff --git a/cpu_freq/cpu_freq_n.cfg b/cpu_freq/cpu_freq_n.cfg new file mode 100644 index 0000000..51a9713 --- /dev/null +++ b/cpu_freq/cpu_freq_n.cfg @@ -0,0 +1 @@ +CONFIG_CPU_FREQ=n diff --git a/cpu_freq/cpu_freq_n.scc b/cpu_freq/cpu_freq_n.scc new file mode 100644 index 0000000..b38ee5f --- /dev/null +++ b/cpu_freq/cpu_freq_n.scc @@ -0,0 +1,5 @@ +define KFEATURE_DESCRIPTION "Disable CPU frequency scaling" + +define KFEATURE_COMPATIBILITY all + +kconf hardware cpu_freq_n.cfg diff --git a/dmiid/dmiid_n.cfg b/dmiid/dmiid_n.cfg new file mode 100644 index 0000000..61c1980 --- /dev/null +++ b/dmiid/dmiid_n.cfg @@ -0,0 +1 @@ +CONFIG_DMIID=n diff --git a/dmiid/dmiid_n.scc b/dmiid/dmiid_n.scc new file mode 100644 index 0000000..470d344 --- /dev/null +++ b/dmiid/dmiid_n.scc @@ -0,0 +1,5 @@ +define KFEATURE_DESCRIPTION "Disable DMIID support" + +define KFEATURE_COMPATIBILITY all + +kconf hardware dmiid_n.cfg diff --git a/features/netdevices/netdevices_n.cfg b/features/netdevices/netdevices_n.cfg index 2b4db2b..9413d2a 100644 --- a/features/netdevices/netdevices_n.cfg +++ b/features/netdevices/netdevices_n.cfg @@ -33,6 +33,11 @@ CONFIG_BNXT=n CONFIG_BNXT_SRIOV=n CONFIG_NET_VENDOR_BROCADE=n # CONFIG_BNA is not set +CONFIG_NET_VENDOR_CAVIUM=n +# CONFIG_THUNDER_NIC_PF is not set +# CONFIG_THUNDER_NIC_VF is not set +# CONFIG_THUNDER_NIC_BGX is not set +# CONFIG_THUNDER_NIC_RGX is not set # CONFIG_LIQUIDIO is not set CONFIG_NET_VENDOR_CHELSIO=n # CONFIG_CHELSIO_T1 is not set diff --git a/features/powermanagement/powermanagement_n.cfg b/features/powermanagement/powermanagement_n.cfg index 6052f83..6248144 100644 --- a/features/powermanagement/powermanagement_n.cfg +++ b/features/powermanagement/powermanagement_n.cfg @@ -1,3 +1,4 @@ +CONFIG_PM=n CONFIG_SUSPEND=n CONFIG_SUSPEND_FREEZER=n CONFIG_PM_SLEEP=n diff --git a/hwmon/hwmon_n.cfg b/hwmon/hwmon_n.cfg new file mode 100644 index 0000000..617d8f5 --- /dev/null +++ b/hwmon/hwmon_n.cfg @@ -0,0 +1 @@ +CONFIG_HWMON=n diff --git a/hwmon/hwmon_n.scc b/hwmon/hwmon_n.scc new file mode 100644 index 0000000..633a107 --- /dev/null +++ b/hwmon/hwmon_n.scc @@ -0,0 +1,5 @@ +define KFEATURE_DESCRIPTION "Disable hardware monitor support" + +define KFEATURE_COMPATIBILITY all + +kconf hardware hwmon_n.cfg diff --git a/i2csupport/i2csupport_n.cfg b/i2csupport/i2csupport_n.cfg new file mode 100644 index 0000000..30c4a3e --- /dev/null +++ b/i2csupport/i2csupport_n.cfg @@ -0,0 +1,80 @@ +CONFIG_REGMAP=n +CONFIG_REGMAP_I2C=n +# +# EEPROM support +# +CONFIG_EEPROM_AT24=n +# +# I2C support +# +CONFIG_I2C=n +CONFIG_ACPI_I2C_OPREGION=n +CONFIG_I2C_BOARDINFO=n +CONFIG_I2C_COMPAT=n +# CONFIG_I2C_CHARDEV is not set +# CONFIG_I2C_MUX is not set +CONFIG_I2C_HELPER_AUTO=n +CONFIG_I2C_SMBUS=n + +# +# I2C Hardware Bus support +# + +# +# PC SMBus host controller drivers +# +# CONFIG_I2C_ALI1535 is not set +# CONFIG_I2C_ALI1563 is not set +# CONFIG_I2C_ALI15X3 is not set +# CONFIG_I2C_AMD756 is not set +# CONFIG_I2C_AMD8111 is not set +CONFIG_I2C_I801=n +# CONFIG_I2C_ISCH is not set +# CONFIG_I2C_ISMT is not set +# CONFIG_I2C_PIIX4 is not set +# CONFIG_I2C_NFORCE2 is not set +# CONFIG_I2C_SIS5595 is not set +# CONFIG_I2C_SIS630 is not set +# CONFIG_I2C_SIS96X is not set +# CONFIG_I2C_VIA is not set +# CONFIG_I2C_VIAPRO is not set + +# +# ACPI drivers +# +# CONFIG_I2C_SCMI is not set + +# +# I2C system bus drivers (mostly embedded / system-on-chip) +# +# CONFIG_I2C_DESIGNWARE_PLATFORM is not set +# CONFIG_I2C_DESIGNWARE_PCI is not set +# CONFIG_I2C_EMEV2 is not set +# CONFIG_I2C_OCORES is not set +# CONFIG_I2C_PCA_PLATFORM is not set +# CONFIG_I2C_PXA_PCI is not set +# CONFIG_I2C_SIMTEC is not set +# CONFIG_I2C_XILINX is not set + +# +# External I2C/SMBus adapter drivers +# +# CONFIG_I2C_DIOLAN_U2C is not set +# CONFIG_I2C_PARPORT_LIGHT is not set +# CONFIG_I2C_ROBOTFUZZ_OSIF is not set +# CONFIG_I2C_TAOS_EVM is not set +# CONFIG_I2C_TINY_USB is not set + +# +# Other I2C/SMBus bus drivers +# +# CONFIG_I2C_STUB is not set +# CONFIG_I2C_SLAVE is not set +# CONFIG_I2C_DEBUG_CORE is not set +# CONFIG_I2C_DEBUG_ALGO is not set +# CONFIG_I2C_DEBUG_BUS is not set + +# +# SPI RTC drivers +# +CONFIG_RTC_I2C_AND_SPI=n diff --git a/i2csupport/i2csupport_n.scc b/i2csupport/i2csupport_n.scc new file mode 100644 index 0000000..ca127b1 --- /dev/null +++ b/i2csupport/i2csupport_n.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Disable i2c support" +define KFEATURE_COMPATIBILITY all + +kconf non-hardware i2csupport_n.cfg diff --git a/intel-e1xxxx/e100_n.cfg b/intel-e1xxxx/e100_n.cfg new file mode 100644 index 0000000..dab91be --- /dev/null +++ b/intel-e1xxxx/e100_n.cfg @@ -0,0 +1 @@ +CONFIG_E100=n diff --git a/intel-e1xxxx/e100_n.scc b/intel-e1xxxx/e100_n.scc new file mode 100644 index 0000000..bdf9995 --- /dev/null +++ b/intel-e1xxxx/e100_n.scc @@ -0,0 +1,5 @@ +define KFEATURE_DESCRIPTION "Build E100 support as a module" + +define KFEATURE_COMPATIBILITY all + +kconf hardware e100_n.cfg diff --git a/intel-e1xxxx/e1xxxx_m.cfg b/intel-e1xxxx/e1xxxx_m.cfg new file mode 100644 index 0000000..c05e8c6 --- /dev/null +++ b/intel-e1xxxx/e1xxxx_m.cfg @@ -0,0 +1,3 @@ +CONFIG_E1000=m +CONFIG_E1000E=m +CONFIG_E1000E_HWTS=m diff --git a/intel-e1xxxx/e1xxxx_m.scc b/intel-e1xxxx/e1xxxx_m.scc new file mode 100644 index 0000000..d8a8f16 --- /dev/null +++ b/intel-e1xxxx/e1xxxx_m.scc @@ -0,0 +1,5 @@ +define KFEATURE_DESCRIPTION "Build E1xxxx drivers as modules" + +define KFEATURE_COMPATIBILITY all + +kconf hardware e1xxxx_m.cfg diff --git a/intel-e1xxxx/e1xxxx_n.cfg b/intel-e1xxxx/e1xxxx_n.cfg new file mode 100644 index 0000000..d12c714 --- /dev/null +++ b/intel-e1xxxx/e1xxxx_n.cfg @@ -0,0 +1,3 @@ +CONFIG_E1000=n +CONFIG_E1000E=n +CONFIG_E1000E_HWTS=n diff --git a/intel-e1xxxx/e1xxxx_n.scc b/intel-e1xxxx/e1xxxx_n.scc new file mode 100644 index 0000000..3d2b0f1 --- /dev/null +++ b/intel-e1xxxx/e1xxxx_n.scc @@ -0,0 +1,5 @@ +define KFEATURE_DESCRIPTION "Build E1xxxx drivers as modules" + +define KFEATURE_COMPATIBILITY all + +kconf hardware e1xxxx_n.cfg diff --git a/isdn/isdn_n.cfg b/isdn/isdn_n.cfg new file mode 100644 index 0000000..d17ce70 --- /dev/null +++ b/isdn/isdn_n.cfg @@ -0,0 +1,4 @@ +CONFIG_ISDN=n +# CONFIG_ISDN_I4L is not set +CONFIG_ISDN_CAPI=n +CONFIG_CAPI_TRACE=n diff --git a/isdn/isdn_n.scc b/isdn/isdn_n.scc new file mode 100644 index 0000000..53404e7 --- /dev/null +++ b/isdn/isdn_n.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Disable isdn support" +define KFEATURE_COMPATIBILITY all + +kconf non-hardware isdn_n.cfg diff --git a/ixgbevf/ixgbevf_y.cfg b/ixgbevf/ixgbevf_y.cfg new file mode 100644 index 0000000..26ca642 --- /dev/null +++ b/ixgbevf/ixgbevf_y.cfg @@ -0,0 +1 @@ +CONFIG_IXGBEVF=y diff --git a/ixgbevf/ixgbevf_y.scc b/ixgbevf/ixgbevf_y.scc new file mode 100644 index 0000000..4772d88 --- /dev/null +++ b/ixgbevf/ixgbevf_y.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Enable virtual functions for Intel 10G ports" +define KFEATURE_COMPATIBILITY board + +kconf hardware ixgbevf_y.cfg diff --git a/kvm/guest_kvm_y.cfg b/kvm/guest_kvm_y.cfg new file mode 100644 index 0000000..95dfb75 --- /dev/null +++ b/kvm/guest_kvm_y.cfg @@ -0,0 +1,12 @@ +HYPERVISOR_GUEST=y +CONFIG_KVM_GUEST=y +CONFIG_KVM_DEBUG_FS=n +CONFIG_PARAVIRT_TIME_ACCOUNTING=y +CONFIG_PARAVIRT_CLOCK=y +CONFIG_PARAVIRT=y +CONFIG_PARAVIRT_DEBUG=n +CONFIG_PARAVIRT_SPINLOCKS=y +CONFIG_QUEUED_LOCK_STAT=y + +CONFIG_SERIAL_8250=y +CONFIG_SERIAL_8250_CONSOLE=y diff --git a/kvm/guest_kvm_y.scc b/kvm/guest_kvm_y.scc new file mode 100644 index 0000000..d95413f --- /dev/null +++ b/kvm/guest_kvm_y.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Enable KVM guest support" +define KFEATURE_COMPATIBILITY board + +kconf non-hardware guest_kvm_y.cfg diff --git a/kvm/guest_n.cfg b/kvm/guest_n.cfg new file mode 100644 index 0000000..2a046f8 --- /dev/null +++ b/kvm/guest_n.cfg @@ -0,0 +1,4 @@ +HYPERVISOR_GUEST=n +CONFIG_PARAVIRT=n +CONFIG_KVM_GUEST=n +CONFIG_VIRTIO=n diff --git a/kvm/guest_n.scc b/kvm/guest_n.scc new file mode 100644 index 0000000..71020d6 --- /dev/null +++ b/kvm/guest_n.scc @@ -0,0 +1,5 @@ +define KFEATURE_DESCRIPTION "Disable guest support" +define KFEATURE_COMPATIBILITY board + +kconf non-hardware guest_n.cfg + diff --git a/kvm/host_n.cfg b/kvm/host_n.cfg new file mode 100644 index 0000000..9c1302a --- /dev/null +++ b/kvm/host_n.cfg @@ -0,0 +1,2 @@ +CONFIG_VIRTUALIZATION=n +CONFIG_VHOST=n diff --git a/kvm/host_n.scc b/kvm/host_n.scc new file mode 100644 index 0000000..b4b3cde --- /dev/null +++ b/kvm/host_n.scc @@ -0,0 +1,5 @@ +define KFEATURE_DESCRIPTION "Disable guest support" +define KFEATURE_COMPATIBILITY board + +kconf non-hardware host_n.cfg + diff --git a/kvm/qemu-kvm_m.cfg b/kvm/qemu-kvm_m.cfg new file mode 100644 index 0000000..14e6582 --- /dev/null +++ b/kvm/qemu-kvm_m.cfg @@ -0,0 +1,30 @@ +CONFIG_HIGH_RES_TIMERS=y +CONFIG_HAVE_KVM=y +CONFIG_VIRTUALIZATION=y +CONFIG_PREEMPT_NOTIFIERS=y +CONFIG_MMU_NOTIFIER=y +CONFIG_ANON_INODES=y +CONFIG_HAVE_KVM_IRQCHIP=y +CONFIG_HAVE_KVM_IRQFD=y +CONFIG_IRQ_BYPASS_MANAGER=y +CONFIG_HAVE_KVM_IRQ_BYPASS=y +CONFIG_HAVE_KVM_IRQ_ROUTING=y +CONFIG_HAVE_KVM_EVENTFD=y +CONFIG_KVM_ASYNC_PF=y +CONFIG_USER_RETURN_NOTIFIER=y +CONFIG_KVM_MMIO=y +CONFIG_TASKSTATS=y +CONFIG_TASK_DELAY_ACCT=y +CONFIG_PERF_EVENTS=y +CONFIG_HAVE_KVM_MSI=y +CONFIG_HAVE_KVM_CPU_RELAX_INTERCEPT=y +CONFIG_KVM_GENERIC_DIRTYLOG_READ_PROTECT=y +CONFIG_KVM_VFIO=y +CONFIG_SRCU=y + +CONFIG_KVM=m +CONFIG_KVM_INTEL=m +CONFIG_KVM_AMD=m +CONFIG_KVM_MMU_AUDIT=n +CONFIG_KVM_DEVICE_ASSIGNMENT=n + diff --git a/kvm/qemu-kvm_m.scc b/kvm/qemu-kvm_m.scc new file mode 100644 index 0000000..ad21fa1 --- /dev/null +++ b/kvm/qemu-kvm_m.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Enable KVM host support" +define KFEATURE_COMPATIBILITY board + +kconf non-hardware qemu-kvm_m.cfg diff --git a/kvm/virtFS_y.cfg b/kvm/virtFS_y.cfg new file mode 100644 index 0000000..c9fefa1 --- /dev/null +++ b/kvm/virtFS_y.cfg @@ -0,0 +1,4 @@ +CONFIG_NET_9P=y +CONFIG_NET_9P_VIRTIO=y +CONFIG_9P_FS=y +CONFIG_9P_FS_POSIX_ACL=y diff --git a/kvm/virtFS_y.scc b/kvm/virtFS_y.scc new file mode 100644 index 0000000..a3fd078 --- /dev/null +++ b/kvm/virtFS_y.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Enable Plan 9 folder sharing over Virtio - I/O virtualization framework" +define KFEATURE_COMPATIBILITY arch + +kconf non-hardware virtFS_y.cfg diff --git a/kvm/virtio_balloon_y.cfg b/kvm/virtio_balloon_y.cfg new file mode 100644 index 0000000..25119df --- /dev/null +++ b/kvm/virtio_balloon_y.cfg @@ -0,0 +1,2 @@ +CONFIG_VIRTIO=y +CONFIG_VIRTIO_BALLOON=y diff --git a/kvm/virtio_balloon_y.scc b/kvm/virtio_balloon_y.scc new file mode 100644 index 0000000..a4f0b97 --- /dev/null +++ b/kvm/virtio_balloon_y.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "virtio support memory ballooning)" +define KFEATURE_COMPATIBILITY arch + +kconf non-hardware virtio_balloon_y.cfg diff --git a/kvm/virtio_caif_y.cfg b/kvm/virtio_caif_y.cfg new file mode 100644 index 0000000..2af936b --- /dev/null +++ b/kvm/virtio_caif_y.cfg @@ -0,0 +1,5 @@ +CONFIG_CAIF=y +CONFIG_HAS_DMA=y +CONFIG_VHOST_RING=y +CONFIG_VIRTIO=y +CONFIG_CAIF_VIRTIO=y diff --git a/kvm/virtio_caif_y.scc b/kvm/virtio_caif_y.scc new file mode 100644 index 0000000..04d5ac4 --- /dev/null +++ b/kvm/virtio_caif_y.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "CAIF virtio transport driver" +define KFEATURE_COMPATIBILITY arch + +kconf non-hardware guest_caif_y.cfg diff --git a/kvm/virtio_input_y.cfg b/kvm/virtio_input_y.cfg new file mode 100644 index 0000000..e83d993 --- /dev/null +++ b/kvm/virtio_input_y.cfg @@ -0,0 +1,2 @@ +CONFIG_VIRTIO=y +CONFIG_VIRTIO_INPUT=y diff --git a/kvm/virtio_input_y.scc b/kvm/virtio_input_y.scc new file mode 100644 index 0000000..b3e3a9a --- /dev/null +++ b/kvm/virtio_input_y.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "virtio support for input(keyboard, mice...) devices" +define KFEATURE_COMPATIBILITY arch + +kconf non-hardware virtio_input_y.cfg diff --git a/kvm/virtio_pci_legacy_y.cfg b/kvm/virtio_pci_legacy_y.cfg new file mode 100644 index 0000000..4df21c5 --- /dev/null +++ b/kvm/virtio_pci_legacy_y.cfg @@ -0,0 +1,3 @@ +CONFIG_VIRTIO=y +CONFIG_VIRTIO_PCI=y +CONFIG_VIRTIO_PCI_LEGACY=y diff --git a/kvm/virtio_pci_legacy_y.scc b/kvm/virtio_pci_legacy_y.scc new file mode 100644 index 0000000..fcdf9e4 --- /dev/null +++ b/kvm/virtio_pci_legacy_y.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "virtio support for leagacy PCI devices" +define KFEATURE_COMPATIBILITY arch + +kconf non-hardware virtio_pci_legacy_y.cfg diff --git a/kvm/virtio_y.cfg b/kvm/virtio_y.cfg new file mode 100644 index 0000000..ff97d75 --- /dev/null +++ b/kvm/virtio_y.cfg @@ -0,0 +1,28 @@ +CONFIG_VIRTIO=y + +CONFIG_VIRTIO_PCI=y +CONFIG_VIRTIO_PCI_LEGACY=n +CONFIG_MIPS_PCI_VIRTIO=n + +CONFIG_VIRTIO_NET=y +CONFIG_VIRTIO_BLK=y +CONFIG_SCSI_VIRTIO=y + +CONFIG_VIRTIO_CONSOLE=y + +CONFIG_VIRTIO_MMIO=y +CONFIG_VIRTIO_MMIO_CMDLINE_DEVICES=n + +CONFIG_VIRTIO_BALLOON=n +CONFIG_VIRTIO_INPUT=n + +CONFIG_HW_RANDOM_VIRTIO=m + +CONFIG_CAIF_VIRTIO=n +CONFIG_RPMSG_VIRTIO=n + +CONFIG_VSOCKETS=m +CONFIG_VIRTIO_VSOCKETS_COMMON=m +CONFIG_VIRTIO_VSOCKETS=m + +CONFIG_DRM_VIRTIO_GPU=m diff --git a/kvm/virtio_y.scc b/kvm/virtio_y.scc new file mode 100644 index 0000000..a80cfa4 --- /dev/null +++ b/kvm/virtio_y.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "virtio support (core,pci,ring,net,blk,mmio)" +define KFEATURE_COMPATIBILITY arch + +kconf non-hardware virtio_y.cfg diff --git a/loopdev/loopdev_n.cfg b/loopdev/loopdev_n.cfg new file mode 100644 index 0000000..c8d2992 --- /dev/null +++ b/loopdev/loopdev_n.cfg @@ -0,0 +1,2 @@ +CONFIG_BLK_DEV_LOOP=n +CONFIG_BLK_DEV_CRYPTOLOOP=n diff --git a/loopdev/loopdev_n.scc b/loopdev/loopdev_n.scc new file mode 100644 index 0000000..3446f2f --- /dev/null +++ b/loopdev/loopdev_n.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Disable loopdev support" +define KFEATURE_COMPATIBILITY all + +kconf non-hardware loopdev_n.cfg diff --git a/msdos_fat_nt_fs/msdos_fat_nt_fs_n.cfg b/msdos_fat_nt_fs/msdos_fat_nt_fs_n.cfg new file mode 100644 index 0000000..0b5ca51 --- /dev/null +++ b/msdos_fat_nt_fs/msdos_fat_nt_fs_n.cfg @@ -0,0 +1,12 @@ +# +# DOS/FAT/NT Filesystems +# +CONFIG_FAT_FS=n +CONFIG_MSDOS_FS=n +CONFIG_VFAT_FS=n +# CONFIG_VFAT_FS_NO_DUALNAMES is not set +#CONFIG_FAT_DEFAULT_CODEPAGE=437 +#CONFIG_FAT_DEFAULT_IOCHARSET="iso8859-1" +# CONFIG_VFAT_NO_CREATE_WITH_LONGNAMES is not set +# CONFIG_FAT_DEFAULT_UTF8 is not set +# CONFIG_NTFS_FS is not set diff --git a/msdos_fat_nt_fs/msdos_fat_nt_fs_n.scc b/msdos_fat_nt_fs/msdos_fat_nt_fs_n.scc new file mode 100644 index 0000000..49aecac --- /dev/null +++ b/msdos_fat_nt_fs/msdos_fat_nt_fs_n.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Disable msdos_fat_nt_fs support" +define KFEATURE_COMPATIBILITY all + +kconf non-hardware msdos_fat_nt_fs_n.cfg diff --git a/netblkdev/netblkdev_n.cfg b/netblkdev/netblkdev_n.cfg new file mode 100644 index 0000000..fb81129 --- /dev/null +++ b/netblkdev/netblkdev_n.cfg @@ -0,0 +1 @@ +CONFIG_BLK_DEV_NBD=n diff --git a/netblkdev/netblkdev_n.scc b/netblkdev/netblkdev_n.scc new file mode 100644 index 0000000..e2efac9 --- /dev/null +++ b/netblkdev/netblkdev_n.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Disable netblkdev support" +define KFEATURE_COMPATIBILITY all + +kconf non-hardware netblkdev_n.cfg diff --git a/netconsole/netconsole_n.cfg b/netconsole/netconsole_n.cfg new file mode 100644 index 0000000..f74f073 --- /dev/null +++ b/netconsole/netconsole_n.cfg @@ -0,0 +1,3 @@ +CONFIG_NETCONSOLE=n +CONFIG_NETPOLL=n +CONFIG_NET_POLL_CONTROLLER=n diff --git a/netconsole/netconsole_n.scc b/netconsole/netconsole_n.scc new file mode 100644 index 0000000..b6c54da --- /dev/null +++ b/netconsole/netconsole_n.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Disable netconsole support" +define KFEATURE_COMPATIBILITY all + +kconf non-hardware netconsole_n.cfg diff --git a/netfilter/netfilter_n.cfg b/netfilter/netfilter_n.cfg new file mode 100644 index 0000000..aebe7a9 --- /dev/null +++ b/netfilter/netfilter_n.cfg @@ -0,0 +1,222 @@ +CONFIG_IP_ROUTE_CLASSID=n +CONFIG_NETFILTER=n +# CONFIG_NETFILTER_DEBUG is not set +CONFIG_NETFILTER_ADVANCED=n +CONFIG_BRIDGE_NETFILTER=n + +# +# Core Netfilter Configuration +# +CONFIG_NETFILTER_INGRESS=n +CONFIG_NETFILTER_NETLINK=n +# CONFIG_NETFILTER_NETLINK_ACCT is not set +CONFIG_NETFILTER_NETLINK_QUEUE=n +CONFIG_NETFILTER_NETLINK_LOG=n +CONFIG_NF_CONNTRACK=n +CONFIG_NF_CONNTRACK_MARK=n +# CONFIG_NF_CONNTRACK_ZONES is not set +CONFIG_NF_CONNTRACK_PROCFS=n +# CONFIG_NF_CONNTRACK_EVENTS is not set +# CONFIG_NF_CONNTRACK_TIMEOUT is not set +# CONFIG_NF_CONNTRACK_TIMESTAMP is not set +# CONFIG_NF_CT_PROTO_DCCP is not set +CONFIG_NF_CT_PROTO_GRE=n +CONFIG_NF_CT_PROTO_SCTP=n +CONFIG_NF_CT_PROTO_UDPLITE=n +CONFIG_NF_CONNTRACK_AMANDA=n +CONFIG_NF_CONNTRACK_FTP=n +CONFIG_NF_CONNTRACK_H323=n +CONFIG_NF_CONNTRACK_IRC=n +CONFIG_NF_CONNTRACK_BROADCAST=n +CONFIG_NF_CONNTRACK_NETBIOS_NS=n +# CONFIG_NF_CONNTRACK_SNMP is not set +CONFIG_NF_CONNTRACK_PPTP=n +CONFIG_NF_CONNTRACK_SANE=n +CONFIG_NF_CONNTRACK_SIP=n +CONFIG_NF_CONNTRACK_TFTP=n +CONFIG_NF_CT_NETLINK=n +# CONFIG_NF_CT_NETLINK_TIMEOUT is not set +# CONFIG_NETFILTER_NETLINK_GLUE_CT is not set +CONFIG_NF_NAT=n +CONFIG_NF_NAT_NEEDED=n +CONFIG_NF_NAT_PROTO_UDPLITE=n +CONFIG_NF_NAT_PROTO_SCTP=n +CONFIG_NF_NAT_AMANDA=n +CONFIG_NF_NAT_FTP=n +CONFIG_NF_NAT_IRC=n +CONFIG_NF_NAT_SIP=n +CONFIG_NF_NAT_TFTP=n +# CONFIG_NF_NAT_REDIRECT is not set +# CONFIG_NF_TABLES is not set +CONFIG_NETFILTER_XTABLES=n + +# +# Xtables combined modules +# +CONFIG_NETFILTER_XT_MARK=n +CONFIG_NETFILTER_XT_CONNMARK=n + +# +# Xtables targets +# +CONFIG_NETFILTER_XT_TARGET_CHECKSUM=n +CONFIG_NETFILTER_XT_TARGET_CLASSIFY=n +CONFIG_NETFILTER_XT_TARGET_CONNMARK=n +CONFIG_NETFILTER_XT_TARGET_CT=n +CONFIG_NETFILTER_XT_TARGET_DSCP=n +CONFIG_NETFILTER_XT_TARGET_HL=n +# CONFIG_NETFILTER_XT_TARGET_HMARK is not set +# CONFIG_NETFILTER_XT_TARGET_IDLETIMER is not set +# CONFIG_NETFILTER_XT_TARGET_LOG is not set +CONFIG_NETFILTER_XT_TARGET_MARK=n +CONFIG_NETFILTER_XT_NAT=n +# CONFIG_NETFILTER_XT_TARGET_NETMAP is not set +CONFIG_NETFILTER_XT_TARGET_NFLOG=n +CONFIG_NETFILTER_XT_TARGET_NFQUEUE=n +CONFIG_NETFILTER_XT_TARGET_NOTRACK=n +# CONFIG_NETFILTER_XT_TARGET_RATEEST is not set +# CONFIG_NETFILTER_XT_TARGET_REDIRECT is not set +# CONFIG_NETFILTER_XT_TARGET_TEE is not set +# CONFIG_NETFILTER_XT_TARGET_TPROXY is not set +CONFIG_NETFILTER_XT_TARGET_TRACE=n +CONFIG_NETFILTER_XT_TARGET_TCPMSS=n +# CONFIG_NETFILTER_XT_TARGET_TCPOPTSTRIP is not set + +# +# Xtables matches +# +CONFIG_NETFILTER_XT_MATCH_ADDRTYPE=n +# CONFIG_NETFILTER_XT_MATCH_BPF is not set +# CONFIG_NETFILTER_XT_MATCH_CGROUP is not set +# CONFIG_NETFILTER_XT_MATCH_CLUSTER is not set +CONFIG_NETFILTER_XT_MATCH_COMMENT=n +CONFIG_NETFILTER_XT_MATCH_CONNBYTES=n +# CONFIG_NETFILTER_XT_MATCH_CONNLABEL is not set +CONFIG_NETFILTER_XT_MATCH_CONNLIMIT=n +CONFIG_NETFILTER_XT_MATCH_CONNMARK=n +CONFIG_NETFILTER_XT_MATCH_CONNTRACK=n +# CONFIG_NETFILTER_XT_MATCH_CPU is not set +CONFIG_NETFILTER_XT_MATCH_DCCP=n +# CONFIG_NETFILTER_XT_MATCH_DEVGROUP is not set +CONFIG_NETFILTER_XT_MATCH_DSCP=n +CONFIG_NETFILTER_XT_MATCH_ECN=n +CONFIG_NETFILTER_XT_MATCH_ESP=n +CONFIG_NETFILTER_XT_MATCH_HASHLIMIT=n +CONFIG_NETFILTER_XT_MATCH_HELPER=n +CONFIG_NETFILTER_XT_MATCH_HL=n +# CONFIG_NETFILTER_XT_MATCH_IPCOMP is not set +# CONFIG_NETFILTER_XT_MATCH_IPRANGE is not set +# CONFIG_NETFILTER_XT_MATCH_L2TP is not set +CONFIG_NETFILTER_XT_MATCH_LENGTH=n +CONFIG_NETFILTER_XT_MATCH_LIMIT=n +CONFIG_NETFILTER_XT_MATCH_MAC=n +CONFIG_NETFILTER_XT_MATCH_MARK=n +CONFIG_NETFILTER_XT_MATCH_MULTIPORT=n +# CONFIG_NETFILTER_XT_MATCH_NFACCT is not set +# CONFIG_NETFILTER_XT_MATCH_OSF is not set +# CONFIG_NETFILTER_XT_MATCH_OWNER is not set +CONFIG_NETFILTER_XT_MATCH_POLICY=n +# CONFIG_NETFILTER_XT_MATCH_PHYSDEV is not set +CONFIG_NETFILTER_XT_MATCH_PKTTYPE=n +CONFIG_NETFILTER_XT_MATCH_QUOTA=n +# CONFIG_NETFILTER_XT_MATCH_RATEEST is not set +CONFIG_NETFILTER_XT_MATCH_REALM=n +# CONFIG_NETFILTER_XT_MATCH_RECENT is not set +CONFIG_NETFILTER_XT_MATCH_SCTP=n +# CONFIG_NETFILTER_XT_MATCH_SOCKET is not set +CONFIG_NETFILTER_XT_MATCH_STATE=n +CONFIG_NETFILTER_XT_MATCH_STATISTIC=n +CONFIG_NETFILTER_XT_MATCH_STRING=n +CONFIG_NETFILTER_XT_MATCH_TCPMSS=n +# CONFIG_NETFILTER_XT_MATCH_TIME is not set +CONFIG_NETFILTER_XT_MATCH_U32=n +# CONFIG_IP_SET is not set +# CONFIG_IP_VS is not set + +# +# IP: Netfilter Configuration +# +CONFIG_NF_DEFRAG_IPV4=n +CONFIG_NF_CONNTRACK_IPV4=n +# CONFIG_NF_DUP_IPV4 is not set +# CONFIG_NF_LOG_ARP is not set +# CONFIG_NF_LOG_IPV4 is not set +CONFIG_NF_REJECT_IPV4=n +CONFIG_NF_NAT_IPV4=n +CONFIG_NF_NAT_MASQUERADE_IPV4=n +CONFIG_NF_NAT_PROTO_GRE=n +CONFIG_NF_NAT_PPTP=n +CONFIG_NF_NAT_H323=n +CONFIG_IP_NF_IPTABLES=n +CONFIG_IP_NF_MATCH_AH=n +CONFIG_IP_NF_MATCH_ECN=n +# CONFIG_IP_NF_MATCH_RPFILTER is not set +CONFIG_IP_NF_MATCH_TTL=n +CONFIG_IP_NF_FILTER=n +CONFIG_IP_NF_TARGET_REJECT=n +# CONFIG_IP_NF_TARGET_SYNPROXY is not set +CONFIG_IP_NF_NAT=n +CONFIG_IP_NF_TARGET_MASQUERADE=n +# CONFIG_IP_NF_TARGET_NETMAP is not set +# CONFIG_IP_NF_TARGET_REDIRECT is not set +CONFIG_IP_NF_MANGLE=n +CONFIG_IP_NF_TARGET_CLUSTERIP=n +CONFIG_IP_NF_TARGET_ECN=n +CONFIG_IP_NF_TARGET_TTL=n +CONFIG_IP_NF_RAW=n +# CONFIG_IP_NF_SECURITY is not set +CONFIG_IP_NF_ARPTABLES=n +CONFIG_IP_NF_ARPFILTER=n +CONFIG_IP_NF_ARP_MANGLE=n + +# +# IPv6: Netfilter Configuration +# +CONFIG_NF_DEFRAG_IPV6=n +CONFIG_NF_CONNTRACK_IPV6=n +# CONFIG_NF_DUP_IPV6 is not set +# CONFIG_NF_REJECT_IPV6 is not set +# CONFIG_NF_LOG_IPV6 is not set +CONFIG_NF_NAT_IPV6=n +CONFIG_NF_NAT_MASQUERADE_IPV6=n +CONFIG_IP6_NF_IPTABLES=n +# CONFIG_IP6_NF_MATCH_AH is not set +CONFIG_IP6_NF_MATCH_EUI64=n +CONFIG_IP6_NF_MATCH_FRAG=n +CONFIG_IP6_NF_MATCH_OPTS=n +CONFIG_IP6_NF_MATCH_HL=n +CONFIG_IP6_NF_MATCH_IPV6HEADER=n +# CONFIG_IP6_NF_MATCH_MH is not set +# CONFIG_IP6_NF_MATCH_RPFILTER is not set +CONFIG_IP6_NF_MATCH_RT=n +# CONFIG_IP6_NF_TARGET_HL is not set +CONFIG_IP6_NF_FILTER=n +# CONFIG_IP6_NF_TARGET_REJECT is not set +# CONFIG_IP6_NF_TARGET_SYNPROXY is not set +CONFIG_IP6_NF_MANGLE=n +CONFIG_IP6_NF_RAW=n +# CONFIG_IP6_NF_SECURITY is not set +CONFIG_IP6_NF_NAT=n +CONFIG_IP6_NF_TARGET_MASQUERADE=n +# CONFIG_IP6_NF_TARGET_NPT is not set +CONFIG_BRIDGE_NF_EBTABLES=n +CONFIG_BRIDGE_EBT_BROUTE=n +CONFIG_BRIDGE_EBT_T_FILTER=n +CONFIG_BRIDGE_EBT_T_NAT=n +CONFIG_BRIDGE_EBT_802_3=n +CONFIG_BRIDGE_EBT_AMONG=n +CONFIG_BRIDGE_EBT_ARP=n +CONFIG_BRIDGE_EBT_IP=n +CONFIG_BRIDGE_EBT_IP6=n +CONFIG_BRIDGE_EBT_LIMIT=n +CONFIG_BRIDGE_EBT_MARK=n +CONFIG_BRIDGE_EBT_PKTTYPE=n +CONFIG_BRIDGE_EBT_STP=n +CONFIG_BRIDGE_EBT_VLAN=n +CONFIG_BRIDGE_EBT_ARPREPLY=n +CONFIG_BRIDGE_EBT_DNAT=n +CONFIG_BRIDGE_EBT_MARK_T=n +CONFIG_BRIDGE_EBT_REDIRECT=n +CONFIG_BRIDGE_EBT_SNAT=n +CONFIG_BRIDGE_EBT_LOG=n +CONFIG_BRIDGE_EBT_NFLOG=n diff --git a/netfilter/netfilter_n.scc b/netfilter/netfilter_n.scc new file mode 100644 index 0000000..279aa21 --- /dev/null +++ b/netfilter/netfilter_n.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Disable netfilter and conn tracking" +define KFEATURE_COMPATIBILITY all + +kconf non-hardware netfilter_n.cfg diff --git a/netfilter/netfilter_y.cfg b/netfilter/netfilter_y.cfg new file mode 100644 index 0000000..b1c310e --- /dev/null +++ b/netfilter/netfilter_y.cfg @@ -0,0 +1,10 @@ +CONFIG_NF_CONNTRACK=y +CONFIG_NF_CONNTRACK_IPV4=y +CONFIG_NF_NAT=y +CONFIG_NETFILTER_XTABLES=y +CONFIG_NETFILTER_XT_NAT=y +CONFIG_NETFILTER_XT_MATCH_ADDRTYPE=y +CONFIG_NETFILTER_XT_MATCH_CONNTRACK=y +CONFIG_NF_DEFRAG_IPV4=y +CONFIG_NF_CONNTRACK_IPV4=y +CONFIG_NF_NAT_IPV4=y diff --git a/netfilter/netfilter_y.scc b/netfilter/netfilter_y.scc new file mode 100644 index 0000000..f0e2e01 --- /dev/null +++ b/netfilter/netfilter_y.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Enable netfilter + conn tracking as built-in modules" +define KFEATURE_COMPATIBILITY all + +kconf non-hardware netfilter_y.cfg diff --git a/nfs/nfs_n.cfg b/nfs/nfs_n.cfg new file mode 100644 index 0000000..a8e60a3 --- /dev/null +++ b/nfs/nfs_n.cfg @@ -0,0 +1,44 @@ +CONFIG_NETWORK_FILESYSTEMS=n +CONFIG_NFS_FS=n +CONFIG_NFS_V2=n +#CONFIG_NFS_DEF_FILE_IO_SIZE=4096 +CONFIG_NFS_V3=n +# CONFIG_NFS_V3_ACL is not set +CONFIG_NFS_V4=n +# CONFIG_NFS_SWAP is not set +# CONFIG_NFS_V4_1 is not set +CONFIG_ROOT_NFS=n +# CONFIG_NFS_USE_LEGACY_DNS is not set +CONFIG_NFS_USE_KERNEL_DNS=n +CONFIG_NFSD=n +CONFIG_NFSD_V3=n +# CONFIG_NFSD_V3_ACL is not set +CONFIG_NFSD_V4=n +# CONFIG_NFSD_BLOCKLAYOUT is not set +# CONFIG_NFSD_SCSILAYOUT is not set +# CONFIG_NFSD_FLEXFILELAYOUT is not set +# CONFIG_NFSD_V4_SECURITY_LABEL is not set +# CONFIG_NFSD_FAULT_INJECTION is not set +CONFIG_GRACE_PERIOD=n +CONFIG_LOCKD=n +CONFIG_LOCKD_V4=n +CONFIG_NFS_COMMON=n +CONFIG_SUNRPC=n +CONFIG_SUNRPC_GSS=n +CONFIG_RPCSEC_GSS_KRB5=n +# CONFIG_SUNRPC_DEBUG is not set +# CONFIG_CEPH_FS is not set +CONFIG_CIFS=n +# CONFIG_CIFS_STATS is not set +# CONFIG_CIFS_WEAK_PW_HASH is not set +# CONFIG_CIFS_UPCALL is not set +CONFIG_CIFS_XATTR=n +CONFIG_CIFS_POSIX=n +# CONFIG_CIFS_ACL is not set +CONFIG_CIFS_DEBUG=n +# CONFIG_CIFS_DEBUG2 is not set +# CONFIG_CIFS_DFS_UPCALL is not set +# CONFIG_CIFS_SMB2 is not set +# CONFIG_NCP_FS is not set +# CONFIG_CODA_FS is not set +# CONFIG_AFS_FS is not set diff --git a/nfs/nfs_n.scc b/nfs/nfs_n.scc new file mode 100644 index 0000000..4cec9a7 --- /dev/null +++ b/nfs/nfs_n.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Disable nfs support" +define KFEATURE_COMPATIBILITY all + +kconf non-hardware nfs_n.cfg diff --git a/parport/parport_n.cfg b/parport/parport_n.cfg new file mode 100644 index 0000000..1e35578 --- /dev/null +++ b/parport/parport_n.cfg @@ -0,0 +1,8 @@ +CONFIG_PARPORT=n +CONFIG_PARPORT_PC=n +# CONFIG_PARPORT_SERIAL is not set +# CONFIG_PARPORT_PC_FIFO is not set +# CONFIG_PARPORT_PC_SUPERIO is not set +# CONFIG_PARPORT_GSC is not set +# CONFIG_PARPORT_AX88796 is not set +# CONFIG_PARPORT_1284 is not set diff --git a/parport/parport_n.scc b/parport/parport_n.scc new file mode 100644 index 0000000..bed7632 --- /dev/null +++ b/parport/parport_n.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Disable parport support" +define KFEATURE_COMPATIBILITY all + +kconf non-hardware parport_n.cfg diff --git a/patches/boot_time_opt_guest/0102-cpuidle-skip-synchronize_rcu-on-single-CPU-systems.patch b/patches/boot_time_opt_guest/0102-cpuidle-skip-synchronize_rcu-on-single-CPU-systems.patch new file mode 100644 index 0000000..1de2a6b --- /dev/null +++ b/patches/boot_time_opt_guest/0102-cpuidle-skip-synchronize_rcu-on-single-CPU-systems.patch @@ -0,0 +1,34 @@ +From 6b0fb5b2a7a157c04d8ab6ad71b092034d0048bf Mon Sep 17 00:00:00 2001 +From: Arjan van de Ven +Date: Wed, 11 Feb 2015 16:19:26 -0600 +Subject: [PATCH 102/114] cpuidle: skip synchronize_rcu() on single CPU systems + +synchronize_rcu() is pretty expensive, and on single CPU systems we don't need +it in this specific case, so skip it. + +Signed-off-by: Arjan van de Ven +Signed-off-by: Miguel Bernal Marin +--- + drivers/cpuidle/cpuidle.c | 5 ++++- + 1 file changed, 4 insertions(+), 1 deletion(-) + +diff --git a/drivers/cpuidle/cpuidle.c b/drivers/cpuidle/cpuidle.c +index 62810ff3b00f..f1d110411098 100644 +--- a/drivers/cpuidle/cpuidle.c ++++ b/drivers/cpuidle/cpuidle.c +@@ -324,8 +324,11 @@ void cpuidle_uninstall_idle_handler(void) + /* + * Make sure external observers (such as the scheduler) + * are done looking at pointed idle states. ++ * This is only relevant if there is more than one cpu, ++ * if there is only one CPU, that is us... and we're ++ * coherent to ourselves. + */ +- synchronize_rcu(); ++ + } + + /** +-- +2.11.1 + diff --git a/patches/boot_time_opt_guest/0103-sysrq-skip-synchronize_rcu-if-there-is-no-old-op.patch b/patches/boot_time_opt_guest/0103-sysrq-skip-synchronize_rcu-if-there-is-no-old-op.patch new file mode 100644 index 0000000..d3a20fb --- /dev/null +++ b/patches/boot_time_opt_guest/0103-sysrq-skip-synchronize_rcu-if-there-is-no-old-op.patch @@ -0,0 +1,38 @@ +From 7be707833bb35c295eb702d13cf73ac9390e4b31 Mon Sep 17 00:00:00 2001 +From: Arjan van de Ven +Date: Wed, 11 Feb 2015 16:25:16 -0600 +Subject: [PATCH 103/114] sysrq: skip synchronize_rcu() if there is no old op + +synchronize_rcu() is expensive. Currently it is called as part of the sysrq +registration/unregistration, which happens during boot several times. +Now, the reason for the synchronize_rcu() is to allow an old registered +operation to expire properly... which is pointless if the old operation +is NULL... +So we can save the common case of the old operation being NULL a lot of time +by just checking for non-NULL prior to the synchronize_rcu() + +Signed-off-by: Arjan van de Ven +Signed-off-by: Miguel Bernal Marin +--- + drivers/tty/sysrq.c | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +diff --git a/drivers/tty/sysrq.c b/drivers/tty/sysrq.c +index 701c085bb19b..c60c7ba57ad9 100644 +--- a/drivers/tty/sysrq.c ++++ b/drivers/tty/sysrq.c +@@ -1065,8 +1065,10 @@ static int __sysrq_swap_key_ops(int key, struct sysrq_key_op *insert_op_p, + * A concurrent __handle_sysrq either got the old op or the new op. + * Wait for it to go away before returning, so the code for an old + * op is not freed (eg. on module unload) while it is in use. ++ * This is only relevant if the old op is not NULL of course. + */ +- synchronize_rcu(); ++ if (remove_op_p) ++ synchronize_rcu(); + + return retval; + } +-- +2.11.1 + diff --git a/patches/boot_time_opt_guest/0104-fbcon-enable-no-blink-by-default.patch b/patches/boot_time_opt_guest/0104-fbcon-enable-no-blink-by-default.patch new file mode 100644 index 0000000..715c195 --- /dev/null +++ b/patches/boot_time_opt_guest/0104-fbcon-enable-no-blink-by-default.patch @@ -0,0 +1,26 @@ +From 5899ff79ed4e3514420e1530a3588a922832dae5 Mon Sep 17 00:00:00 2001 +From: Jose Carlos Venegas Munoz +Date: Mon, 13 Apr 2015 11:26:36 -0500 +Subject: [PATCH 104/114] fbcon: enable no blink by default + +Author: Arjan van de Ven +--- + drivers/video/console/fbcon.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/drivers/video/console/fbcon.c b/drivers/video/console/fbcon.c +index a44f5627b82a..95b73366b86f 100644 +--- a/drivers/video/console/fbcon.c ++++ b/drivers/video/console/fbcon.c +@@ -146,7 +146,7 @@ static const struct consw fb_con; + + static int fbcon_set_origin(struct vc_data *); + +-static int fbcon_cursor_noblink; ++static int fbcon_cursor_noblink = 1; + + #define divides(a, b) ((!(a) || (b)%(a)) ? 0 : 1) + +-- +2.11.1 + diff --git a/patches/boot_time_opt_guest/0105-vmstats-wakeups.patch b/patches/boot_time_opt_guest/0105-vmstats-wakeups.patch new file mode 100644 index 0000000..09b109a --- /dev/null +++ b/patches/boot_time_opt_guest/0105-vmstats-wakeups.patch @@ -0,0 +1,28 @@ +From ff47b4e9be8113b4ba05d6f2afee3db6904bc10f Mon Sep 17 00:00:00 2001 +From: Arjan van de Ven +Date: Wed, 11 Feb 2015 16:47:20 -0600 +Subject: [PATCH 105/114] vmstats: wakeups + +Author: Arjan van de Ven + +Signed-off-by: Miguel Bernal Marin +--- + mm/vmstat.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/mm/vmstat.c b/mm/vmstat.c +index 7c28df36f50f..efe1b6797139 100644 +--- a/mm/vmstat.c ++++ b/mm/vmstat.c +@@ -1549,7 +1549,7 @@ static const struct file_operations proc_vmstat_file_operations = { + #ifdef CONFIG_SMP + static struct workqueue_struct *vmstat_wq; + static DEFINE_PER_CPU(struct delayed_work, vmstat_work); +-int sysctl_stat_interval __read_mostly = HZ; ++int sysctl_stat_interval __read_mostly = 8 * HZ; + + #ifdef CONFIG_PROC_FS + static void refresh_vm_stats(struct work_struct *work) +-- +2.11.1 + diff --git a/patches/boot_time_opt_guest/0106-pci-probe.patch b/patches/boot_time_opt_guest/0106-pci-probe.patch new file mode 100644 index 0000000..5045926 --- /dev/null +++ b/patches/boot_time_opt_guest/0106-pci-probe.patch @@ -0,0 +1,123 @@ +From b225caf8f743b9f5f9e84d0df711ee0c17e049ae Mon Sep 17 00:00:00 2001 +From: Arjan van de Ven +Date: Wed, 11 Feb 2015 16:53:08 -0600 +Subject: [PATCH 106/114] pci: probe + +Author: Arjan van de Ven + +Signed-off-by: Miguel Bernal Marin +--- + drivers/pci/probe.c | 43 ++++++++++++++++++++++++++++++++++++++++--- + 1 file changed, 40 insertions(+), 3 deletions(-) + +diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c +index 204960e70333..7399a06698da 100644 +--- a/drivers/pci/probe.c ++++ b/drivers/pci/probe.c +@@ -182,6 +182,10 @@ int __pci_read_base(struct pci_dev *dev, enum pci_bar_type type, + + mask = type ? PCI_ROM_ADDRESS_MASK : ~0; + ++ res->name = pci_name(dev); ++ ++ printk("clr: Starting probe for %s\n", res->name); ++ + /* No printks while decoding is disabled! */ + if (!dev->mmio_always_on) { + pci_read_config_word(dev, PCI_COMMAND, &orig_cmd); +@@ -191,8 +195,6 @@ int __pci_read_base(struct pci_dev *dev, enum pci_bar_type type, + } + } + +- res->name = pci_name(dev); +- + pci_read_config_dword(dev, pos, &l); + pci_write_config_dword(dev, pos, l | mask); + pci_read_config_dword(dev, pos, &sz); +@@ -324,6 +326,8 @@ static void pci_read_bases(struct pci_dev *dev, unsigned int howmany, int rom) + if (dev->non_compliant_bars) + return; + ++ printk("clr: pci_read_bases start\n"); ++ + for (pos = 0; pos < howmany; pos++) { + struct resource *res = &dev->resource[pos]; + reg = PCI_BASE_ADDRESS_0 + (pos << 2); +@@ -332,11 +336,13 @@ static void pci_read_bases(struct pci_dev *dev, unsigned int howmany, int rom) + + if (rom) { + struct resource *res = &dev->resource[PCI_ROM_RESOURCE]; ++ printk("clr: rom path\n"); + dev->rom_base_reg = rom; + res->flags = IORESOURCE_MEM | IORESOURCE_PREFETCH | + IORESOURCE_READONLY | IORESOURCE_SIZEALIGN; + __pci_read_base(dev, pci_bar_mem32, res, rom); + } ++ printk("clr: pci_read_bases end\n"); + } + + static void pci_read_bridge_io(struct pci_bus *child) +@@ -1311,6 +1317,28 @@ static void pci_msi_setup_pci_dev(struct pci_dev *dev) + pci_msix_clear_and_set_ctrl(dev, PCI_MSIX_FLAGS_ENABLE, 0); + } + ++static int guess_bar_count(int class) ++{ ++ if (class == 0x068000) ++ return 0; ++ if (class == 0x020000) ++ return 2; ++ if (class == 0x010000) ++ return 2; ++ if (class == 0x00ff00) ++ return 1; ++ return 6; ++} ++ ++static int has_rom(int class, int rom) ++{ ++ if (class == 0x020000) ++ return 0; ++ if (class == 0x010000 || class == 0x00ff00) ++ return 0; ++ return rom; ++} ++ + /** + * pci_setup_device - fill in class and map information of a device + * @dev: the device structure to fill +@@ -1329,6 +1357,9 @@ int pci_setup_device(struct pci_dev *dev) + int pos = 0; + struct pci_bus_region region; + struct resource *res; ++ int maxbar; ++ ++ printk("clr: pci_setup_device start\n"); + + if (pci_read_config_byte(dev, PCI_HEADER_TYPE, &hdr_type)) + return -EIO; +@@ -1383,7 +1414,11 @@ int pci_setup_device(struct pci_dev *dev) + if (class == PCI_CLASS_BRIDGE_PCI) + goto bad; + pci_read_irq(dev); +- pci_read_bases(dev, 6, PCI_ROM_ADDRESS); ++ ++ maxbar = guess_bar_count(dev->class); ++ ++ if (class != PCI_CLASS_STORAGE_IDE) ++ pci_read_bases(dev, maxbar, has_rom(dev->class, PCI_ROM_ADDRESS)); + pci_read_config_word(dev, PCI_SUBSYSTEM_VENDOR_ID, &dev->subsystem_vendor); + pci_read_config_word(dev, PCI_SUBSYSTEM_ID, &dev->subsystem_device); + +@@ -1468,6 +1503,8 @@ int pci_setup_device(struct pci_dev *dev) + dev->class = PCI_CLASS_NOT_DEFINED << 8; + } + ++ printk("clr: pci_setup_device end\n"); ++ + /* We found a fine healthy device, go go go... */ + return 0; + } +-- +2.11.1 + diff --git a/patches/boot_time_opt_guest/0107-cgroup.patch b/patches/boot_time_opt_guest/0107-cgroup.patch new file mode 100644 index 0000000..d68c686 --- /dev/null +++ b/patches/boot_time_opt_guest/0107-cgroup.patch @@ -0,0 +1,107 @@ +From 0adc5bfd84939d11d3c172eab0a00bfab4aadb46 Mon Sep 17 00:00:00 2001 +From: Arjan van de Ven +Date: Fri, 28 Aug 2015 11:00:36 -0500 +Subject: [PATCH 107/114] cgroup + +Author: Arjan van de Ven + +Signed-off-by: Miguel Bernal Marin +Signed-off-by: Jose Carlos Venegas Munoz +--- + include/linux/cgroup-defs.h | 2 +- + kernel/cgroup.c | 24 ++++++++++++++---------- + 2 files changed, 15 insertions(+), 11 deletions(-) + +diff --git a/include/linux/cgroup-defs.h b/include/linux/cgroup-defs.h +index 861b4677fc5b..5d3c345ee60c 100644 +--- a/include/linux/cgroup-defs.h ++++ b/include/linux/cgroup-defs.h +@@ -137,7 +137,7 @@ struct cgroup_subsys_state { + + /* percpu_ref killing and RCU release */ + struct rcu_head rcu_head; +- struct work_struct destroy_work; ++ struct delayed_work destroy_work; + }; + + /* +diff --git a/kernel/cgroup.c b/kernel/cgroup.c +index 53bbca7c4859..6de39d8213ed 100644 +--- a/kernel/cgroup.c ++++ b/kernel/cgroup.c +@@ -73,7 +73,7 @@ + * Expiring in the middle is a performance problem not a correctness one. + * 1 sec should be enough. + */ +-#define CGROUP_PIDLIST_DESTROY_DELAY HZ ++#define CGROUP_PIDLIST_DESTROY_DELAY round_jiffies_relative(HZ) + + #define CGROUP_FILE_NAME_MAX (MAX_CGROUP_TYPE_NAMELEN + \ + MAX_CFTYPE_NAME + 2) +@@ -4986,8 +4986,9 @@ static struct cftype cgroup_legacy_base_files[] = { + */ + static void css_free_work_fn(struct work_struct *work) + { ++ struct delayed_work *dwork = to_delayed_work(work); + struct cgroup_subsys_state *css = +- container_of(work, struct cgroup_subsys_state, destroy_work); ++ container_of(dwork, struct cgroup_subsys_state, destroy_work); + struct cgroup_subsys *ss = css->ss; + struct cgroup *cgrp = css->cgroup; + +@@ -5036,14 +5037,15 @@ static void css_free_rcu_fn(struct rcu_head *rcu_head) + struct cgroup_subsys_state *css = + container_of(rcu_head, struct cgroup_subsys_state, rcu_head); + +- INIT_WORK(&css->destroy_work, css_free_work_fn); +- queue_work(cgroup_destroy_wq, &css->destroy_work); ++ INIT_DELAYED_WORK(&css->destroy_work, css_free_work_fn); ++ queue_delayed_work(cgroup_destroy_wq, &css->destroy_work, CGROUP_PIDLIST_DESTROY_DELAY); + } + + static void css_release_work_fn(struct work_struct *work) + { ++ struct delayed_work *dwork = to_delayed_work(work); + struct cgroup_subsys_state *css = +- container_of(work, struct cgroup_subsys_state, destroy_work); ++ container_of(dwork, struct cgroup_subsys_state, destroy_work); + struct cgroup_subsys *ss = css->ss; + struct cgroup *cgrp = css->cgroup; + +@@ -5088,8 +5090,9 @@ static void css_release(struct percpu_ref *ref) + struct cgroup_subsys_state *css = + container_of(ref, struct cgroup_subsys_state, refcnt); + +- INIT_WORK(&css->destroy_work, css_release_work_fn); +- queue_work(cgroup_destroy_wq, &css->destroy_work); ++ INIT_DELAYED_WORK(&css->destroy_work, css_release_work_fn); ++ queue_delayed_work(cgroup_destroy_wq, &css->destroy_work, CGROUP_PIDLIST_DESTROY_DELAY); ++ + } + + static void init_and_link_css(struct cgroup_subsys_state *css, +@@ -5371,8 +5374,9 @@ static int cgroup_mkdir(struct kernfs_node *parent_kn, const char *name, + */ + static void css_killed_work_fn(struct work_struct *work) + { ++ struct delayed_work *dwork = to_delayed_work(work); + struct cgroup_subsys_state *css = +- container_of(work, struct cgroup_subsys_state, destroy_work); ++ container_of(dwork, struct cgroup_subsys_state, destroy_work); + + mutex_lock(&cgroup_mutex); + +@@ -5393,8 +5397,8 @@ static void css_killed_ref_fn(struct percpu_ref *ref) + container_of(ref, struct cgroup_subsys_state, refcnt); + + if (atomic_dec_and_test(&css->online_cnt)) { +- INIT_WORK(&css->destroy_work, css_killed_work_fn); +- queue_work(cgroup_destroy_wq, &css->destroy_work); ++ INIT_DELAYED_WORK(&css->destroy_work, css_killed_work_fn); ++ queue_delayed_work(cgroup_destroy_wq, &css->destroy_work, CGROUP_PIDLIST_DESTROY_DELAY); + } + } + +-- +2.11.1 + diff --git a/patches/boot_time_opt_guest/0108-smpboot-reuse-timer-calibration.patch b/patches/boot_time_opt_guest/0108-smpboot-reuse-timer-calibration.patch new file mode 100644 index 0000000..48be94a --- /dev/null +++ b/patches/boot_time_opt_guest/0108-smpboot-reuse-timer-calibration.patch @@ -0,0 +1,45 @@ +From 634947be6c24d844af5f6ecf59453f2ddc09e032 Mon Sep 17 00:00:00 2001 +From: Arjan van de Ven +Date: Wed, 11 Feb 2015 17:28:14 -0600 +Subject: [PATCH 108/114] smpboot: reuse timer calibration + +NO point recalibrating for known-constant tsc... saves 200ms+ of boot time. + +Author: Arjan van de Ven + +Signed-off-by: Miguel Bernal Marin +--- + arch/x86/kernel/smpboot.c | 2 +- + arch/x86/kernel/tsc.c | 3 +++ + 2 files changed, 4 insertions(+), 1 deletion(-) + +diff --git a/arch/x86/kernel/smpboot.c b/arch/x86/kernel/smpboot.c +index 99b920d0e516..e17bb425bb52 100644 +--- a/arch/x86/kernel/smpboot.c ++++ b/arch/x86/kernel/smpboot.c +@@ -761,7 +761,7 @@ wakeup_secondary_cpu_via_init(int phys_apicid, unsigned long start_eip) + pr_debug("Waiting for send to finish...\n"); + send_status = safe_apic_wait_icr_idle(); + +- udelay(init_udelay); ++ udelay(100); + + pr_debug("Deasserting INIT\n"); + +diff --git a/arch/x86/kernel/tsc.c b/arch/x86/kernel/tsc.c +index 37e7cf544e51..e99be8a6a132 100644 +--- a/arch/x86/kernel/tsc.c ++++ b/arch/x86/kernel/tsc.c +@@ -1413,6 +1413,9 @@ unsigned long calibrate_delay_is_known(void) + if (!mask) + return 0; + ++ if (cpu !=0) ++ return cpu_data(0).loops_per_jiffy; ++ + sibling = cpumask_any_but(mask, cpu); + if (sibling < nr_cpu_ids) + return cpu_data(sibling).loops_per_jiffy; +-- +2.11.1 + diff --git a/patches/boot_time_opt_guest/0109-perf.patch b/patches/boot_time_opt_guest/0109-perf.patch new file mode 100644 index 0000000..75f50f6 --- /dev/null +++ b/patches/boot_time_opt_guest/0109-perf.patch @@ -0,0 +1,28 @@ +From cce700dfbd5fdbf72b96e6479ca539ab4d880ce2 Mon Sep 17 00:00:00 2001 +From: Arjan van de Ven +Date: Wed, 4 Nov 2015 15:17:10 -0600 +Subject: [PATCH 109/114] perf + +Author: Arjan van de Ven + +Signed-off-by: Miguel Bernal Marin +--- + arch/x86/events/intel/core.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/arch/x86/events/intel/core.c b/arch/x86/events/intel/core.c +index eb1484c86bb4..c13ea26ac066 100644 +--- a/arch/x86/events/intel/core.c ++++ b/arch/x86/events/intel/core.c +@@ -4040,7 +4040,7 @@ __init int intel_pmu_init(void) + */ + if (x86_pmu.extra_regs) { + for (er = x86_pmu.extra_regs; er->msr; er++) { +- er->extra_msr_access = check_msr(er->msr, 0x11UL); ++ er->extra_msr_access = false; + /* Disable LBR select mapping */ + if ((er->idx == EXTRA_REG_LBR) && !er->extra_msr_access) + x86_pmu.lbr_sel_map = NULL; +-- +2.11.1 + diff --git a/patches/boot_time_opt_guest/0110-pci-probe-identify-known-devices.patch b/patches/boot_time_opt_guest/0110-pci-probe-identify-known-devices.patch new file mode 100644 index 0000000..742a045 --- /dev/null +++ b/patches/boot_time_opt_guest/0110-pci-probe-identify-known-devices.patch @@ -0,0 +1,190 @@ +From c662d99134b67c58e63ecc17c2531588a3a51596 Mon Sep 17 00:00:00 2001 +From: Arjan van de Ven +Date: Sat, 14 Feb 2015 09:49:41 -0600 +Subject: [PATCH 110/114] pci: probe: identify known devices + +Author: Arjan van de Ven +Modify-by: Miguel Bernal Marin + +Signed-off-by: Miguel Bernal Marin +--- + drivers/pci/probe.c | 156 ++++++++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 156 insertions(+) + +diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c +index 7399a06698da..4fb2d7fed4c5 100644 +--- a/drivers/pci/probe.c ++++ b/drivers/pci/probe.c +@@ -163,6 +163,159 @@ static inline unsigned long decode_bar(struct pci_dev *dev, u32 bar) + + #define PCI_COMMAND_DECODE_ENABLE (PCI_COMMAND_MEMORY | PCI_COMMAND_IO) + ++/* shortcut version of __pci_read_base where we know the sizes already */ ++int __pci_read_base_shortcut(struct pci_dev *dev, enum pci_bar_type type, ++ struct resource *res, unsigned int pos, u32 sz_in, u32 sz2_in) ++{ ++ u32 l, sz; ++ u64 l64, sz64, mask64; ++ struct pci_bus_region region, inverted_region; ++ ++ res->name = pci_name(dev); ++ ++ pci_read_config_dword(dev, pos, &l); ++ ++ sz = sz_in; ++ ++ /* ++ * All bits set in sz means the device isn't working properly. ++ * If the BAR isn't implemented, all bits must be 0. If it's a ++ * memory BAR or a ROM, bit 0 must be clear; if it's an io BAR, bit ++ * 1 must be clear. ++ * Here we set the size and is not 0xffffffff ++ */ ++ ++ /* ++ * I don't know how l can have all bits set. Copied from old code. ++ * Maybe it fixes a bug on some ancient platform. ++ */ ++ if (l == 0xffffffff) ++ l = 0; ++ ++ if (type == pci_bar_unknown) { ++ res->flags = decode_bar(dev, l); ++ res->flags |= IORESOURCE_SIZEALIGN; ++ if (res->flags & IORESOURCE_IO) { ++ l64 = l & PCI_BASE_ADDRESS_IO_MASK; ++ sz64 = sz & PCI_BASE_ADDRESS_IO_MASK; ++ mask64 = PCI_BASE_ADDRESS_IO_MASK & (u32)IO_SPACE_LIMIT; ++ } else { ++ l64 = l & PCI_BASE_ADDRESS_MEM_MASK; ++ sz64 = sz & PCI_BASE_ADDRESS_MEM_MASK; ++ mask64 = (u32)PCI_BASE_ADDRESS_MEM_MASK; ++ } ++ } else { ++ res->flags |= (l & IORESOURCE_ROM_ENABLE); ++ l64 = l & PCI_ROM_ADDRESS_MASK; ++ sz64 = sz & PCI_ROM_ADDRESS_MASK; ++ mask64 = (u32)PCI_ROM_ADDRESS_MASK; ++ } ++ ++ if (res->flags & IORESOURCE_MEM_64) { ++ pci_read_config_dword(dev, pos + 4, &l); ++ sz = sz2_in; ++ ++ l64 |= ((u64)l << 32); ++ sz64 |= ((u64)sz << 32); ++ mask64 |= ((u64)~0 << 32); ++ } ++ ++ if (!sz64) ++ goto fail; ++ ++ sz64 = pci_size(l64, sz64, mask64); ++ if (!sz64) { ++ dev_info(&dev->dev, FW_BUG "reg 0x%x: invalid BAR (can't size)\n", ++ pos); ++ goto fail; ++ } ++ ++ if (res->flags & IORESOURCE_MEM_64) { ++ if ((sizeof(dma_addr_t) < 8 || sizeof(resource_size_t) < 8) && ++ sz64 > 0x100000000ULL) { ++ res->flags |= IORESOURCE_UNSET | IORESOURCE_DISABLED; ++ res->start = 0; ++ res->end = 0; ++ dev_err(&dev->dev, "reg 0x%x: can't handle BAR larger than 4GB (size %#010llx)\n", ++ pos, (unsigned long long)sz64); ++ goto out; ++ } ++ ++ if ((sizeof(dma_addr_t) < 8) && l) { ++ /* Above 32-bit boundary; try to reallocate */ ++ res->flags |= IORESOURCE_UNSET; ++ res->start = 0; ++ res->end = sz64; ++ dev_info(&dev->dev, "reg 0x%x: can't handle BAR above 4GB (bus address %#010llx)\n", ++ pos, (unsigned long long)l64); ++ goto out; ++ } ++ } ++ ++ region.start = l64; ++ region.end = l64 + sz64; ++ ++ pcibios_bus_to_resource(dev->bus, res, ®ion); ++ pcibios_resource_to_bus(dev->bus, &inverted_region, res); ++ ++ /* ++ * If "A" is a BAR value (a bus address), "bus_to_resource(A)" is ++ * the corresponding resource address (the physical address used by ++ * the CPU. Converting that resource address back to a bus address ++ * should yield the original BAR value: ++ * ++ * resource_to_bus(bus_to_resource(A)) == A ++ * ++ * If it doesn't, CPU accesses to "bus_to_resource(A)" will not ++ * be claimed by the device. ++ */ ++ if (inverted_region.start != region.start) { ++ res->flags |= IORESOURCE_UNSET; ++ res->start = 0; ++ res->end = region.end - region.start; ++ dev_info(&dev->dev, "reg 0x%x: initial BAR value %#010llx invalid\n", ++ pos, (unsigned long long)region.start); ++ } ++ ++ goto out; ++ ++ ++fail: ++ res->flags = 0; ++out: ++ if (res->flags) ++ dev_printk(KERN_DEBUG, &dev->dev, "reg 0x%x: %pR\n", pos, res); ++ ++ return (res->flags & IORESOURCE_MEM_64) ? 1 : 0; ++} ++ ++static int is_known_device(struct pci_dev *dev, int pos, int *sz) ++{ ++ /* Red Hat, Inc : Virtio network device */ ++ if (dev->vendor == 0x1af4 && dev->device == 0x1000) { ++ if (pos == 0x10) { ++ *sz = 0xffffffe1; ++ return 1; ++ } ++ if (pos == 0x14) { ++ *sz = 0xfffff000; ++ return 1; ++ } ++ } ++ /* Red Hat, Inc : Virtio block device */ ++ if (dev->vendor == 0x1af4 && dev->device == 0x1001) { ++ if (pos == 0x10) { ++ *sz = 0xffffffc1; ++ return 1; ++ } ++ if (pos == 0x14) { ++ *sz = 0xfffff000; ++ return 1; ++ } ++ } ++ return 0; ++} ++ + /** + * pci_read_base - read a PCI BAR + * @dev: the PCI device +@@ -182,6 +335,9 @@ int __pci_read_base(struct pci_dev *dev, enum pci_bar_type type, + + mask = type ? PCI_ROM_ADDRESS_MASK : ~0; + ++ if (is_known_device(dev, pos, &sz)) ++ return __pci_read_base_shortcut(dev, type, res, pos, sz, 0); ++ + res->name = pci_name(dev); + + printk("clr: Starting probe for %s\n", res->name); +-- +2.11.1 + diff --git a/patches/boot_time_opt_guest/0111-init-no-wait-for-the-known-devices.patch b/patches/boot_time_opt_guest/0111-init-no-wait-for-the-known-devices.patch new file mode 100644 index 0000000..701a18d --- /dev/null +++ b/patches/boot_time_opt_guest/0111-init-no-wait-for-the-known-devices.patch @@ -0,0 +1,39 @@ +From be2ab4809c6b5058fbf3cd54c0f59c56416e572c Mon Sep 17 00:00:00 2001 +From: Arjan van de Ven +Date: Mon, 22 Jun 2015 09:33:33 -0500 +Subject: [PATCH 111/114] init: no wait for the known devices + +No wait for the known devices to complete their probing + +Author: Arjan van de Ven + +Signed-off-by: Miguel Bernal Marin +--- + init/do_mounts.c | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +diff --git a/init/do_mounts.c b/init/do_mounts.c +index c2de5104aad2..40725f0f5fb3 100644 +--- a/init/do_mounts.c ++++ b/init/do_mounts.c +@@ -28,6 +28,7 @@ + #include + #include + #include ++#include + + #include + #include +@@ -563,7 +564,8 @@ void __init prepare_namespace(void) + * For example, it is not atypical to wait 5 seconds here + * for the touchpad of a laptop to initialize. + */ +- wait_for_device_probe(); ++ //wait_for_device_probe(); ++ async_synchronize_full(); + + md_run_setup(); + +-- +2.11.1 + diff --git a/patches/boot_time_opt_guest/0112-ksm-wakeups.patch b/patches/boot_time_opt_guest/0112-ksm-wakeups.patch new file mode 100644 index 0000000..b131e3f --- /dev/null +++ b/patches/boot_time_opt_guest/0112-ksm-wakeups.patch @@ -0,0 +1,32 @@ +From 2dc48e4b5c651691b7028991b64c935047b41b19 Mon Sep 17 00:00:00 2001 +From: Arjan van de Ven +Date: Mon, 14 Mar 2016 11:06:46 -0600 +Subject: [PATCH 112/114] ksm-wakeups + +reduce wakeups in ksm +--- + mm/ksm.c | 8 ++++++-- + 1 file changed, 6 insertions(+), 2 deletions(-) + +diff --git a/mm/ksm.c b/mm/ksm.c +index 9ae6011a41f8..eecd3ff669e2 100644 +--- a/mm/ksm.c ++++ b/mm/ksm.c +@@ -1725,8 +1725,12 @@ static int ksm_scan_thread(void *nothing) + try_to_freeze(); + + if (ksmd_should_run()) { +- schedule_timeout_interruptible( +- msecs_to_jiffies(ksm_thread_sleep_millisecs)); ++ if (ksm_thread_sleep_millisecs >= 1000) ++ schedule_timeout_interruptible( ++ msecs_to_jiffies(round_jiffies_relative(ksm_thread_sleep_millisecs))); ++ else ++ schedule_timeout_interruptible( ++ msecs_to_jiffies(ksm_thread_sleep_millisecs)); + } else { + wait_event_freezable(ksm_thread_wait, + ksmd_should_run() || kthread_should_stop()); +-- +2.11.1 + diff --git a/patches/boot_time_opt_guest/0113-init-do_mounts-recreate-dev-root.patch b/patches/boot_time_opt_guest/0113-init-do_mounts-recreate-dev-root.patch new file mode 100644 index 0000000..047eddb --- /dev/null +++ b/patches/boot_time_opt_guest/0113-init-do_mounts-recreate-dev-root.patch @@ -0,0 +1,42 @@ +From 179b7f41d5509f93cd297cc81c5d8da4a3123d9d Mon Sep 17 00:00:00 2001 +From: Miguel Bernal Marin +Date: Fri, 20 Nov 2015 14:01:26 -0600 +Subject: [PATCH 113/114] init: do_mounts: recreate /dev/root + +Rootfs shows as is mounted in /dev/root, but this devices is not present in +/dev directory. + +Signed-off-by: Miguel Bernal Marin +--- + init/do_mounts.c | 8 ++++++++ + 1 file changed, 8 insertions(+) + +diff --git a/init/do_mounts.c b/init/do_mounts.c +index 40725f0f5fb3..78b5b1dba8ca 100644 +--- a/init/do_mounts.c ++++ b/init/do_mounts.c +@@ -550,6 +550,7 @@ void __init mount_root(void) + void __init prepare_namespace(void) + { + int is_floppy; ++ int err; + + if (root_delay) { + printk(KERN_INFO "Waiting %d sec before mounting root device...\n", +@@ -604,6 +605,13 @@ void __init prepare_namespace(void) + devtmpfs_mount("dev"); + sys_mount(".", "/", NULL, MS_MOVE, NULL); + sys_chroot("."); ++#ifdef CONFIG_BLOCK ++ /* recreate the /dev/root */ ++ err = create_dev("/dev/root", ROOT_DEV); ++ ++ if (err < 0) ++ pr_emerg("Failed to create /dev/root: %d\n", err); ++#endif + } + + static bool is_tmpfs; +-- +2.11.1 + diff --git a/patches/boot_time_opt_guest/0114-xattr-allow-setting-user.-attributes-on-symlinks-by-.patch b/patches/boot_time_opt_guest/0114-xattr-allow-setting-user.-attributes-on-symlinks-by-.patch new file mode 100644 index 0000000..dee9058 --- /dev/null +++ b/patches/boot_time_opt_guest/0114-xattr-allow-setting-user.-attributes-on-symlinks-by-.patch @@ -0,0 +1,56 @@ +From 02fd2e6a7c708bf973209f9b238c5c61cbf15239 Mon Sep 17 00:00:00 2001 +From: Alan Cox +Date: Thu, 10 Mar 2016 15:11:28 +0000 +Subject: [PATCH 114/114] xattr: allow setting user.* attributes on symlinks by + owner + +Kvmtool and clear containers supports using user attributes to label host +files with the virtual uid/guid of the file in the container. This allows an +end user to manage their files and a complete uid space without all the ugly +namespace stuff. + +The one gap in the support is symlinks because an end user can change the +ownership of a symbolic link. We support attributes on these files as you +can already (as root) set security attributes on them. + +The current rules seem slightly over-paranoid and as we have a use case this +patch enables updating the attributes on a symbolic link IFF you are the +owner of the synlink (as permissions are not usually meaningful on the link +itself). + +Signed-off-by: Alan Cox +--- + fs/xattr.c | 14 ++++++++------ + 1 file changed, 8 insertions(+), 6 deletions(-) + +diff --git a/fs/xattr.c b/fs/xattr.c +index 7e3317cf4045..e005c30acb2c 100644 +--- a/fs/xattr.c ++++ b/fs/xattr.c +@@ -118,15 +118,17 @@ xattr_permission(struct inode *inode, const char *name, int mask) + } + + /* +- * In the user.* namespace, only regular files and directories can have +- * extended attributes. For sticky directories, only the owner and +- * privileged users can write attributes. ++ * In the user.* namespace, only regular files, symbolic links, and ++ * directories can have extended attributes. For symbolic links and ++ * sticky directories, only the owner and privileged users can write ++ * attributes. + */ + if (!strncmp(name, XATTR_USER_PREFIX, XATTR_USER_PREFIX_LEN)) { +- if (!S_ISREG(inode->i_mode) && !S_ISDIR(inode->i_mode)) ++ if (!S_ISREG(inode->i_mode) && !S_ISDIR(inode->i_mode) && !S_ISLNK(inode->i_mode)) + return (mask & MAY_WRITE) ? -EPERM : -ENODATA; +- if (S_ISDIR(inode->i_mode) && (inode->i_mode & S_ISVTX) && +- (mask & MAY_WRITE) && !inode_owner_or_capable(inode)) ++ if (((S_ISDIR(inode->i_mode) && (inode->i_mode & S_ISVTX)) ++ || S_ISLNK(inode->i_mode)) && (mask & MAY_WRITE) ++ && !inode_owner_or_capable(inode)) + return -EPERM; + } + +-- +2.11.1 + diff --git a/patches/boot_time_opt_guest/0151-mm-Export-do_madvise.patch b/patches/boot_time_opt_guest/0151-mm-Export-do_madvise.patch new file mode 100644 index 0000000..a6dbff7 --- /dev/null +++ b/patches/boot_time_opt_guest/0151-mm-Export-do_madvise.patch @@ -0,0 +1,84 @@ +From 99b4cdcce43ad0f706120bef26fef8c628c572cf Mon Sep 17 00:00:00 2001 +From: Sebastien Boeuf +Date: Mon, 23 Jan 2017 15:03:52 -0800 +Subject: [PATCH 151/154] mm: Export do_madvise() + +Combined with some interesting flags madvise() system call +allows to free memory more smartly and more efficiently than +we could do with a simple free(). The issue is that is not +available for kernel modules that could need it. + +In order to solve this lack of support, this patch exports +do_madvise() so as to make it available to the entire kernel. +The already existing madvise() system call is unchanged and +now relies on this new do_madvise() function. + +Suggested-by: Arjan van de Ven +Signed-off-by: Sebastien Boeuf +--- + include/linux/mm.h | 2 ++ + mm/madvise.c | 25 +++++++++++++++++++++---- + 2 files changed, 23 insertions(+), 4 deletions(-) + +diff --git a/include/linux/mm.h b/include/linux/mm.h +index 0b5b2e4df14e..925ec25f99a8 100644 +--- a/include/linux/mm.h ++++ b/include/linux/mm.h +@@ -2450,5 +2450,7 @@ void __init setup_nr_node_ids(void); + static inline void setup_nr_node_ids(void) {} + #endif + ++extern int do_madvise(unsigned long start, size_t len_in, int behavior); ++ + #endif /* __KERNEL__ */ + #endif /* _LINUX_MM_H */ +diff --git a/mm/madvise.c b/mm/madvise.c +index 93fb63e88b5e..c8bbf93d4978 100644 +--- a/mm/madvise.c ++++ b/mm/madvise.c +@@ -618,9 +618,7 @@ madvise_behavior_valid(int behavior) + } + + /* +- * The madvise(2) system call. +- * +- * Applications can use madvise() to advise the kernel how it should ++ * Kernel modules can use do_madvise() to advise the kernel how it should + * handle paging I/O in this VM area. The idea is to help the kernel + * use appropriate read-ahead and caching techniques. The information + * provided is advisory only, and can be safely disregarded by the +@@ -673,7 +671,7 @@ madvise_behavior_valid(int behavior) + * -EBADF - map exists, but area maps something that isn't a file. + * -EAGAIN - a kernel resource was temporarily unavailable. + */ +-SYSCALL_DEFINE3(madvise, unsigned long, start, size_t, len_in, int, behavior) ++int do_madvise(unsigned long start, size_t len_in, int behavior) + { + unsigned long end, tmp; + struct vm_area_struct *vma, *prev; +@@ -767,3 +765,22 @@ SYSCALL_DEFINE3(madvise, unsigned long, start, size_t, len_in, int, behavior) + + return error; + } ++EXPORT_SYMBOL_GPL(do_madvise); ++ ++/* ++ * The madvise(2) system call. ++ * ++ * Applications can use madvise() system call to advise the kernel how ++ * it should handle paging I/O in this VM area. The idea is to help ++ * the kernel use appropriate read-ahead and caching techniques. The ++ * information provided is advisory only, and can be safely disregarded ++ * by the kernel without affecting the correct operation of the application. ++ * ++ * behavior values are the same than the ones defined in madvise() ++ * ++ * return values are the same than the ones defined in madvise() ++ */ ++SYSCALL_DEFINE3(madvise, unsigned long, start, size_t, len_in, int, behavior) ++{ ++ return do_madvise(start, len_in, behavior); ++} +-- +2.12.1 + diff --git a/patches/boot_time_opt_guest/0152-x86-kvm-Notify-host-to-release-pages.patch b/patches/boot_time_opt_guest/0152-x86-kvm-Notify-host-to-release-pages.patch new file mode 100644 index 0000000..ff9d8c0 --- /dev/null +++ b/patches/boot_time_opt_guest/0152-x86-kvm-Notify-host-to-release-pages.patch @@ -0,0 +1,180 @@ +From d28921b5f797829e4e676f7968ae688ef96b7992 Mon Sep 17 00:00:00 2001 +From: Sebastien Boeuf +Date: Mon, 23 Jan 2017 15:08:55 -0800 +Subject: [PATCH 152/154] x86: kvm: Notify host to release pages + +In context of hypervisors managing several virtual machines, we +want those virtual machines to give the memory they used back to +the host when they don't need it anymore. + +This patch introduces a new hypercall KVM_HC_RETURN_MEM, allowing +the guest kernel to notify the host kernel when such event occurs. +And relying on do_madvise() function that we have previously exported, +it issues a call to this function when it receives the new hypercall. + +Use of do_madvise() with MADV_DONTNEED flag will allow the guest to +ask for a new page without going through a new hypercall. Instead, +it will be able to start using that memory again as it will get +faulted back in as a fresh new page. That's why do_madvise() is more +efficient than doing vm_unmap() to return some memory to the host. + +This patch introduces also a new sysctl kvm_madv_instant_free, +allowing user to set MADV_FREE advice instead of MADV_DONTNEED. +Indeed, MADV_FREE saves more performances than using MADV_DONTNEED +because it does not zero the pages in case the memory has not been +freed by the kernel. This can happen when there was no need for the +kernel to get this memory back, meaning it was keeping those pages +in the right state to be re-used by the same application. +MADV_FREE being a very recent advice introduced in kernel 4.5, we +only want to enable it through a sysctl in case the user want to +use it. + +Suggested-by: Arjan van de Ven +Signed-off-by: Sebastien Boeuf +--- + arch/x86/kvm/x86.c | 17 +++++++++++++++++ + include/linux/mm.h | 5 +++++ + include/uapi/linux/kvm_para.h | 3 +++ + kernel/sysctl.c | 7 +++++++ + mm/Makefile | 2 +- + mm/kvm.c | 25 +++++++++++++++++++++++++ + 6 files changed, 58 insertions(+), 1 deletion(-) + create mode 100644 mm/kvm.c + +diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c +index 582c75311f95..683a94dd5f03 100644 +--- a/arch/x86/kvm/x86.c ++++ b/arch/x86/kvm/x86.c +@@ -46,6 +46,7 @@ + #include + #include + #include ++#include + #include + #include + #include +@@ -6019,6 +6020,19 @@ static void kvm_pv_kick_cpu_op(struct kvm *kvm, unsigned long flags, int apicid) + kvm_irq_delivery_to_apic(kvm, NULL, &lapic_irq, NULL); + } + ++static int kvm_pv_return_mem_op(struct kvm *kvm, gpa_t gpa, size_t len) ++{ ++ unsigned long start = gfn_to_hva(kvm, gpa_to_gfn(gpa)); ++ ++ if (len > KVM_MAX_RET_MEM_SIZE) ++ return KVM_EPERM; ++ ++ if (kvm_is_error_hva(start + len)) ++ return KVM_EFAULT; ++ ++ return do_madvise(start, len, kvm_ret_mem_advice); ++} ++ + void kvm_vcpu_deactivate_apicv(struct kvm_vcpu *vcpu) + { + vcpu->arch.apicv_active = false; +@@ -6065,6 +6079,9 @@ int kvm_emulate_hypercall(struct kvm_vcpu *vcpu) + kvm_pv_kick_cpu_op(vcpu->kvm, a0, a1); + ret = 0; + break; ++ case KVM_HC_RETURN_MEM: ++ ret = kvm_pv_return_mem_op(vcpu->kvm, a0, a1); ++ break; + default: + ret = -KVM_ENOSYS; + break; +diff --git a/include/linux/mm.h b/include/linux/mm.h +index 925ec25f99a8..833f23d98baa 100644 +--- a/include/linux/mm.h ++++ b/include/linux/mm.h +@@ -2303,6 +2303,11 @@ extern bool process_shares_mm(struct task_struct *p, struct mm_struct *mm); + extern int sysctl_drop_caches; + int drop_caches_sysctl_handler(struct ctl_table *, int, + void __user *, size_t *, loff_t *); ++extern int sysctl_kvm_madv_instant_free; ++extern int kvm_ret_mem_advice; ++int kvm_madv_instant_free_sysctl_handler(struct ctl_table *table, int write, ++ void __user *buffer, size_t *length, ++ loff_t *ppos); + #endif + + void drop_slab(void); +diff --git a/include/uapi/linux/kvm_para.h b/include/uapi/linux/kvm_para.h +index bf6cd7d5cac2..7d90f77d87d0 100644 +--- a/include/uapi/linux/kvm_para.h ++++ b/include/uapi/linux/kvm_para.h +@@ -23,6 +23,9 @@ + #define KVM_HC_MIPS_GET_CLOCK_FREQ 6 + #define KVM_HC_MIPS_EXIT_VM 7 + #define KVM_HC_MIPS_CONSOLE_OUTPUT 8 ++#define KVM_HC_RETURN_MEM 10 ++ ++#define KVM_MAX_RET_MEM_SIZE (1 << 22) // 4MiB + + /* + * hypercalls use architecture specific +diff --git a/kernel/sysctl.c b/kernel/sysctl.c +index c1095cdc0fe2..d8ae774fa042 100644 +--- a/kernel/sysctl.c ++++ b/kernel/sysctl.c +@@ -1398,6 +1398,13 @@ static struct ctl_table vm_table[] = { + .extra1 = &one, + .extra2 = &four, + }, ++ { ++ .procname = "kvm_madv_instant_free", ++ .data = &sysctl_kvm_madv_instant_free, ++ .maxlen = sizeof(int), ++ .mode = 0644, ++ .proc_handler = kvm_madv_instant_free_sysctl_handler, ++ }, + #ifdef CONFIG_COMPACTION + { + .procname = "compact_memory", +diff --git a/mm/Makefile b/mm/Makefile +index 295bd7a9f76b..651ce0aff140 100644 +--- a/mm/Makefile ++++ b/mm/Makefile +@@ -37,7 +37,7 @@ obj-y := filemap.o mempool.o oom_kill.o \ + mm_init.o mmu_context.o percpu.o slab_common.o \ + compaction.o vmacache.o \ + interval_tree.o list_lru.o workingset.o \ +- prfile.o debug.o $(mmu-y) ++ prfile.o debug.o kvm.o $(mmu-y) + + obj-y += init-mm.o + +diff --git a/mm/kvm.c b/mm/kvm.c +new file mode 100644 +index 000000000000..8945f6a311b9 +--- /dev/null ++++ b/mm/kvm.c +@@ -0,0 +1,25 @@ ++#include ++ ++int sysctl_kvm_madv_instant_free; ++ ++int kvm_ret_mem_advice = MADV_DONTNEED; ++EXPORT_SYMBOL_GPL(kvm_ret_mem_advice); ++ ++int kvm_madv_instant_free_sysctl_handler(struct ctl_table *table, int write, ++ void __user *buffer, size_t *length, loff_t *ppos) ++{ ++ int ret; ++ ++ ret = proc_dointvec(table, write, buffer, length, ppos); ++ if (ret) ++ return ret; ++ ++#ifdef MADV_FREE ++ if (sysctl_kvm_madv_instant_free > 0) ++ kvm_ret_mem_advice = MADV_FREE; ++ else ++ kvm_ret_mem_advice = MADV_DONTNEED; ++#endif ++ ++ return 0; ++} +-- +2.12.1 + diff --git a/patches/boot_time_opt_guest/0153-x86-Return-memory-from-guest-to-host-kernel.patch b/patches/boot_time_opt_guest/0153-x86-Return-memory-from-guest-to-host-kernel.patch new file mode 100644 index 0000000..cdb876a --- /dev/null +++ b/patches/boot_time_opt_guest/0153-x86-Return-memory-from-guest-to-host-kernel.patch @@ -0,0 +1,155 @@ +From 855ef164854307839c08c60688eaeac14f9a649e Mon Sep 17 00:00:00 2001 +From: Sebastien Boeuf +Date: Mon, 23 Jan 2017 15:26:13 -0800 +Subject: [PATCH 153/154] x86: Return memory from guest to host kernel + +All virtual machines need memory to perform various tasks, but this +memory is not released to the host after it is not used anymore. We +have to wait for the termination of the virtual machine to get this +memory back into the host. + +Ballooning mechanism is close but not designed for the same purpose. +In case we hit memory limits of the system, the host predicts how much +memory can be asked back from a guest, and it issues an hypercall to +retrieve this memory. + +The solution proposed is different because it does not wait for host +needs before to return memory, and it knows precisely how much memory +it can return. + +The way to notify the host side about such a return is to rely on +the new hypercall KVM_HC_RETURN_MEM. In order to avoid the CPU to be +overloaded with too many hypercalls, we only return memory blocks of +order 7 (512k blocks) and higher. This value has been found running +memory tests using multiple threads allocating/freeing high amount +of memory. Those tests were run for different order values, and 7 was +the best tradeoff between the number of hypercalls issued and the +amount of memory returned to the host. + +In order to limit performances impact related to this code addition, +we check for blocks of order 7 or higher. This means it only costs an +additional function call and a branch to perform this check. + +Furthermore, this code has been added to the "merge" codepath of the +buddy allocator, which is not as sensitive as the "free" codepath. +Not all blocks going through the "free" codepath will end up in the +"merge" codepath because some of them won't find their free buddy. +But this is a negligible amount since the kernel does not use many +high order blocks directly. Instead, those bigger blocks are often +broken into smaller chunks used as low order blocks. At the time +those small blocks are released, they go through the merge path. + +Benchmarks such as ebizzy and will-it-scale have been run in order +to make sure this patch does not affect kernel performances and no +significant differences were observed. + +Suggested-by: Arjan van de Ven +Signed-off-by: Sebastien Boeuf +--- + arch/x86/include/asm/kvm_para.h | 22 ++++++++++++++++++++++ + arch/x86/kernel/kvm.c | 10 ++++++++++ + include/linux/mm-arch-hooks.h | 8 ++++++++ + mm/page_alloc.c | 2 ++ + 4 files changed, 42 insertions(+) + +diff --git a/arch/x86/include/asm/kvm_para.h b/arch/x86/include/asm/kvm_para.h +index bc62e7cbf1b1..4a2f6d1adbd2 100644 +--- a/arch/x86/include/asm/kvm_para.h ++++ b/arch/x86/include/asm/kvm_para.h +@@ -92,6 +92,28 @@ void kvm_async_pf_task_wait(u32 token); + void kvm_async_pf_task_wake(u32 token); + u32 kvm_read_and_reset_pf_reason(void); + extern void kvm_disable_steal_time(void); ++void kvm_arch_return_memory(struct page *page, unsigned int order); ++ ++/* ++ * This order has been found in an empirical way, running memory tests ++ * through many iterations to assess the number of hypercalls issued ++ * and the amount of memory returned. In case you change this order to ++ * 6 or 8, it should not impact your performances significantly. ++ * ++ * Smaller values lead to less memory waste, but consume more CPU on ++ * hypercalls. Larger values use less CPU, but do not as precisely ++ * inform the hypervisor of which memory is free. ++ */ ++#define RET_MEM_BUDDY_ORDER 7 ++ ++static inline void arch_buddy_merge(struct page *page, unsigned int order) ++{ ++ if (order < RET_MEM_BUDDY_ORDER) ++ return; ++ ++ kvm_arch_return_memory(page, order); ++} ++#define arch_buddy_merge arch_buddy_merge + + #ifdef CONFIG_PARAVIRT_SPINLOCKS + void __init kvm_spinlock_init(void); +diff --git a/arch/x86/kernel/kvm.c b/arch/x86/kernel/kvm.c +index edbbfc854e39..14167b3f6514 100644 +--- a/arch/x86/kernel/kvm.c ++++ b/arch/x86/kernel/kvm.c +@@ -552,6 +552,16 @@ static __init int activate_jump_labels(void) + } + arch_initcall(activate_jump_labels); + ++void kvm_arch_return_memory(struct page *page, unsigned int order) ++{ ++ if (!kvm_para_available()) ++ return; ++ ++ kvm_hypercall2(KVM_HC_RETURN_MEM, ++ page_to_phys(page), ++ PAGE_SIZE << order); ++} ++ + #ifdef CONFIG_PARAVIRT_SPINLOCKS + + /* Kick a cpu by its apicid. Used to wake up a halted vcpu */ +diff --git a/include/linux/mm-arch-hooks.h b/include/linux/mm-arch-hooks.h +index 4efc3f56e6df..26eb3a05a8a3 100644 +--- a/include/linux/mm-arch-hooks.h ++++ b/include/linux/mm-arch-hooks.h +@@ -12,6 +12,7 @@ + #define _LINUX_MM_ARCH_HOOKS_H + + #include ++#include + + #ifndef arch_remap + static inline void arch_remap(struct mm_struct *mm, +@@ -22,4 +23,11 @@ static inline void arch_remap(struct mm_struct *mm, + #define arch_remap arch_remap + #endif + ++#ifndef arch_buddy_merge ++static inline void arch_buddy_merge(struct page *page, unsigned int order) ++{ ++} ++#define arch_buddy_merge arch_buddy_merge ++#endif ++ + #endif /* _LINUX_MM_ARCH_HOOKS_H */ +diff --git a/mm/page_alloc.c b/mm/page_alloc.c +index 1460e6ad5e14..5f6e6371bc6f 100644 +--- a/mm/page_alloc.c ++++ b/mm/page_alloc.c +@@ -64,6 +64,7 @@ + #include + #include + #include ++#include + + #include + #include +@@ -855,6 +856,7 @@ static inline void __free_one_page(struct page *page, + } + + done_merging: ++ arch_buddy_merge(page, order); + set_page_order(page, order); + + /* +-- +2.12.1 + diff --git a/patches/boot_time_opt_guest/0154-sysctl-vm-Fine-grained-cache-shrinking.patch b/patches/boot_time_opt_guest/0154-sysctl-vm-Fine-grained-cache-shrinking.patch new file mode 100644 index 0000000..07d4a83 --- /dev/null +++ b/patches/boot_time_opt_guest/0154-sysctl-vm-Fine-grained-cache-shrinking.patch @@ -0,0 +1,137 @@ +From 2c145b5233b504f5226a0f4bc44baeef33b444d8 Mon Sep 17 00:00:00 2001 +From: Sebastien Boeuf +Date: Mon, 23 Jan 2017 15:32:39 -0800 +Subject: [PATCH 154/154] sysctl: vm: Fine-grained cache shrinking + +Lots of virtual machines are let in idle state for days until they +are terminated, and they can keep a large amount of memory in their +cache, meaning this memory cannot be used by other processes. + +We tried to release this memory using existing drop_caches sysctl, +but it led to the complete cache loss while it could have been used +whether the idle process wakes up. Indeed, the process can't find any +available cached data and it directly affects performances to rebuild +it from scratch. + +Instead, the solution we want is based on shrinking gradually system +cache over time. This patch adds a new sysctl shrink_caches_mb so as +to allow userspace applications indicating the kernel it should shrink +system cache up to the amount (in MiB) specified. + +There is an application called "memshrinker" which uses this new +mechanism. It runs in the background and periodically releases a +specified amount of cache. This amount is based on the remaining +cache on the system, and period is computed to follow a shrinking +model. It results in saving a lot of memory for other processes +running on the system. + +Suggested-by: Arjan van de Ven +Signed-off-by: Sebastien Boeuf +--- + fs/drop_caches.c | 25 +++++++++++++++++++++++++ + include/linux/mm.h | 4 ++++ + kernel/sysctl.c | 8 ++++++++ + mm/vmscan.c | 2 -- + 4 files changed, 37 insertions(+), 2 deletions(-) + +diff --git a/fs/drop_caches.c b/fs/drop_caches.c +index d72d52b90433..f564dfcc13a4 100644 +--- a/fs/drop_caches.c ++++ b/fs/drop_caches.c +@@ -8,10 +8,12 @@ + #include + #include + #include ++#include + #include "internal.h" + + /* A global variable is a bit ugly, but it keeps the code simple */ + int sysctl_drop_caches; ++int sysctl_shrink_caches_mb; + + static void drop_pagecache_sb(struct super_block *sb, void *unused) + { +@@ -67,3 +69,26 @@ int drop_caches_sysctl_handler(struct ctl_table *table, int write, + } + return 0; + } ++ ++int shrink_caches_sysctl_handler(struct ctl_table *table, int write, ++ void __user *buffer, size_t *length, loff_t *ppos) ++{ ++ int ret; ++ unsigned long nr_to_reclaim, page_reclaimed; ++ ++ ret = proc_dointvec_minmax(table, write, buffer, length, ppos); ++ if (ret) ++ return ret; ++ ++ nr_to_reclaim = sysctl_shrink_caches_mb * (1 << 20) / PAGE_SIZE; ++ if (write) { ++ page_reclaimed = shrink_all_memory(nr_to_reclaim); ++ if (page_reclaimed > 0) ++ lru_add_drain_all(); ++ ++ if (page_reclaimed != nr_to_reclaim) ++ return page_reclaimed; ++ } ++ ++ return 0; ++} +diff --git a/include/linux/mm.h b/include/linux/mm.h +index 833f23d98baa..0bb66c1c31c9 100644 +--- a/include/linux/mm.h ++++ b/include/linux/mm.h +@@ -2308,6 +2308,10 @@ extern int kvm_ret_mem_advice; + int kvm_madv_instant_free_sysctl_handler(struct ctl_table *table, int write, + void __user *buffer, size_t *length, + loff_t *ppos); ++extern int sysctl_shrink_caches_mb; ++int shrink_caches_sysctl_handler(struct ctl_table *table, int write, ++ void __user *buffer, size_t *length, ++ loff_t *ppos); + #endif + + void drop_slab(void); +diff --git a/kernel/sysctl.c b/kernel/sysctl.c +index d8ae774fa042..5dc9a46ae212 100644 +--- a/kernel/sysctl.c ++++ b/kernel/sysctl.c +@@ -1405,6 +1405,14 @@ static struct ctl_table vm_table[] = { + .mode = 0644, + .proc_handler = kvm_madv_instant_free_sysctl_handler, + }, ++ { ++ .procname = "shrink_caches_mb", ++ .data = &sysctl_shrink_caches_mb, ++ .maxlen = sizeof(int), ++ .mode = 0644, ++ .proc_handler = shrink_caches_sysctl_handler, ++ .extra1 = &one, ++ }, + #ifdef CONFIG_COMPACTION + { + .procname = "compact_memory", +diff --git a/mm/vmscan.c b/mm/vmscan.c +index 30a88b945a44..1198e74d1860 100644 +--- a/mm/vmscan.c ++++ b/mm/vmscan.c +@@ -3525,7 +3525,6 @@ void wakeup_kswapd(struct zone *zone, int order, enum zone_type classzone_idx) + wake_up_interruptible(&pgdat->kswapd_wait); + } + +-#ifdef CONFIG_HIBERNATION + /* + * Try to free `nr_to_reclaim' of memory, system-wide, and return the number of + * freed pages. +@@ -3564,7 +3563,6 @@ unsigned long shrink_all_memory(unsigned long nr_to_reclaim) + + return nr_reclaimed; + } +-#endif /* CONFIG_HIBERNATION */ + + /* It's optimal to keep kswapds on the same CPUs as their memory, but + not required for correctness. So if the last cpu in a node goes +-- +2.12.1 + diff --git a/patches/boot_time_opt_guest/guest_boot_time_opt.scc b/patches/boot_time_opt_guest/guest_boot_time_opt.scc new file mode 100644 index 0000000..3636c01 --- /dev/null +++ b/patches/boot_time_opt_guest/guest_boot_time_opt.scc @@ -0,0 +1,19 @@ +define KFEATURE_DESCRIPTION "Boot time optimization changes ported from ClearLinux , https://github.com/clearlinux-pkgs/linux-kvm" +define KFEATURE_COMPATIBILITY all + +patch 0103-sysrq-skip-synchronize_rcu-if-there-is-no-old-op.patch +patch 0104-fbcon-enable-no-blink-by-default.patch +patch 0105-vmstats-wakeups.patch +# Remove patch because it causes ixgvbevf to not initialize correctly in the guest +#patch 0106-pci-probe.patch +patch 0107-cgroup.patch +patch 0108-smpboot-reuse-timer-calibration.patch +patch 0109-perf.patch +patch 0110-pci-probe-identify-known-devices.patch +patch 0111-init-no-wait-for-the-known-devices.patch +patch 0112-ksm-wakeups.patch + +patch 0151-mm-Export-do_madvise.patch +patch 0152-x86-kvm-Notify-host-to-release-pages.patch +patch 0153-x86-Return-memory-from-guest-to-host-kernel.patch +patch 0154-sysctl-vm-Fine-grained-cache-shrinking.patch diff --git a/pci/pci_iov_m.cfg b/pci/pci_iov_m.cfg new file mode 100644 index 0000000..c52af46 --- /dev/null +++ b/pci/pci_iov_m.cfg @@ -0,0 +1 @@ +CONFIG_PCI_IOV=y diff --git a/pci/pci_iov_m.scc b/pci/pci_iov_m.scc new file mode 100644 index 0000000..1612c3c --- /dev/null +++ b/pci/pci_iov_m.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Enable PCI I/O access" +define KFEATURE_COMPATIBILITY board + +kconf non-hardware pci_iov_m.cfg diff --git a/pci/pci_iov_y.cfg b/pci/pci_iov_y.cfg new file mode 100644 index 0000000..c52af46 --- /dev/null +++ b/pci/pci_iov_y.cfg @@ -0,0 +1 @@ +CONFIG_PCI_IOV=y diff --git a/pci/pci_iov_y.scc b/pci/pci_iov_y.scc new file mode 100644 index 0000000..685f058 --- /dev/null +++ b/pci/pci_iov_y.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Enable PCI I/O access" +define KFEATURE_COMPATIBILITY board + +kconf non-hardware pci_iov_y.cfg diff --git a/pcimodules/pcimodules_n.cfg b/pcimodules/pcimodules_n.cfg new file mode 100644 index 0000000..48fa2a1 --- /dev/null +++ b/pcimodules/pcimodules_n.cfg @@ -0,0 +1,19 @@ +CONFIG_PCI_CNB20LE_QUIRK=n +CONFIG_HOTPLUG_PCI_PCIE=n +CONFIG_PCIEASPM_DEBUG=n +CONFIG_PCI_DEBUG=n +CONFIG_PCI_REALLOC_ENABLE_AUTO=n +CONFIG_PCI_STUB=m +CONFIG_PCI_PRI=n +CONFIG_HOTPLUG_PCI=n +CONFIG_HOTPLUG_PCI_ACPI=n +# CONFIG_HOTPLUG_PCI_ACPI_IBM is not set +CONFIG_HOTPLUG_PCI_CPCI=n +# CONFIG_HOTPLUG_PCI_CPCI_ZT5550 is not set +# CONFIG_HOTPLUG_PCI_CPCI_GENERIC is not set +# CONFIG_HOTPLUG_PCI_SHPC is not set +# +# PCI host controller drivers +# +CONFIG_PCIE_DW_PLAT=n +CONFIG_PCIE_DW=n diff --git a/pcimodules/pcimodules_n.scc b/pcimodules/pcimodules_n.scc new file mode 100644 index 0000000..6cad0c5 --- /dev/null +++ b/pcimodules/pcimodules_n.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Disable pcimodules support" +define KFEATURE_COMPATIBILITY all + +kconf non-hardware pcimodules_n.cfg diff --git a/perf/perf_n.cfg b/perf/perf_n.cfg new file mode 100644 index 0000000..8392495 --- /dev/null +++ b/perf/perf_n.cfg @@ -0,0 +1,2 @@ +CONFIG_CGROUP_PERF=n +CONFIG_PERF_EVENTS=n diff --git a/perf/perf_n.scc b/perf/perf_n.scc new file mode 100644 index 0000000..4c5ebaf --- /dev/null +++ b/perf/perf_n.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Disable options required for perf support" +define KFEATURE_COMPATIBILITY all + +kconf non-hardware perf_n.cfg diff --git a/power_supply/power_supply_n.cfg b/power_supply/power_supply_n.cfg new file mode 100644 index 0000000..92dec05 --- /dev/null +++ b/power_supply/power_supply_n.cfg @@ -0,0 +1 @@ +ONFIG_POWER_SUPPLY=n diff --git a/power_supply/power_supply_n.scc b/power_supply/power_supply_n.scc new file mode 100644 index 0000000..81bce6b --- /dev/null +++ b/power_supply/power_supply_n.scc @@ -0,0 +1,5 @@ +define KFEATURE_DESCRIPTION "Disable power supply support" + +define KFEATURE_COMPATIBILITY all + +kconf hardware power_supply_n.cfg diff --git a/ppp/ppp_n.cfg b/ppp/ppp_n.cfg new file mode 100644 index 0000000..04d84a8 --- /dev/null +++ b/ppp/ppp_n.cfg @@ -0,0 +1,10 @@ +CONFIG_PPP=n +CONFIG_PPP_BSDCOMP=n +CONFIG_PPP_DEFLATE=n +CONFIG_PPP_FILTER=n +# CONFIG_PPP_MPPE is not set +CONFIG_PPP_MULTILINK=n +CONFIG_PPPOE=n +# CONFIG_PPTP is not set +CONFIG_PPP_ASYNC=n +CONFIG_PPP_SYNC_TTY=n diff --git a/ppp/ppp_n.scc b/ppp/ppp_n.scc new file mode 100644 index 0000000..3d6a8db --- /dev/null +++ b/ppp/ppp_n.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Disable ppp support" +define KFEATURE_COMPATIBILITY all + +kconf non-hardware ppp_n.cfg diff --git a/prockcore/prockcore_n.cfg b/prockcore/prockcore_n.cfg new file mode 100644 index 0000000..aa9e6a4 --- /dev/null +++ b/prockcore/prockcore_n.cfg @@ -0,0 +1 @@ +CONFIG_PROC_KCORE=n diff --git a/prockcore/prockcore_n.scc b/prockcore/prockcore_n.scc new file mode 100644 index 0000000..a2651b5 --- /dev/null +++ b/prockcore/prockcore_n.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Disable prockcore support" +define KFEATURE_COMPATIBILITY all + +kconf non-hardware prockcore_n.cfg diff --git a/reduced_kernel_footprint_guest/reduced_kernel_footprint_guest.scc b/reduced_kernel_footprint_guest/reduced_kernel_footprint_guest.scc new file mode 100644 index 0000000..7fae6cd --- /dev/null +++ b/reduced_kernel_footprint_guest/reduced_kernel_footprint_guest.scc @@ -0,0 +1,75 @@ +# Add standard kernel configuration and XZ kernel compression +include features/std_kernel/std_kernel_y.scc + +# Disable unnecessary modules +include features/bcma/bcma_n.scc +include features/btrfs/btrfs_n.scc +include features/compilechecks/compilechecks_n.scc +include features/i2csupport/i2csupport_n.scc +include features/isdn/isdn_n.scc +include features/loopdev/loopdev_n.scc +include features/msdos_fat_nt_fs/msdos_fat_nt_fs_n.scc +include features/netblkdev/netblkdev_n.scc +include features/netconsole/netconsole_n.scc +include features/netfilter/netfilter_n.scc +include features/nfs/nfs_n.scc +include features/parport/parport_n.scc +include features/pcimodules/pcimodules_n.scc +include features/ppp/ppp_n.scc +include features/prockcore/prockcore_n.scc +include features/serio/serio_n.scc +include features/slip/slip_n.scc +include features/bug_support/bug_support_n.scc +include features/powermanagement/powermanagement_n.scc +include features/acpi/acpi_n.scc +include features/cpu_freq/cpu_freq_n.scc +include features/bluetooth/bluetooth_n.scc +include features/wireless/wireless_n.scc +include features/rfkill/rfkill_n.scc +include features/6lowpan/6lowpan_n.scc +include features/netdevices/netdevices_n.scc +include features/media/media_n.scc +include features/nfc/nfc_n.scc +include features/sound/sound_n.scc +include features/usbnet/usbnet_n.scc +include features/i2csupport/i2csupport_n.scc +include features/serio/serio_n.scc +include features/tablet/tablet_n.scc +include features/mouse/mouse_n.scc +include features/mousedev/mousedev_n.scc +include features/keyboard/keyboard_n.scc +include features/input/input_n.scc +include features/wlan/wlan_n.scc +include features/ftrace/ftrace_n.scc +include features/debug/debug_kernel_n.scc +include features/ata/ata_n.scc +include features/cdrom/cdrom_n.scc +include features/power_supply/power_supply_n.scc +include features/hwmon/hwmon_n.scc +include features/thermal/thermal_n.scc +include features/usbsupport/usbsupport_n.scc +include features/touchscreen/touchscreen_n.scc +include features/udev/udev_n.scc +include features/kprobes/kprobes_n.scc +include features/acp/acp_n.scc +include features/agp/agp_n.scc +include features/backlight/backlight_n.scc +include features/cdrom_fs/cdrom_fs_n.scc +include features/cgroupdbg/cgroupdbg_n.scc +include features/display/display_n.scc +include features/drm/drm_n.scc +include features/elf_core_support/elf_core_support_n.scc +include features/framebuffer/framebuffer_n.scc +include features/hdmi/hdmi_n.scc +include features/hid/hid_n.scc +include features/kprobes/kprobes_n.scc +include features/mmc/mmc_n.scc +include features/pcspkr/pcspkr_n.scc +include features/watchdog/watchdog_n.scc +include features/vga/vga_n.scc +include features/intel-e1xxxx/e100_n.scc +include features/x86_platform/x86_platform_n.scc +include features/memorydbg/memorydbg_n.scc +include features/perf/perf_n.cfg +include features/kgdb/kgdb_n.cfg +include features/dmiid/dmiid_n.cfg diff --git a/serio/serio_n.cfg b/serio/serio_n.cfg new file mode 100644 index 0000000..c505fdd --- /dev/null +++ b/serio/serio_n.cfg @@ -0,0 +1,15 @@ +# +# Hardware I/O ports +# +CONFIG_SERIO=n +CONFIG_ARCH_MIGHT_HAVE_PC_SERIO=n +CONFIG_SERIO_I8042=n +CONFIG_SERIO_SERPORT=n +# CONFIG_SERIO_CT82C710 is not set +# CONFIG_SERIO_PCIPS2 is not set +# CONFIG_SERIO_LIBPS2 is not set +# CONFIG_SERIO_RAW is not set +# CONFIG_SERIO_ALTERA_PS2 is not set +# CONFIG_SERIO_PS2MULT is not set +# CONFIG_SERIO_ARC_PS2 is not set +# CONFIG_USERIO is not set diff --git a/serio/serio_n.scc b/serio/serio_n.scc new file mode 100644 index 0000000..389bf1e --- /dev/null +++ b/serio/serio_n.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Disable serio support" +define KFEATURE_COMPATIBILITY all + +kconf non-hardware serio_n.cfg diff --git a/slip/slip_n.cfg b/slip/slip_n.cfg new file mode 100644 index 0000000..b5cbd33 --- /dev/null +++ b/slip/slip_n.cfg @@ -0,0 +1,5 @@ +CONFIG_SLIP=n +CONFIG_SLHC=n +CONFIG_SLIP_COMPRESSED=n +CONFIG_SLIP_SMART=n +CONFIG_SLIP_MODE_SLIP6=n diff --git a/slip/slip_n.scc b/slip/slip_n.scc new file mode 100644 index 0000000..27b54c8 --- /dev/null +++ b/slip/slip_n.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Disable slip support" +define KFEATURE_COMPATIBILITY all + +kconf non-hardware slip_n.cfg diff --git a/thermal/thermal_n.cfg b/thermal/thermal_n.cfg new file mode 100644 index 0000000..faa4970 --- /dev/null +++ b/thermal/thermal_n.cfg @@ -0,0 +1,4 @@ +CONFIG_THERMAL=n +CONFIG_THERMAL_WRITABLE_TRIPS=n +CONFIG_THERMAL_GOV_USER_SPACE=n +CONFIG_X86_PKG_TEMP_THERMAL=n diff --git a/thermal/thermal_n.scc b/thermal/thermal_n.scc new file mode 100644 index 0000000..cccc945 --- /dev/null +++ b/thermal/thermal_n.scc @@ -0,0 +1,5 @@ +define KFEATURE_DESCRIPTION "Disable thermal sysfs support" + +define KFEATURE_COMPATIBILITY all + +kconf hardware thermal_n.cfg diff --git a/udev/udev.cfg b/udev/udev.cfg new file mode 100644 index 0000000..08dc3b0 --- /dev/null +++ b/udev/udev.cfg @@ -0,0 +1,28 @@ +CONFIG_DEVTMPFS=y +CONFIG_CGROUPS=y +CONFIG_INOTIFY_USER=y +CONFIG_SIGNALFD=y +CONFIG_TIMERFD=y +CONFIG_EPOLL=y +CONFIG_NET=y +CONFIG_SYSFS=y +CONFIG_PROC_FS=y +CONFIG_FHANDLE=y + +CONFIG_SYSFS_DEPRECATED=n + +CONFIG_UEVENT_HELPER_PATH="" + +CONFIG_FW_LOADER_USER_HELPER=n + +CONFIG_DMIID=y + +CONFIG_BLK_DEV_BSG=y + +CONFIG_NET_NS=y +CONFIG_DEVPTS_MULTIPLE_INSTANCES=y +CONFIG_USER_NS=y + +CONFIG_CGROUP_SCHED=y +CONFIG_FAIR_GROUP_SCHED=y +CONFIG_CFS_BANDWIDTH=y diff --git a/udev/udev.scc b/udev/udev.scc new file mode 100644 index 0000000..089ca2e --- /dev/null +++ b/udev/udev.scc @@ -0,0 +1,7 @@ +define KFEATURE_DESCRIPTION "UDEV specific kernel configs: https://github.com/systemd/systemd/blob/master/README" +define KFEATURE_COMPATIBILITY all + +kconf non-hardware udev.cfg +kconf non-hardware udev_crypto.cfg +kconf non-hardware udev_uefi.cfg +kconf non-hardware udev_opt.cfg diff --git a/udev/udev_crypto.cfg b/udev/udev_crypto.cfg new file mode 100644 index 0000000..1e0be79 --- /dev/null +++ b/udev/udev_crypto.cfg @@ -0,0 +1,3 @@ +CONFIG_CRYPTO_USER_API_HASH=y +CONFIG_CRYPTO_HMAC=y +CONFIG_CRYPTO_SHA256=y diff --git a/udev/udev_crypto.scc b/udev/udev_crypto.scc new file mode 100644 index 0000000..9c019a6 --- /dev/null +++ b/udev/udev_crypto.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "UDEV kernels config to support crypto" +define KFEATURE_COMPATIBILITY all + +kconf non-hardware udev_crypto.cfg diff --git a/udev/udev_n.cfg b/udev/udev_n.cfg new file mode 100644 index 0000000..ef9e6d4 --- /dev/null +++ b/udev/udev_n.cfg @@ -0,0 +1 @@ +CONFIG_UEVENT_HELPER=n diff --git a/udev/udev_n.scc b/udev/udev_n.scc new file mode 100644 index 0000000..bfaa194 --- /dev/null +++ b/udev/udev_n.scc @@ -0,0 +1,5 @@ +define KFEATURE_DESCRIPTION "Disable udev support" + +define KFEATURE_COMPATIBILITY all + +kconf hardware udev_n.cfg diff --git a/udev/udev_opt.cfg b/udev/udev_opt.cfg new file mode 100644 index 0000000..d08e36a --- /dev/null +++ b/udev/udev_opt.cfg @@ -0,0 +1,10 @@ +CONFIG_IPV6=y +CONFIG_AUTOFS4_FS=y +CONFIG_TMPFS_XATTR=y +CONFIG_TMPFS_POSIX_ACL=y +CONFIG_EXT4_POSIX_ACL=y +CONFIG_XFS_ACL=y +CONFIG_BTRFS_FS_POSIX_ACL=y +CONFIG_SECCOMP=y +CONFIG_SECCOMP_FILTER=y +CONFIG_CHECKPOINT_RESTORE=y diff --git a/udev/udev_opt.scc b/udev/udev_opt.scc new file mode 100644 index 0000000..dc1b86a --- /dev/null +++ b/udev/udev_opt.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "Optional UDEV kernel configs" +define KFEATURE_COMPATIBILITY all + +kconf non-hardware udev_opt.cfg diff --git a/udev/udev_uefi.cfg b/udev/udev_uefi.cfg new file mode 100644 index 0000000..ec2aa3e --- /dev/null +++ b/udev/udev_uefi.cfg @@ -0,0 +1,2 @@ +CONFIG_EFIVAR_FS=y +CONFIG_EFI_PARTITION=y diff --git a/udev/udev_uefi.scc b/udev/udev_uefi.scc new file mode 100644 index 0000000..bda289e --- /dev/null +++ b/udev/udev_uefi.scc @@ -0,0 +1,4 @@ +define KFEATURE_DESCRIPTION "kernel configs for UDEV with UEFI support" +define KFEATURE_COMPATIBILITY all + +kconf non-hardware udev_uefi.cfg diff --git a/vga/vga_n.cfg b/vga/vga_n.cfg new file mode 100644 index 0000000..cc679da --- /dev/null +++ b/vga/vga_n.cfg @@ -0,0 +1 @@ +CONFIG_VGA_ARB=n diff --git a/vga/vga_n.scc b/vga/vga_n.scc new file mode 100644 index 0000000..2b9e2c1 --- /dev/null +++ b/vga/vga_n.scc @@ -0,0 +1,5 @@ +define KFEATURE_DESCRIPTION "Disable VGA" + +define KFEATURE_COMPATIBILITY all + +kconf hardware vga_n.cfg diff --git a/watchdog/watchdog_n.cfg b/watchdog/watchdog_n.cfg new file mode 100644 index 0000000..3d103ce --- /dev/null +++ b/watchdog/watchdog_n.cfg @@ -0,0 +1 @@ +CONFIG_WATCHDOG=n diff --git a/watchdog/watchdog_n.scc b/watchdog/watchdog_n.scc new file mode 100644 index 0000000..d394a3d --- /dev/null +++ b/watchdog/watchdog_n.scc @@ -0,0 +1,5 @@ +define KFEATURE_DESCRIPTION "Disable watchdog support" + +define KFEATURE_COMPATIBILITY all + +kconf hardware watchdog_n.cfg diff --git a/x86_platform/x86_platform_n.cfg b/x86_platform/x86_platform_n.cfg new file mode 100644 index 0000000..2a96aa9 --- /dev/null +++ b/x86_platform/x86_platform_n.cfg @@ -0,0 +1 @@ +CONFIG_X86_PLATFORM_DEVICES=n diff --git a/x86_platform/x86_platform_n.scc b/x86_platform/x86_platform_n.scc new file mode 100644 index 0000000..a224808 --- /dev/null +++ b/x86_platform/x86_platform_n.scc @@ -0,0 +1,5 @@ +define KFEATURE_DESCRIPTION "Disable x86 platform devices" + +define KFEATURE_COMPATIBILITY all + +kconf hardware x86_platform_n.cfg -- cgit v1.2.3-54-g00ecf