sys-kernel/gentoo-kernel: Bump to 5.4.71

Signed-off-by: Michał Górny <mgorny@gentoo.org>
This commit is contained in:
Michał Górny
2020-10-15 14:39:19 +02:00
parent 3a365d53e9
commit 9d7068c76d
2 changed files with 139 additions and 0 deletions
+2
View File
@@ -8,6 +8,8 @@ DIST genpatches-5.4-70.base.tar.xz 2483716 BLAKE2B ec87f655614a22728baa721a29161
DIST genpatches-5.4-70.extras.tar.xz 1772 BLAKE2B b7dcaf96dabb3dcb2ffac6532b59b9eff8e9e55e309b02b4d774a3c665e4499f0353bfb91ed81f1cbc73b852f0de50adc6a03dc36e8e7beb88f0cf62a5fd9a42 SHA512 3fedd41a60c6941f9ee18485c92b67c3dc69d0b36a134adb89c246106d043e10afcc9114f5448ea4164b956934e2dc9efb1f3af95c2bd1a67eaeef5253b07630
DIST genpatches-5.4-71.base.tar.xz 2499052 BLAKE2B f19927e24c884ed8849b9572b5d199d8e9d1ad57137af70658016cee341e4a45d0e974996138c61880c39adb83616d6399e798e5fdd020c6275becd57a9d56b3 SHA512 dad3be3fa63d809458b08b7da7f45c2a0c126ca1df75ed156b2f54a93204b4504d42e678a74df79618e137b7b565fbc97e108e2807c97cd1b4a8d0bec69151a4
DIST genpatches-5.4-71.extras.tar.xz 1772 BLAKE2B e462c7bf461058db545a11d05d6f6de16d0868a4f162874682425424f07e6b78019ce65ba9bd51aa413433894cea8561cba33837b66dd600351f36c563a0edb0 SHA512 ba9930a24342f7ccb5514688913e2517c726137317563ce301dbf383d484a6243c04e4d7e6ba427c0269009f979aea8c623e677e9d7f763275c1e299519d2ee4
DIST genpatches-5.4-72.base.tar.xz 2519916 BLAKE2B 1998698004dea3a4dfa3866b96937902ca455766129d8e62b627e72f69aae4661abf37e46dfc996dec4232099c77cf910ad6f56baec527990aa94b1eff0c2184 SHA512 f6a48c095635a2fc8fa058ca40fbf272768da52993d924669544ff73d0c8b8f0d1bccabdbaaa5c8c1092a69008a1d527e9613a8c6862b55832738c0a80d55302
DIST genpatches-5.4-72.extras.tar.xz 1768 BLAKE2B 8a25411510431be8515a339398b5d8d43d7739089f62c1e8158ca79ac793e7bfacc39b8e43d2f5e2667125ae7342bc943480804dd7b63df3e42400d9b662133b SHA512 955413633bcc16fe215e9769cec6dce68c3d8faf13659342db6a795d3e042ecccff9a6722cdb0abc87220ca301caeaccb6f25588f19da44642e358a8dee46916
DIST genpatches-5.8-15.base.tar.xz 498912 BLAKE2B 429c079f836b9dc6d2086fe818f4e705264f002bcfcf4e5bdbe144af53aca53c8bfc1c0ac23aa33939bc59111e2194747088bbccff61015fd59ac0e3150aab62 SHA512 936414eaaa159a84bf016080332a8ba29c2024c02e5b83ed559df7b1a910ba405093e5ed36d54a346091a534f1389eba99b95852b23328a92e2f7ba5b07723ee
DIST genpatches-5.8-15.extras.tar.xz 1772 BLAKE2B 690935cb537f442dd48dea34000bc444b9c2861b259ebb156722f1027ba281111b037fafe4cfdb71e68c40603f2dcb27d2639d949d4e4fbada8811fce2716329 SHA512 8dcc4ebb194603036323dcc559b5827d02c6a678b2f162191e306fe6ae52cc860e651937962ac8b52e2a4e229b1326a2cb24f938638556b0ddf4369f140f997b
DIST genpatches-5.8-16.base.tar.xz 525416 BLAKE2B 53b0e2548b25b93999650cdf8eb920447367305049349a468b954f84368f803d2e1fd591fe4c01722515568257f1457a7480650a2debb1e9196bc41cebc07b5c SHA512 b708d0ad5303cabd7ba73b28391c138bf443c0af1dfc8296eb528e1a16cf00763a5a36aec1cb7bd0b0e9c9b0d844d4a135e2f1f5cf4ddbfa9742d7e05e0a4c0d
@@ -0,0 +1,137 @@
# Copyright 2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
inherit kernel-build
MY_P=linux-${PV%.*}
GENPATCHES_P=genpatches-${PV%.*}-$(( ${PV##*.} + 1 ))
# https://koji.fedoraproject.org/koji/packageinfo?packageID=8
CONFIG_VER=5.4.21
CONFIG_HASH=2809b7faa6a8cb232cd825096c146b7bdc1e08ea
DESCRIPTION="Linux kernel built with Gentoo patches"
HOMEPAGE="https://www.kernel.org/"
SRC_URI+=" https://cdn.kernel.org/pub/linux/kernel/v$(ver_cut 1).x/${MY_P}.tar.xz
https://dev.gentoo.org/~mpagano/dist/genpatches/${GENPATCHES_P}.base.tar.xz
https://dev.gentoo.org/~mpagano/dist/genpatches/${GENPATCHES_P}.extras.tar.xz
amd64? (
https://src.fedoraproject.org/rpms/kernel/raw/${CONFIG_HASH}/f/kernel-x86_64.config
-> kernel-x86_64.config.${CONFIG_VER}
)
arm64? (
https://src.fedoraproject.org/rpms/kernel/raw/${CONFIG_HASH}/f/kernel-aarch64.config
-> kernel-aarch64.config.${CONFIG_VER}
)
ppc64? (
https://src.fedoraproject.org/rpms/kernel/raw/${CONFIG_HASH}/f/kernel-ppc64le.config
-> kernel-ppc64le.config.${CONFIG_VER}
)
x86? (
https://src.fedoraproject.org/rpms/kernel/raw/${CONFIG_HASH}/f/kernel-i686.config
-> kernel-i686.config.${CONFIG_VER}
)"
S=${WORKDIR}/${MY_P}
LICENSE="GPL-2"
KEYWORDS="~amd64 ~arm64 ~ppc64 ~x86"
IUSE="debug"
RDEPEND="
!sys-kernel/vanilla-kernel:${SLOT}
!sys-kernel/vanilla-kernel-bin:${SLOT}"
BDEPEND="
debug? ( dev-util/dwarves )"
pkg_pretend() {
ewarn "Starting with 5.4.52, Distribution Kernels are switching from Arch"
ewarn "Linux configs to Fedora. Please keep a backup kernel just in case."
kernel-install_pkg_pretend
}
src_prepare() {
local PATCHES=(
# meh, genpatches have no directory
"${WORKDIR}"/*.patch
)
default
# prepare the default config
case ${ARCH} in
amd64)
cp "${DISTDIR}/kernel-x86_64.config.${CONFIG_VER}" .config || die
;;
arm64)
cp "${DISTDIR}/kernel-aarch64.config.${CONFIG_VER}" .config || die
;;
ppc64)
cp "${DISTDIR}/kernel-ppc64le.config.${CONFIG_VER}" .config || die
;;
x86)
cp "${DISTDIR}/kernel-i686.config.${CONFIG_VER}" .config || die
;;
*)
die "Unsupported arch ${ARCH}"
;;
esac
local config_tweaks=(
# replace (none) with gentoo
-e 's:^CONFIG_DEFAULT_HOSTNAME=:&"gentoo":'
# we do support x32
-e '/CONFIG_X86_X32/s:.*:CONFIG_X86_X32=y:'
# disable signatures
-e '/CONFIG_MODULE_SIG/d'
-e '/CONFIG_SECURITY_LOCKDOWN/d'
-e '/CONFIG_KEXEC_SIG/d'
-e '/CONFIG_KEXEC_BZIMAGE_VERIFY_SIG/d'
-e '/CONFIG_SYSTEM_EXTRA_CERTIFICATE/d'
-e '/CONFIG_SIGNATURE/d'
# remove massive array of LSMs
-e 's/CONFIG_LSM=.*/CONFIG_LSM="yama"/'
-e 's/CONFIG_DEFAULT_SECURITY_SELINUX=y/CONFIG_DEFAULT_SECURITY_DAC=y/'
# nobody actually wants fips
-e '/CONFIG_CRYPTO_FIPS/d'
# these tests are really not necessary
-e 's/.*CONFIG_CRYPTO_MANAGER_DISABLE_TESTS.*/CONFIG_CRYPTO_MANAGER_DISABLE_TESTS=y/'
# probably not needed by anybody but developers
-e '/CONFIG_CRYPTO_STATS/d'
# 1000hz is excessive for laptops
-e 's/CONFIG_HZ_1000=y/CONFIG_HZ_300=y/'
# nobody is using this kernel on insane super computers
-e 's/CONFIG_NR_CPUS=.*/CONFIG_NR_CPUS=512/'
# we're not actually producing live patches for folks
-e 's/CONFIG_LIVEPATCH=y/CONFIG_LIVEPATCH=n/'
# this slows down networking in general
-e 's/CONFIG_IP_FIB_TRIE_STATS=y/CONFIG_IP_FIB_TRIE_STATS=n/'
# include font for normal and hidpi screens
-e 's/.*CONFIG_FONTS.*/CONFIG_FONTS=y\nCONFIG_FONT_8x16=y\nCONFIG_FONT_TER16x32=y/'
# we don't need to actually install system headers from this ebuild
-e '/CONFIG_HEADERS_INSTALL/d'
# enable /proc/config.gz, used by linux-info.eclass
-e '/CONFIG_IKCONFIG/s:.*:CONFIG_IKCONFIG=y\nCONFIG_IKCONFIG_PROC=y:'
# WireGuard was backported to 5.4 but we use old configs (#739128)
-e '$aCONFIG_WIREGUARD=m'
)
use debug || config_tweaks+=(
-e '/CONFIG_DEBUG_INFO/d'
-e '/CONFIG_DEBUG_RODATA_TEST/d'
-e '/CONFIG_DEBUG_VM/d'
-e '/CONFIG_DEBUG_SHIRQ/d'
-e '/CONFIG_DEBUG_LIST/d'
-e '/CONFIG_BUG_ON_DATA_CORRUPTION/d'
-e '/CONFIG_TORTURE_TEST/d'
-e '/CONFIG_BOOTTIME_TRACING/d'
-e '/CONFIG_RING_BUFFER_BENCHMARK/d'
-e '/CONFIG_X86_DECODER_SELFTEST/d'
-e '/CONFIG_KGDB/d'
)
[[ ${ARCH} == x86 ]] && config_tweaks+=(
# fix autoenabling 64bit
-e '2i\
# CONFIG_64BIT is not set'
)
sed -i "${config_tweaks[@]}" .config || die
}