[kernel-rt 4.18] Upgrade kernel-rt to version 4.18.0-147.3.1 based on SRPM

Story: 2007308
Task: 38795
Depends-On: https://review.opendev.org/#/c/722017/
Depends-On: https://review.opendev.org/#/c/722019/
Change-Id: I942b2aa6167120157a38af83135ed358b17ee78b
Signed-off-by: Dongqi Chen <chen.dq@neusoft.com>
This commit is contained in:
Dongqi Chen 2020-04-23 17:43:26 +08:00
parent f6ed6f5843
commit c0fee2da8e
50 changed files with 1576 additions and 6359 deletions

View File

@ -1 +0,0 @@
kernel-rt-3.10.0-1062.1.2.rt56.1025.el7.src.rpm

View File

@ -1,4 +1,4 @@
COPY_LIST="files/*" COPY_LIST="files/*"
TIS_PATCH_VER=5 TIS_PATCH_VER=1
BUILD_IS_BIG=11 BUILD_IS_BIG=21
BUILD_IS_SLOW=12 BUILD_IS_SLOW=16

View File

@ -5,525 +5,254 @@ Subject: [PATCH] Build logic and sources for TiC
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com> Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
Signed-off-by: Robin Lu <bin1.lu@intel.com> Signed-off-by: Robin Lu <bin1.lu@intel.com>
Signed-off-by: Dongqi Chen <chen.dq@neusoft.com>
--- ---
SPECS/kernel-rt.spec | 279 ++++++++++++++++++++++++++++++++++++++++++- SPECS/kernel-rt.spec | 87 ++++++++++++++++++++++++++++++++--------------------
1 file changed, 273 insertions(+), 6 deletions(-) 1 file changed, 53 insertions(+), 34 deletions(-)
diff --git a/SPECS/kernel-rt.spec b/SPECS/kernel-rt.spec diff --git a/SPECS/kernel-rt.spec b/SPECS/kernel-rt.spec
index a922773..adffde2 100644 index f9cfea3..4930a83 100644
--- a/SPECS/kernel-rt.spec --- a/SPECS/kernel-rt.spec
+++ b/SPECS/kernel-rt.spec +++ b/SPECS/kernel-rt.spec
@@ -17,23 +17,33 @@ Summary: The Linux Realtime kernel @@ -36,9 +36,9 @@ Summary: The Linux kernel
%define pkgrelease 147.3.1.rt24.96.el8_1
# The Build ID # allow pkg_release to have configurable %%{?dist} tag
# %%define buildid .local -%define specrelease 147.3.1.rt24.96%{?dist}
+%define buildid .tis.%{tis_patch_ver} +%define specrelease 147.3.1.rt24.96.el8_1
# For a kernel released for public testing, released_kernel should be 1. -%define pkg_release %{specrelease}%{?buildid}
# For internal testing builds during development, it should be 0. +%define pkg_release %{specrelease}%{?buildid}%{?_tis_dist}.%{tis_patch_ver}
%global released_kernel 1
+# If we want to sign the kernel and modules, do_sign should be 1.
+# To speed up builds (don't sign) use 0.
+%global do_sign 1
+
# conditional with/without variables
# Note that the logic here is inverted; a bcond_without implies
# that the variable is on by default (since you use --without to turn it off)
# Likewise a bcond_with implies the variable is off by default (turned on by --with)
%bcond_without rt
%bcond_without doc
-%bcond_without debug
-%bcond_with headers
+%bcond_with debug
+%bcond_without headers
%bcond_with vanilla
-%bcond_without trace
+%bcond_with trace
%bcond_with perf
-%bcond_without debuginfo
+%bcond_with debuginfo
+%bcond_without tools
+
+# Architectures we build tools/cpupower on
+%define cpupowerarchs x86_64 ppc64 ppc64le
+
# What parts do we want to build? We must build at least one kernel. # What parts do we want to build? We must build at least one kernel.
# These are the kernels that are built IF the architecture allows it. # These are the kernels that are built IF the architecture allows it.
@@ -53,7 +63,11 @@ Summary: The Linux Realtime kernel @@ -46,6 +46,7 @@ Summary: The Linux kernel
# Verbose output? # by later arch-specific checks.
# %%global verbose V=1
+%if %{do_sign} %define _with_kabidupchk 1
%global signmodules 1 +%define _with_tools 1
+%else # The following build options are enabled by default.
+%global signmodules 0 # Use either --without <opt> in your rpmbuild command or force values
+%endif # to 0 in here to disable them.
@@ -54,6 +55,8 @@ Summary: The Linux kernel
# if patch fuzzy patch applying will be forbidden %define with_up %{?_without_up: 0} %{?!_without_up: 1}
%global with_fuzzy_patches 0 # kernel-debug
@@ -84,7 +98,7 @@ Summary: The Linux Realtime kernel %define with_debug %{?_without_debug: 0} %{?!_without_debug: 1}
%global with_sparse %{?_with_sparse: 1} %{?!_with_sparse: 0} +# STX: disable debug build
+%define with_debug 0
%global pkg_release_simple %{rhel_build}.%{rttag}.%{rtbuild} # kernel-headers
-%global pkg_release %{rhel_build}.%{rttag}.%{rtbuild}%{?buildid}%{?dist} # realtime
+%global pkg_release %{pkg_release_simple}%{?dist}%{?buildid} %define with_realtime %{?_without_realtime: 0} %{?!_without_realtime: 1}
@@ -67,6 +70,8 @@ Summary: The Linux kernel
%global KVERREL %{rpmversion}-%{pkg_release}.%{_target_cpu} %define with_bpftool %{?_without_bpftool: 0} %{?!_without_bpftool: 1}
# kernel-debuginfo
@@ -290,9 +304,14 @@ BuildRequires: xmlto, asciidoc %define with_debuginfo %{?_without_debuginfo: 0} %{?!_without_debuginfo: 1}
BuildRequires: openssl +# STX: disable debuginfo
BuildRequires: hmaccalc +%define with_debuginfo 0
BuildRequires: elfutils-libelf-devel # Want to build a the vsdo directories installed
+%if %{do_sign} %define with_vdso_install %{?_without_vdso_install: 0} %{?!_without_vdso_install: 1}
%ifarch x86_64 # kernel-zfcpdump (s390 specific kernel for zfcpdump)
BuildRequires: pesign >= 0.109-4 @@ -126,10 +131,11 @@ Summary: The Linux kernel
%endif %global rttag .rt24
+%endif # realtimeN
+%if %{with_tools} %global rtbuild .96
+BuildRequires: pciutils-devel gettext ncurses-devel -%define with_headers 0
+%endif +%define with_headers 1
%define with_cross_headers 0
%define with_perf 0
-%define with_tools 0
+# generate kernel-rt-tools
+%define with_tools 1
%define with_bpftool 0
%define with_zfcpdump 0
%define with_kabichk 0
@@ -291,7 +297,7 @@ Requires: rt-setup
#
BuildRequires: kmod, patch, bash, tar, git
BuildRequires: bzip2, xz, findutils, gzip, m4, perl-interpreter, perl-Carp, perl-devel, perl-generators, make, diffutils, gawk
-BuildRequires: gcc, binutils, redhat-rpm-config, hmaccalc, python3-devel
+BuildRequires: gcc, binutils, redhat-rpm-config, hmaccalc, python2-devel
BuildRequires: net-tools, hostname, bc, bison, flex, elfutils-devel
%if %{with_sparse} %if %{with_sparse}
BuildRequires: sparse >= 0.4.1 BuildRequires: sparse
@@ -357,6 +363,7 @@ BuildRequires: xmlto
%if %{with_perf} || %{with_tools}
BuildRequires: asciidoc
%endif %endif
@@ -340,6 +359,13 @@ Source25: merge.pl +BuildRequires: kernel-headers
Source27: sanity_check.py
Source29: extrakeys.pub
+Source37: centos.cer Source0: linux-%{rpmversion}-%{pkgrelease}.tar.xz
+Source38: ima_signing_key.pub
+%if %{?released_kernel}
+%define pesign_name redhatsecureboot301
+%else
+%define pesign_name redhatsecureboot003
+%endif
### Configuration files @@ -417,6 +424,12 @@ Source301: kernel-kabi-dw-%{rpmversion}-%{distro_build}.tar.bz2
Source50: kernel-%{version}-x86_64-rt.config Source2000: cpupower.service
@@ -352,6 +378,14 @@ Source81: find-debuginfo.sh Source2001: cpupower.config
# Sources for kernel modprobe config files
Source1000: modprobe-dccp-blacklist.conf
+# Sources for kernel-rt-tools +# Sources for stx
+Source2000: cpupower.service +Source3000: centos.cer
+Source2001: cpupower.config
+ +
+Source30000: kernel-3.10.0-x86_64-rt.config.tis_extra +#Stx config
+Source30001: kernel-3.10.0-x86_64-rt-debug.config.tis_extra +Source30000: kernel-rt-4.18.0-x86_64.config.tis_extra
+Source30002: kernel-3.10.0-x86_64-rt-trace.config.tis_extra
+ +
# Empty final patch file to facilitate testing of kernel patches ## Patches needed for building this package
Patch999999: linux-kernel-test.patch
@@ -374,6 +408,7 @@ This kernel has been compiled with the RT patch applied and is intended # END OF PATCH DEFINITIONS
for use in deterministic response-time situations @@ -915,6 +928,7 @@ ApplyOptionalPatch()
+%if %{builddoc}
%package doc
Summary: Various documentation bits found in the kernel source
Group: Documentation
@@ -386,6 +421,7 @@ device drivers shipped with it are documented in these files.
You will want to install this package if you need a reference to the
options that can be passed to Linux kernel modules at load time.
+%endif
%package headers
Summary: Header files for the Linux kernel for use by glibc
@@ -393,6 +429,7 @@ Group: Development/System
Obsoletes: glibc-kernheaders < 3.0-46
Provides: glibc-kernheaders = 3.0-46
Provides: kernel-rt-extras = %{version}-%{release}
+Provides: kernel-headers
%description headers
Kernel-headers includes the C header files that specify the interface
between the Linux kernel and userspace libraries and programs. The
@@ -442,6 +479,7 @@ AutoReq: no\
This package provides KVM modules for package %{name}%{?1:-%{1}}.\
%{nil}
+%if %{builddebuginfo}
#
# This macro creates a kernel-rt-<subpackage>-kvm-debuginfo package.
# %%kernel_kvm_debuginfo_package <subpackage>
@@ -458,7 +496,9 @@ This package provides debug information for package %{name}%{?1:-%{1}}.\
This is required to use SystemTap with %{name}%{?1:-%{1}}-%{KVERREL}.\
%{expand:%%global debuginfo_args %{?debuginfo_args} -p '/.*/%%{KVERREL}%{?1:\.%{1}}/.*|/.*%%{KVERREL}%{?1:\.%{1}}(\.debug)?' -o debuginfo%{?1}-kvm.list}\
%{nil}
+%endif
+%if %{builddebuginfo}
#
# This macro creates a kernel-<subpackage>-debuginfo package.
# %%kernel_debuginfo_package <subpackage>
@@ -476,6 +516,7 @@ This package provides debug information for package %{name}%{?1:-%{1}}.\
This is required to use SystemTap with %{name}%{?1:-%{1}}-%{KVERREL}.\
%{expand:%%global debuginfo_args %{?debuginfo_args} -p '/.*/%%{KVERREL}%{?1:\.%{1}}/.*|/.*%%{KVERREL}%{?1:\.%{1}}(\.debug)?' -o debuginfo%{?1}.list}\
%{nil}
+%endif
#
# This macro creates a kernel-<subpackage>-devel package.
@@ -490,6 +531,7 @@ Provides: kernel-rt-devel = %{version}-%{release}%{?1:.%{1}}\
Provides: kernel-rt%{?1:-%{1}}-devel-%{_target_cpu} = %{version}-%{release}\
Provides: kernel-rt-devel-%{_target_cpu} = %{version}-%{release}%{?1:.%{1}}\
Provides: kernel-rt-devel-uname-r = %{KVERREL}%{?1:.%{1}}\
+Provides: kernel-devel = %{version}-%{release}%{?1:.%{1}}\
AutoReqProv: no\
Requires(pre): /usr/bin/find\
%description -n kernel-rt%{?variant}%{?1:-%{1}}-devel\
@@ -502,6 +544,7 @@ against the %{?2:%{2} }kernel package.\
# %%define variant_summary The Linux kernel compiled for <configuration>
# %%kernel_variant_package [-n <pretty-name>] <subpackage>
#
+%if %{builddebuginfo}
%define kernel_variant_package(n:) \
%package %1\
Summary: %{variant_summary}\
@@ -512,15 +555,29 @@ Group: System Environment/Kernel\
%{expand:%%kernel_kvm_package %1}\
%{expand:%%kernel_kvm_debuginfo_package %1}\
%{nil}
+%else
+%define kernel_variant_package(n:) \
+%package %1\
+Summary: %{variant_summary}\
+Group: System Environment/Kernel\
+%kernel_reqprovconf\
+%{expand:%%kernel_devel_package %1 %{!?-n:%1}%{?-n:%{-n*}}}\
+%{expand:%%kernel_kvm_package %1}\
+%{nil}
+%endif
# First the auxiliary packages of the main kernel package.
%kernel_devel_package
+%if %{builddebuginfo}
%kernel_debuginfo_package
+%endif
# create the production kvm module package
%kernel_kvm_package
+%if %{builddebuginfo}
%kernel_kvm_debuginfo_package
+%endif
# Now, each variant package.
@@ -570,6 +627,54 @@ It should only be installed when trying to gather additional information
on kernel bugs.
%endif
+%if %{with_tools}
+
+%package -n kernel-rt-tools
+Summary: Assortment of tools for the Linux kernel
+Group: Development/System
+License: GPLv2
+Provides: cpupowerutils-rt = 1:009-0.6.p1
+Obsoletes: cpupowerutils-rt < 1:009-0.6.p1
+Provides: cpufreq-utils-rt = 1:009-0.6.p1
+Provides: cpufrequtils-rt = 1:009-0.6.p1
+Obsoletes: cpufreq-utils-rt < 1:009-0.6.p1
+Obsoletes: cpufrequtils-rt < 1:009-0.6.p1
+Obsoletes: cpuspeed-rt < 1:2.0
+Requires: kernel-rt-tools-libs = %{version}-%{release}
+%description -n kernel-rt-tools
+This package contains the tools/ directory from the kernel source
+and the supporting documentation.
+
+%package -n kernel-rt-tools-libs
+Summary: Libraries for the kernels-tools
+Group: Development/System
+License: GPLv2
+%description -n kernel-rt-tools-libs
+This package contains the libraries built from the tools/ directory
+from the kernel source.
+
+%package -n kernel-rt-tools-libs-devel
+Summary: Assortment of tools for the Linux kernel
+Group: Development/System
+License: GPLv2
+Requires: kernel-rt-tools = %{version}-%{release}
+Provides: cpupowerutils-devel = 1:009-0.6.p1.1
+Obsoletes: cpupowerutils-devel <= 1:009-0.6.p1
+Requires: kernel-rt-tools-libs = %{version}-%{release}
+Provides: kernel-rt-tools-devel
+%description -n kernel-rt-tools-libs-devel
+This package contains the development files for the tools/ directory from
+the kernel source.
+
+%endif # with_tools
+
+%if %{do_sign}
+%package unsigned
+Summary: Unsigned build of the Linux kernel
+%description unsigned
+Contains an unsigned version of the Linux kernel
+%endif # do_sign
+
%prep
## ApplyPatch routine
patch_command='patch -p1 -F1 -s'
@@ -614,6 +719,12 @@ cp -rl vanilla-%{kversion} linux-%{kversion}.%{_target_cpu}
cd linux-%{kversion}.%{_target_cpu}
+# Copy any TiS-specific config changes
+cp $RPM_SOURCE_DIR/kernel-%{version}-*.config.tis_extra .
+
+# Copy TiS specific IMA public key
+cp %{SOURCE38} .
+
## Apply Patches here
ApplyPatch linux-kernel-test.patch
@@ -637,6 +748,15 @@ for i in *.config
do
mv $i .config
Arch=`head -1 .config | cut -b 3-`
+
+ # Handle StarlingX Cloud customizations. Use -n to match oldnoconfig below. We want this before
+ # the make line below so that the one below removes any dependencies of ones that we
+ # turn off here. We also want it before "make listnewconfig" so that we can set the
+ # config option for new configs introduced in the StarlingX Cloud patches.
+ if [ -f ${i}.tis_extra ]; then
+ scripts/kconfig/merge_config.sh -m -n .config ${i}.tis_extra
+ fi
+
make %{?cross_opts} ARCH=$Arch listnewconfig | grep -E '^CONFIG_' >.newoptions || true
%if %{listnewconfig_fail}
if [ -s .newoptions ]; then
@@ -771,9 +891,13 @@ BuildKernel() {
cp arch/$Arch/boot/zImage.stub $RPM_BUILD_ROOT/%{image_install_path}/zImage.stub-$KernelVer || :
fi fi
# EFI SecureBoot signing, x86_64-only }
+%if %{do_sign}
+ cp $KernelImage vmlinuz.unsigned
+ $CopyKernel vmlinuz.unsigned $RPM_BUILD_ROOT/%{image_install_path}/vmlinuz.unsigned
%ifarch x86_64
- %pesign -s -i $KernelImage -o $KernelImage.signed -a %{SOURCE13} -c %{SOURCE14} -n %{pesign_name}
+ %pesign -s -i $KernelImage -o $KernelImage.signed -a %{SOURCE37} -c %{SOURCE37} -n %{pesign_name}
mv $KernelImage.signed $KernelImage
+%endif
%endif
$CopyKernel $KernelImage $RPM_BUILD_ROOT/%{image_install_path}/$InstallName-$KernelVer
chmod 755 $RPM_BUILD_ROOT/%{image_install_path}/$InstallName-$KernelVer
@@ -919,6 +1043,12 @@ BuildKernel() {
cp signing_key.priv signing_key.priv.sign${Flavour:+.${Flavour}}
cp signing_key.x509 signing_key.x509.sign${Flavour:+.${Flavour}}
+
%setup -q -n %{name}-%{rpmversion}-%{pkgrelease} -c
mv linux-%{rpmversion}-%{pkgrelease} linux-%{KVERREL}
@@ -938,20 +952,6 @@ mv COPYING COPYING-%{version}
# This Prevents scripts/setlocalversion from mucking with our version numbers.
touch .scmversion
-# Do not use "ambiguous" python shebangs. RHEL 8 now has a new script
-# (/usr/lib/rpm/redhat/brp-mangle-shebangs), which forces us to specify a
-# "non-ambiguous" python shebang for scripts we ship in buildroot. This
-# script throws an error like below:
-# *** ERROR: ambiguous python shebang in /usr/bin/kvm_stat: #!/usr/bin/python. Change it to python3 (or python2) explicitly.
-# We patch all sources below for which we got a report/error.
-pathfix.py -i %{__python3} -p -n \
- tools/kvm/kvm_stat/kvm_stat \
- scripts/show_delta \
- scripts/diffconfig \
- scripts/bloat-o-meter \
- tools/perf/tests/attr.py \
- tools/perf/scripts/python/stat-cpi.py \
- tools/perf/scripts/python/sched-migration.py
%define make make %{?cross_opts} HOSTCFLAGS="%{?build_hostcflags}" HOSTLDFLAGS="%{?build_hostldflags}"
# only deal with configs if we are going to build for the arch
@@ -965,6 +965,9 @@ cd configs
# Drop some necessary files from the source dir into the buildroot
cp $RPM_SOURCE_DIR/kernel-*.config .
+# Copy stx config
+cp $RPM_SOURCE_DIR/kernel-rt-%{version}-*.config.tis_extra .
+
cp %{SOURCE41} .
VERSION=%{version} ./generate_all_configs.sh %{name}
@@ -984,8 +987,20 @@ do
done
%endif
+# Handle StarlingX Cloud customizations. Use -n to match oldnoconfig below. We want this before
+# the make line below so that the one below removes any dependencies of ones that we
+# turn off here. We also want it before "make listnewconfig" so that we can set the
+# config option for new configs introduced in the StarlingX Cloud patches.
+for i in *.config
+do
+ if [ -f ${i}.tis_extra ]; then
+ ../scripts/kconfig/merge_config.sh -m -n ${i} ${i}.tis_extra
+ mv .config ${i}
+ fi
+done
+
cp %{SOURCE42} .
-./process_configs.sh -w %{name} %{rpmversion}
+./process_configs.sh -w -c %{name} %{rpmversion}
# end of kernel config
%endif
@@ -1092,7 +1107,7 @@ BuildKernel() {
fi
%if %{signkernel}
# Sign the image if we're using EFI
- %pesign -s -i $KernelImage -o vmlinuz.signed -a %{SOURCE13} -c %{SOURCE14} -n %{pesign_name}
+ %pesign -s -i $KernelImage -o vmlinuz.signed -a %{SOURCE3000} -c %{SOURCE3000} -n %{pesign_name}
if [ ! -s vmlinuz.signed ]; then
echo "pesigning failed"
exit 1
@@ -1439,6 +1454,12 @@ BuildKernel() {
# Save the signing keys so we can sign the modules in __modsign_install_post
cp certs/signing_key.pem certs/signing_key.pem.sign${Flav}
cp certs/signing_key.x509 certs/signing_key.x509.sign${Flav}
+ # STX: Copy these keys as part of the devel package + # STX: Copy these keys as part of the devel package
+ # The Module signing keys are to ensure that only Out-of-tree + # The Module signing keys are to ensure that only Out-of-tree
+ # built against the StarlingX Kernel get signed and loaded sans warnings + # built against the StarlingX Kernel get signed and loaded sans warnings
+ cp signing_key.priv ${RPM_BUILD_ROOT}/lib/modules/${KernelVer}/build/ + cp certs/signing_key.pem ${RPM_BUILD_ROOT}/lib/modules/${KernelVer}/build/
+ cp signing_key.x509 ${RPM_BUILD_ROOT}/lib/modules/${KernelVer}/build/ + chmod 755 ${RPM_BUILD_ROOT}/lib/modules/${KernelVer}/build/signing_key.pem
+ + cp certs/signing_key.x509 ${RPM_BUILD_ROOT}/lib/modules/${KernelVer}/build/
# remove files that will be auto generated by depmod at rpm -i time fi
for i in alias alias.bin builtin.bin ccwmap dep dep.bin ieee1394map inputmap isapnpmap ofmap pcimap seriomap symbols symbols.bin usbmap softdep devname
do
@@ -934,6 +1064,15 @@ BuildKernel() {
install -Dm644 %{SOURCE1000} $RPM_BUILD_ROOT%{_sysconfdir}/modprobe.d/dccp-blacklist.conf
+ # create the kABI metadata for use in packaging
+ # NOTENOTE: the name symvers is used by the rpm backend
+ # NOTENOTE: to discover and run the /usr/lib/rpm/fileattrs/kabi.attr
+ # NOTENOTE: script which dynamically adds exported kernel symbol
+ # NOTENOTE: checksums to the rpm metadata provides list.
+ # NOTENOTE: if you change the symvers name, update the backend too
+ echo "**** GENERATING kernel ABI metadata ****"
+ gzip -c9 < Module.symvers > $RPM_BUILD_ROOT/boot/symvers-$KernelVer.gz
+
# prune junk from kernel-devel
find $RPM_BUILD_ROOT/usr/src/kernels -name ".*.cmd" -exec rm -f {} \;
}
@@ -981,6 +1120,31 @@ BuildKernel %make_target %kernel_image vanilla
BuildKernel %make_target %kernel_image
%endif %endif
+%if %{with_tools} @@ -1991,7 +2012,7 @@ fi
+%ifarch %{cpupowerarchs} %endif # with_perf
+# cpupower
+# make sure version-gen.sh is executable.
+chmod +x tools/power/cpupower/utils/version-gen.sh
+make %{?cross_opts} %{?_smp_mflags} -C tools/power/cpupower CPUFREQ_BENCH=false
+%ifarch x86_64
+ pushd tools/power/cpupower/debug/x86_64
+ make %{?_smp_mflags} centrino-decode powernow-k8-decode
+ popd
+%endif
+%ifarch x86_64
+ pushd tools/power/x86/x86_energy_perf_policy/
+ make
+ popd
+ pushd tools/power/x86/turbostat
+ make
+ popd
+%endif #turbostat/x86_energy_perf_policy
+%endif
+pushd tools
+make tmon
+popd
+%endif
+
%if %{builddoc}
# Make the HTML and man pages.
make -j1 htmldocs mandocs || %{doc_build_fail}
@@ -1013,6 +1177,7 @@ popd
# if it isn't.
%ifnarch noarch %if %{with_tools}
+%if %{do_sign} -%files -n kernel-tools
%define __modsign_install_post \ +%files -n %{name}-tools
if [ "%{with_rt}" -ne "0" ]; then \ %defattr(-,root,root)
Arch=`head -1 configs/kernel-%{version}-%{_target_cpu}-rt.config | cut -b 3-` \ %ifarch %{cpupowerarchs}
@@ -1031,6 +1196,24 @@ popd %files -n %{name}-tools -f cpupower.lang
%{modsign_cmd} $RPM_BUILD_ROOT/lib/modules/%{KVERREL}.${AAA} || exit 1 \ @@ -2087,26 +2108,24 @@ fi
done \ %if %{with_realtime}\
%exclude /lib/modules/%{KVERREL}%{?3:+%{3}}/kernel/arch/x86/kvm\
%exclude /lib/modules/%{KVERREL}%{?3:+%{3}}/kernel/drivers/gpu/drm/i915/gvt\
-%exclude /lib/modules/%{KVERREL}%{?3:+%{3}}/modules.kvm\
-%exclude /lib/modules/%{KVERREL}%{?3:+%{3}}/kernel/drivers/ptp/ptp_kvm*\
%endif\
%{!?_licensedir:%global license %%doc}\
%license linux-%{KVERREL}/COPYING-%{version}\
/lib/modules/%{KVERREL}%{?3:+%{3}}/%{?-k:%{-k*}}%{!?-k:vmlinuz}\
-%ghost /%{image_install_path}/%{?-k:%{-k*}}%{!?-k:vmlinuz}-%{KVERREL}%{?3:+%{3}}\
+/%{image_install_path}/%{?-k:%{-k*}}%{!?-k:vmlinuz}-%{KVERREL}%{?3:+%{3}}\
/lib/modules/%{KVERREL}%{?3:+%{3}}/.vmlinuz.hmac \
-%ghost /%{image_install_path}/.vmlinuz-%{KVERREL}%{?3:+%{3}}.hmac \
+/%{image_install_path}/.vmlinuz-%{KVERREL}%{?3:+%{3}}.hmac \
%ifarch aarch64\
/lib/modules/%{KVERREL}%{?3:+%{3}}/dtb \
-%ghost /%{image_install_path}/dtb-%{KVERREL}%{?3:+%{3}} \
+/%{image_install_path}/dtb-%{KVERREL}%{?3:+%{3}} \
%endif\
%attr(600,root,root) /lib/modules/%{KVERREL}%{?3:+%{3}}/System.map\
-%ghost /boot/System.map-%{KVERREL}%{?3:+%{3}}\
+/boot/System.map-%{KVERREL}%{?3:+%{3}}\
/lib/modules/%{KVERREL}%{?3:+%{3}}/symvers.gz\
/lib/modules/%{KVERREL}%{?3:+%{3}}/config\
-%ghost /boot/symvers-%{KVERREL}%{?3:+%{3}}.gz\
-%ghost /boot/config-%{KVERREL}%{?3:+%{3}}\
-%ghost /boot/initramfs-%{KVERREL}%{?3:+%{3}}.img\
+/boot/symvers-%{KVERREL}%{?3:+%{3}}.gz\
+/boot/config-%{KVERREL}%{?3:+%{3}}\
+/boot/initramfs-%{KVERREL}%{?3:+%{3}}.img\
%dir /lib/modules\
%dir /lib/modules/%{KVERREL}%{?3:+%{3}}\
%dir /lib/modules/%{KVERREL}%{?3:+%{3}}/kernel\
@@ -2127,7 +2146,6 @@ fi
%exclude /lib/modules/%{KVERREL}%{?3:+%{3}}/kernel/arch/x86/kvm\
%exclude /lib/modules/%{KVERREL}%{?3:+%{3}}/kernel/drivers/gpu/drm/i915/gvt\
%exclude /lib/modules/%{KVERREL}%{?3:+%{3}}/modules.kvm\
-%exclude /lib/modules/%{KVERREL}%{?3:+%{3}}/kernel/drivers/ptp/ptp_kvm*\
%endif\
%{expand:%%files %{?3:%{3}-}devel}\
%defattr(-,root,root)\
@@ -2157,19 +2175,20 @@ fi
/lib/modules/%{KVERREL}%{?3:+%{3}}/modules.kvm\
/lib/modules/%{KVERREL}%{?3:+%{3}}/kernel/arch/x86/kvm\
/lib/modules/%{KVERREL}%{?3:+%{3}}/kernel/drivers/gpu/drm/i915/gvt/kvmgt.ko*\
-/lib/modules/%{KVERREL}%{?3:+%{3}}/kernel/drivers/ptp/ptp_kvm.ko*\
%if %{with_debuginfo}\
%{expand:%%files %{?3:%{3}-}kvm-debuginfo}\
%dir %{debuginfodir}/lib/modules/%{KVERREL}%{?3:+%{3}}/kernel/arch/x86/kvm\
%{debuginfodir}/lib/modules/%{KVERREL}%{?3:+%{3}}/kernel/arch/x86/kvm\
%{debuginfodir}/lib/modules/%{KVERREL}%{?3:+%{3}}/kernel/drivers/gpu/drm/i915/gvt\
-%{debuginfodir}/lib/modules/%{KVERREL}%{?3:+%{3}}/kernel/drivers/ptp/ptp_kvm*\
%endif\
%endif\
%{nil} %{nil}
+%else
+%define __modsign_install_post \
+ if [ "%{with_rt}" -ne "0" ]; then \
+ Arch=`head -1 configs/kernel-%{version}-%{_target_cpu}-rt.config | cut -b 3-` \
+ rm -rf .tmp_versions \
+ mv .tmp_versions.sign .tmp_versions \
+ mv signing_key.priv.sign signing_key.priv \
+ mv signing_key.x509.sign signing_key.x509 \
+ fi\
+ for AAA in %{?with_trace:trace} %{?with_debug:debug} %{?with_vanilla:vanilla}; do \
+ Arch=`head -1 configs/kernel-%{version}-%{_target_cpu}-rt-${AAA}.config | cut -b 3-` \
+ rm -rf .tmp_versions \
+ mv .tmp_versions.sign.${AAA} .tmp_versions \
+ mv signing_key.priv.sign.${AAA} signing_key.priv \
+ mv signing_key.x509.sign.${AAA} signing_key.x509 \
+ done \
+%{nil}
+%endif
%endif
### %kernel_variant_files %{with_vdso_install} %{with_up}
@@ -1120,6 +1303,39 @@ mkdir -p $RPM_BUILD_ROOT%{_datadir}/doc/perf +# STX: disable debug build
%endif # buildperf +%if %{with_debug}
%kernel_variant_files %{with_vdso_install} %{with_debug} debug
+%endif
%if %{with_zfcpdump}
%kernel_variant_files %{with_vdso_install} %{with_zfcpdump} zfcpdump
%endif %endif
+%if %{with_tools}
+%ifarch %{cpupowerarchs}
+make -C tools/power/cpupower DESTDIR=$RPM_BUILD_ROOT libdir=%{_libdir} mandir=%{_mandir} CPUFREQ_BENCH=false install
+rm -f %{buildroot}%{_libdir}/*.{a,la}
+%find_lang cpupower
+mv cpupower.lang ../
+%ifarch x86_64
+ pushd tools/power/cpupower/debug/x86_64
+ install -m755 centrino-decode %{buildroot}%{_bindir}/centrino-decode
+ install -m755 powernow-k8-decode %{buildroot}%{_bindir}/powernow-k8-decode
+ popd
+%endif
+chmod 0755 %{buildroot}%{_libdir}/libcpupower.so*
+mkdir -p %{buildroot}%{_unitdir} %{buildroot}%{_sysconfdir}/sysconfig
+install -m644 %{SOURCE2000} %{buildroot}%{_unitdir}/cpupower.service
+install -m644 %{SOURCE2001} %{buildroot}%{_sysconfdir}/sysconfig/cpupower
+%ifarch %{ix86} x86_64
+ mkdir -p %{buildroot}%{_mandir}/man8
+ pushd tools/power/x86/x86_energy_perf_policy
+ make DESTDIR=%{buildroot} install
+ popd
+ pushd tools/power/x86/turbostat
+ make DESTDIR=%{buildroot} install
+ popd
+%endif #turbostat/x86_energy_perf_policy
+pushd tools/thermal/tmon
+make INSTALL_ROOT=%{buildroot} install
+popd
+%endif
+
+%endif
+
+
%if %{buildheaders}
# Install kernel headers
make ARCH=%{hdrarch} INSTALL_HDR_PATH=$RPM_BUILD_ROOT/usr headers_install
@@ -1174,6 +1390,14 @@ rm -rf $RPM_BUILD_ROOT
### scripts
###
+%if %{with_tools}
+%post -n kernel-rt-tools
+/sbin/ldconfig
+
+%postun -n kernel-rt-tools
+/sbin/ldconfig
+%endif
+
#
# This macro defines a %%post script for a kernel*-devel package.
# %%kernel_devel_post [<subpackage>]
@@ -1337,6 +1561,43 @@ fi
%endif
%endif
+
+%if %{with_tools}
+%files -n kernel-rt-tools -f cpupower.lang
+%defattr(-,root,root)
+%ifarch %{cpupowerarchs}
+%{_bindir}/cpupower
+%ifarch x86_64
+%{_bindir}/centrino-decode
+%{_bindir}/powernow-k8-decode
+%endif
+%{_unitdir}/cpupower.service
+%{_mandir}/man[1-8]/cpupower*
+%config(noreplace) %{_sysconfdir}/sysconfig/cpupower
+%ifarch %{ix86} x86_64
+%{_bindir}/x86_energy_perf_policy
+%{_mandir}/man8/x86_energy_perf_policy*
+%{_bindir}/turbostat
+%{_mandir}/man8/turbostat*
+%endif
+%endif
+%{_bindir}/tmon
+
+%ifarch %{cpupowerarchs}
+%files -n kernel-rt-tools-libs
+%defattr(-,root,root)
+%{_libdir}/libcpupower.so.0
+%{_libdir}/libcpupower.so.0.0.0
+
+%files -n kernel-rt-tools-libs-devel
+%defattr(-,root,root)
+%{_libdir}/libcpupower.so
+%{_includedir}/cpufreq.h
+%endif
+
+%endif # with_tools
+
+
# This is %{image_install_path} on an arch where that includes ELF files,
# or empty otherwise.
%global elf_image_install_path %{?kernel_image_elf:%{image_install_path}}
@@ -1353,6 +1614,7 @@ fi
/%{image_install_path}/%{?-k:%{-k*}}%{!?-k:vmlinuz}-%{KVERREL}%{?2:.%{2}}\
/%{image_install_path}/.vmlinuz-%{KVERREL}%{?2:.%{2}}.hmac\
/boot/System.map-%{KVERREL}%{?2:.%{2}}\
+/boot/symvers-%{KVERREL}%{?2:.%{2}}.gz\
/boot/config-%{KVERREL}%{?2:.%{2}}\
/boot/symvers*\
%exclude /lib/modules/%{KVERREL}%{?2:.%{2}}/kernel/arch/x86/kvm\
@@ -1432,6 +1694,11 @@ fi
%kernel_variant_files %{buildvanilla} vanilla
%endif
+%if %{do_sign}
+%files unsigned
+/boot/vmlinuz.unsigned
+%endif # do_sign
+
%changelog
* Mon Sep 16 2019 Luis Claudio R. Goncalves <lgoncalv@redhat.com> [3.10.0-1062.1.2.rt56.1025.el7]
- [rt] Update source tree to match RHEL rhel-7.7.z tree [1740918 1708718]
-- --
1.8.3.1 2.7.4

View File

@ -1,42 +0,0 @@
From 611efdc47a31f229612fd324925c76f6fb204d9c Mon Sep 17 00:00:00 2001
Message-Id: <611efdc47a31f229612fd324925c76f6fb204d9c.1584650624.git.Jim.Somerville@windriver.com>
In-Reply-To: <0a8e423b2d06a4604c51a1e5bfcc305203d49a62.1584650624.git.Jim.Somerville@windriver.com>
References: <0a8e423b2d06a4604c51a1e5bfcc305203d49a62.1584650624.git.Jim.Somerville@windriver.com>
From: Jim Somerville <Jim.Somerville@windriver.com>
Date: Fri, 13 Mar 2020 16:15:29 -0400
Subject: [PATCH 2/2] Compile issues
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
---
SPECS/kernel-rt.spec | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/SPECS/kernel-rt.spec b/SPECS/kernel-rt.spec
index c549d7e..f8fe5be 100644
--- a/SPECS/kernel-rt.spec
+++ b/SPECS/kernel-rt.spec
@@ -426,6 +426,11 @@ Patch1033: rh-ext4-release-leaked-posix-acl-in-ext4_acl_chmod.patch
Patch1034: rh-ext4-release-leaked-posix-acl-in-ext4_xattr_set_a.patch
# Workaround for broken bios causing IOMMU issues
Patch1035: Allow-dmar-quirks-for-broken-bioses.patch
+Patch1100: fix-compilation-issues.patch
+# Fix CentOS 7.6 upgrade compile error
+Patch1101: fix-CentOS-7.6-upgrade-compile-error.patch
+# Compile fix for disabling CONFIG_MEMCG_KMEM
+Patch1102: compile-fix-for-disabling-CONFIG_MEMCG_KMEM.patch
BuildRoot: %{_tmppath}/kernel-%{KVERREL}-root
@@ -799,6 +804,9 @@ ApplyPatch ipvs-fix-memory-leak-in-ip_vs_ctl.c.patch
ApplyPatch rh-ext4-release-leaked-posix-acl-in-ext4_acl_chmod.patch
ApplyPatch rh-ext4-release-leaked-posix-acl-in-ext4_xattr_set_a.patch
ApplyPatch Allow-dmar-quirks-for-broken-bioses.patch
+ApplyPatch fix-compilation-issues.patch
+ApplyPatch fix-CentOS-7.6-upgrade-compile-error.patch
+ApplyPatch compile-fix-for-disabling-CONFIG_MEMCG_KMEM.patch
# move off upstream version mechanism
if [ -e localversion-rt ]; then
--
1.8.3.1

View File

@ -5,100 +5,59 @@ Date: Fri, 13 Mar 2020 16:15:29 -0400
Subject: [PATCH 1/2] Kernel source patches for TiC Subject: [PATCH 1/2] Kernel source patches for TiC
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com> Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
Signed-off-by: Dongqi Chen <chen.dq@neusoft.com>
--- ---
SPECS/kernel-rt.spec | 72 ++++++++++++++++++++++++++++++++++++++++++++++++++++ SPECS/kernel-rt.spec | 30 ++++++++++++++++++++++++++++++
1 file changed, 72 insertions(+) 1 file changed, 30 insertions(+)
diff --git a/SPECS/kernel-rt.spec b/SPECS/kernel-rt.spec diff --git a/SPECS/kernel-rt.spec b/SPECS/kernel-rt.spec
index c48b73e..c549d7e 100644 index c48b73e..c549d7e 100644
--- a/SPECS/kernel-rt.spec --- a/SPECS/kernel-rt.spec
+++ b/SPECS/kernel-rt.spec +++ b/SPECS/kernel-rt.spec
@@ -388,6 +388,44 @@ Source30002: kernel-3.10.0-x86_64-rt-trace.config.tis_extra @@ -432,6 +432,22 @@ Source3001: ima_signing_key.pub
Source30000: kernel-rt-4.18.0-x86_64.config.tis_extra
# Empty final patch file to facilitate testing of kernel patches ## Patches needed for building this package
Patch999999: linux-kernel-test.patch +# StarlingX Cloud patches here.
+Patch1000: debrand-single-cpu.patch +Patch40002: Notification-of-death-of-arbitrary-processes.patch
+Patch1001: debrand-rh_taint.patch +Patch40004: PCI-Add-ACS-quirk-for-Intel-Fortville-NICs.patch
+Patch1002: debrand-rh-i686-cpu.patch +Patch40005: affine-compute-kernel-threads.patch
+Patch1003: affine-compute-kernel-threads.patch +Patch40006: Affine-irqs-and-workqueues-with-kthread_cpus.patch
+Patch1004: Affine-irqs-and-workqueues-with-kthread_cpus.patch +Patch40007: Make-kernel-start-eth-devices-at-offset.patch
+Patch1005: CGTS-3744-route-do-not-cache-fib-route-info-on-local.patch +Patch40008: intel-iommu-allow-ignoring-Ethernet-device-RMRR-with.patch
+Patch1006: cma-add-placement-specifier-for-cma-kernel-parameter.patch +Patch40026: turn-off-write-same-in-smartqpi-driver.patch
+Patch1007: intel-iommu-allow-ignoring-Ethernet-device-RMRR-with.patch +Patch40031: Allow-dmar-quirks-for-broken-bioses.patch
+Patch1008: Make-kernel-start-eth-devices-at-offset.patch +
+Patch1009: memblock-introduce-memblock_alloc_range.patch +# StarlingX Cloud rt patches here.
+Patch1010: Notification-of-death-of-arbitrary-processes.patch +
+Patch1011: PCI-Add-ACS-quirk-for-Intel-Fortville-NICs.patch +Patch41000: debrand-rh-i686-cpu.patch
+Patch1012: x86-enable-DMA-CMA-with-swiotlb.patch +Patch41001: debrand-rh_taint.patch
+Patch1013: Add-missing-ifdef-around-max-latency-variable.patch +Patch41002: debrand-single-cpu.patch
+Patch1015: Enable-building-kernel-with-CONFIG_BLK_DEV_NBD.patch +Patch41003: restrict-iSCSI-kthreads-to-CPUs-in-cpu_kthread_mask.patch
+Patch1016: x86-make-dma_alloc_coherent-return-zeroed-memory-if-.patch
+Patch1018: Porting-Cacheinfo-from-Kernel-4.10.17.patch
+Patch1019: Fix-cacheinfo-compilation-issues-for-3.10.patch
+Patch1020: cpuidle-menu-stop-seeking-deeper-idle-if-current-sta.patch
+Patch1021: cpuidle-menu-add-per-CPU-PM-QoS-resume-latency-consi.patch
+Patch1022: CPU-PM-expose-pm_qos_resume_latency-for-CPUs.patch
+Patch1023: cpuidle-menu-Avoid-taking-spinlock-for-accessing-QoS.patch
+Patch1024: US101216-IMA-support-in-Titanium-kernel.patch
+Patch1025: US103091-IMA-System-Configuration.patch
+# Fix compile warnings that break the build
+Patch1026: aic94xx-Skip-reading-user-settings-if-flash-is-not-f.patch
+Patch1027: dpt_i2o-fix-build-warning.patch
+# DRBD was choking on write same
+Patch1028: turn-off-write-same-in-smartqpi-driver.patch
+Patch1029: restrict-iSCSI-kthreads-to-CPUs-in-cpu_kthread_mask.patch
+Patch1030: robustify-CFS-bandwidth-timer-locking.patch
+Patch1031: epoll-fix-use-after-free-in-eventpoll_release_file.patch
+# Fix three potential kernel memory leaks
+Patch1032: ipvs-fix-memory-leak-in-ip_vs_ctl.c.patch
+Patch1033: rh-ext4-release-leaked-posix-acl-in-ext4_acl_chmod.patch
+Patch1034: rh-ext4-release-leaked-posix-acl-in-ext4_xattr_set_a.patch
+# Workaround for broken bios causing IOMMU issues
+Patch1035: Allow-dmar-quirks-for-broken-bioses.patch
BuildRoot: %{_tmppath}/kernel-%{KVERREL}-root # END OF PATCH DEFINITIONS
@@ -727,6 +765,40 @@ cp %{SOURCE38} . @@ -937,6 +953,20 @@ cd linux-%{KVERREL}
## Apply Patches here # END OF PATCH APPLICATIONS
ApplyPatch linux-kernel-test.patch
+ApplyPatch debrand-single-cpu.patch
+ApplyPatch debrand-rh_taint.patch
+ApplyPatch debrand-rh-i686-cpu.patch
+ApplyPatch affine-compute-kernel-threads.patch
+ApplyPatch Affine-irqs-and-workqueues-with-kthread_cpus.patch
+ApplyPatch CGTS-3744-route-do-not-cache-fib-route-info-on-local.patch
+ApplyPatch cma-add-placement-specifier-for-cma-kernel-parameter.patch
+ApplyPatch intel-iommu-allow-ignoring-Ethernet-device-RMRR-with.patch
+ApplyPatch Make-kernel-start-eth-devices-at-offset.patch
+ApplyPatch memblock-introduce-memblock_alloc_range.patch
+ApplyPatch PCI-Add-ACS-quirk-for-Intel-Fortville-NICs.patch
+ApplyPatch Notification-of-death-of-arbitrary-processes.patch
+ApplyPatch x86-enable-DMA-CMA-with-swiotlb.patch
+ApplyPatch Add-missing-ifdef-around-max-latency-variable.patch
+ApplyPatch Enable-building-kernel-with-CONFIG_BLK_DEV_NBD.patch
+ApplyPatch x86-make-dma_alloc_coherent-return-zeroed-memory-if-.patch
+ApplyPatch Porting-Cacheinfo-from-Kernel-4.10.17.patch
+ApplyPatch Fix-cacheinfo-compilation-issues-for-3.10.patch
+ApplyPatch cpuidle-menu-stop-seeking-deeper-idle-if-current-sta.patch
+ApplyPatch cpuidle-menu-add-per-CPU-PM-QoS-resume-latency-consi.patch
+ApplyPatch CPU-PM-expose-pm_qos_resume_latency-for-CPUs.patch
+ApplyPatch cpuidle-menu-Avoid-taking-spinlock-for-accessing-QoS.patch
+ApplyPatch US101216-IMA-support-in-Titanium-kernel.patch
+ApplyPatch US103091-IMA-System-Configuration.patch
+ApplyPatch aic94xx-Skip-reading-user-settings-if-flash-is-not-f.patch
+ApplyPatch dpt_i2o-fix-build-warning.patch
+ApplyPatch turn-off-write-same-in-smartqpi-driver.patch
+ApplyPatch restrict-iSCSI-kthreads-to-CPUs-in-cpu_kthread_mask.patch
+ApplyPatch robustify-CFS-bandwidth-timer-locking.patch
+ApplyPatch epoll-fix-use-after-free-in-eventpoll_release_file.patch
+ApplyPatch ipvs-fix-memory-leak-in-ip_vs_ctl.c.patch
+ApplyPatch rh-ext4-release-leaked-posix-acl-in-ext4_acl_chmod.patch
+ApplyPatch rh-ext4-release-leaked-posix-acl-in-ext4_xattr_set_a.patch
+ApplyPatch Allow-dmar-quirks-for-broken-bioses.patch
# move off upstream version mechanism +# StarlingX Cloud patches here.
if [ -e localversion-rt ]; then +ApplyOptionalPatch Notification-of-death-of-arbitrary-processes.patch
+ApplyOptionalPatch PCI-Add-ACS-quirk-for-Intel-Fortville-NICs.patch
+ApplyOptionalPatch affine-compute-kernel-threads.patch
+ApplyOptionalPatch Affine-irqs-and-workqueues-with-kthread_cpus.patch
+ApplyOptionalPatch Make-kernel-start-eth-devices-at-offset.patch
+ApplyOptionalPatch intel-iommu-allow-ignoring-Ethernet-device-RMRR-with.patch
+ApplyOptionalPatch turn-off-write-same-in-smartqpi-driver.patch
+ApplyOptionalPatch Allow-dmar-quirks-for-broken-bioses.patch
+ApplyOptionalPatch debrand-rh-i686-cpu.patch
+ApplyOptionalPatch debrand-rh_taint.patch
+ApplyOptionalPatch debrand-single-cpu.patch
+ApplyOptionalPatch restrict-iSCSI-kthreads-to-CPUs-in-cpu_kthread_mask.patch
+
# Any further pre-build tree manipulations happen here.
%if %{with_realtime}
-- --
1.8.3.1 2.7.4

View File

@ -1,3 +1,2 @@
Build-logic-and-sources-for-TiC.patch Build-logic-and-sources-for-TiC.patch
Kernel-source-patches-for-TiC.patch Kernel-source-patches-for-TiC.patch
Compile-issues.patch

View File

@ -1,52 +0,0 @@
From d249a02d441998c43aeb1755c85cffb062628500 Mon Sep 17 00:00:00 2001
Message-Id: <d249a02d441998c43aeb1755c85cffb062628500.1528226387.git.Jim.Somerville@windriver.com>
In-Reply-To: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
References: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
From: Jim Somerville <Jim.Somerville@windriver.com>
Date: Thu, 22 Dec 2016 17:54:11 -0500
Subject: [PATCH 14/32] Add missing ifdef around max latency variable
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
---
kernel/trace/trace_hwlat.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/kernel/trace/trace_hwlat.c b/kernel/trace/trace_hwlat.c
index 4b30d8b..1bb578c 100644
--- a/kernel/trace/trace_hwlat.c
+++ b/kernel/trace/trace_hwlat.c
@@ -167,7 +167,9 @@ void trace_hwlat_callback(bool enter)
*/
static int get_sample(void)
{
+#ifdef CONFIG_TRACER_MAX_TRACE
struct trace_array *tr = hwlat_trace;
+#endif
time_type start, t1, t2, last_t2;
s64 diff, total, last_total = 0;
u64 sample = 0;
@@ -254,9 +256,11 @@ static int get_sample(void)
s.nmi_count = nmi_count;
trace_hwlat_sample(&s);
+#ifdef CONFIG_TRACER_MAX_TRACE
/* Keep a running maximum ever recorded hardware latency */
if (sample > tr->max_latency)
tr->max_latency = sample;
+#endif
}
out:
@@ -582,7 +586,9 @@ static int hwlat_tracer_init(struct trace_array *tr)
disable_migrate = false;
hwlat_data.count = 0;
+#ifdef CONFIG_TRACER_MAX_TRACE
tr->max_latency = 0;
+#endif
save_tracing_thresh = tracing_thresh;
/* tracing_thresh is in nsecs, we speak in usecs */
--
1.8.3.1

View File

@ -1,10 +1,7 @@
From 1584ae45f750efec21265fb0b8ac6a02975dfb76 Mon Sep 17 00:00:00 2001 From 3ceddd371d3d53ef0bbe81bad548f2d6889ec3d2 Mon Sep 17 00:00:00 2001
Message-Id: <1584ae45f750efec21265fb0b8ac6a02975dfb76.1528226387.git.Jim.Somerville@windriver.com>
In-Reply-To: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
References: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
From: Chris Friesen <chris.friesen@windriver.com> From: Chris Friesen <chris.friesen@windriver.com>
Date: Tue, 24 Nov 2015 16:27:29 -0500 Date: Tue, 24 Nov 2015 16:27:29 -0500
Subject: [PATCH 05/32] Affine irqs and workqueues with kthread_cpus Subject: [PATCH 04/10] Affine irqs and workqueues with kthread_cpus
If the kthread_cpus boot arg is set it means we want to affine If the kthread_cpus boot arg is set it means we want to affine
kernel threads to the specified CPU mask as much as possible kernel threads to the specified CPU mask as much as possible
@ -23,34 +20,35 @@ Signed-off-by: Chris Friesen <chris.friesen@windriver.com>
Signed-off-by: Vu Tran <vu.tran@windriver.com> Signed-off-by: Vu Tran <vu.tran@windriver.com>
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com> Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
Signed-off-by: Zhang Zhiguo <zhangzhg@neusoft.com>
--- ---
kernel/irq/manage.c | 7 +++++++ kernel/irq/manage.c | 7 +++++++
kernel/workqueue.c | 4 ++++ kernel/workqueue.c | 4 ++++
2 files changed, 11 insertions(+) 2 files changed, 11 insertions(+)
diff --git a/kernel/irq/manage.c b/kernel/irq/manage.c diff --git a/kernel/irq/manage.c b/kernel/irq/manage.c
index bd59426..bad147c 100644 index c4e31f4..002dec3 100644
--- a/kernel/irq/manage.c --- a/kernel/irq/manage.c
+++ b/kernel/irq/manage.c +++ b/kernel/irq/manage.c
@@ -410,6 +410,13 @@ setup_affinity(unsigned int irq, struct irq_desc *desc, struct cpumask *mask) @@ -400,6 +400,13 @@ int irq_setup_affinity(struct irq_desc *desc)
if (cpumask_intersects(mask, nodemask)) if (cpumask_intersects(&mask, nodemask))
cpumask_and(mask, mask, nodemask); cpumask_and(&mask, &mask, nodemask);
} }
+ +
+ /* This will narrow down the affinity further if we've specified + /* This will narrow down the affinity further if we've specified
+ * a reduced cpu_kthread_mask in the boot args. + * a reduced cpu_kthread_mask in the boot args.
+ */ + */
+ if (cpumask_intersects(mask, cpu_kthread_mask)) + if (cpumask_intersects(&mask, cpu_kthread_mask))
+ cpumask_and(mask, mask, cpu_kthread_mask); + cpumask_and(&mask, &mask, cpu_kthread_mask);
+ +
irq_do_set_affinity(&desc->irq_data, mask, false); ret = irq_do_set_affinity(&desc->irq_data, &mask, false);
return 0; raw_spin_unlock(&mask_lock);
} return ret;
diff --git a/kernel/workqueue.c b/kernel/workqueue.c diff --git a/kernel/workqueue.c b/kernel/workqueue.c
index 986e283..7160e71 100644 index 4228207..c7fa0ec 100644
--- a/kernel/workqueue.c --- a/kernel/workqueue.c
+++ b/kernel/workqueue.c +++ b/kernel/workqueue.c
@@ -5483,6 +5483,8 @@ static int __init init_workqueues(void) @@ -5730,6 +5730,8 @@ int __init workqueue_init_early(void)
BUG_ON(!(attrs = alloc_workqueue_attrs(GFP_KERNEL))); BUG_ON(!(attrs = alloc_workqueue_attrs(GFP_KERNEL)));
attrs->nice = std_nice[i]; attrs->nice = std_nice[i];
@ -59,7 +57,7 @@ index 986e283..7160e71 100644
unbound_std_wq_attrs[i] = attrs; unbound_std_wq_attrs[i] = attrs;
/* /*
@@ -5493,6 +5495,8 @@ static int __init init_workqueues(void) @@ -5740,6 +5742,8 @@ int __init workqueue_init_early(void)
BUG_ON(!(attrs = alloc_workqueue_attrs(GFP_KERNEL))); BUG_ON(!(attrs = alloc_workqueue_attrs(GFP_KERNEL)));
attrs->nice = std_nice[i]; attrs->nice = std_nice[i];
attrs->no_numa = true; attrs->no_numa = true;
@ -69,5 +67,5 @@ index 986e283..7160e71 100644
} }
-- --
1.8.3.1 2.7.4

View File

@ -27,6 +27,7 @@ Lu Baolu of Intel Corp to lkml
https://lkml.org/lkml/2019/12/24/15 https://lkml.org/lkml/2019/12/24/15
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com> Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
Signed-off-by: Dongqi Chen <chen.dq@neusoft.com>
--- ---
drivers/iommu/dmar.c | 25 ++++++++++++++++++++++++- drivers/iommu/dmar.c | 25 ++++++++++++++++++++++++-
1 file changed, 24 insertions(+), 1 deletion(-) 1 file changed, 24 insertions(+), 1 deletion(-)
@ -35,9 +36,9 @@ diff --git a/drivers/iommu/dmar.c b/drivers/iommu/dmar.c
index 4658dc3..eeaef2e 100644 index 4658dc3..eeaef2e 100644
--- a/drivers/iommu/dmar.c --- a/drivers/iommu/dmar.c
+++ b/drivers/iommu/dmar.c +++ b/drivers/iommu/dmar.c
@@ -75,6 +75,26 @@ static unsigned long dmar_seq_ids[BITS_TO_LONGS(DMAR_UNITS_SUPPORTED)]; @@ -76,6 +76,26 @@ static void free_iommu(struct intel_iommu *iommu);
static int alloc_iommu(struct dmar_drhd_unit *drhd);
static void free_iommu(struct intel_iommu *iommu); extern const struct iommu_ops intel_iommu_ops;
+static int scope_mismatch_quirk; +static int scope_mismatch_quirk;
+static void quirk_dmar_scope_mismatch(struct pci_dev *dev) +static void quirk_dmar_scope_mismatch(struct pci_dev *dev)
@ -62,7 +63,7 @@ index 4658dc3..eeaef2e 100644
static void dmar_register_drhd_unit(struct dmar_drhd_unit *drhd) static void dmar_register_drhd_unit(struct dmar_drhd_unit *drhd)
{ {
/* /*
@@ -257,7 +277,10 @@ int dmar_insert_dev_scope(struct dmar_pci_notify_info *info, @@ -258,7 +278,10 @@ int dmar_insert_dev_scope(struct dmar_pci_notify_info *info,
info->dev->class >> 8 != PCI_CLASS_BRIDGE_OTHER))) { info->dev->class >> 8 != PCI_CLASS_BRIDGE_OTHER))) {
pr_warn("Device scope type does not match for %s\n", pr_warn("Device scope type does not match for %s\n",
pci_name(info->dev)); pci_name(info->dev));
@ -75,5 +76,5 @@ index 4658dc3..eeaef2e 100644
for_each_dev_scope(devices, devices_cnt, i, tmp) for_each_dev_scope(devices, devices_cnt, i, tmp)
-- --
1.8.3.1 2.7.4

View File

@ -1,58 +0,0 @@
From a4302d3590621f64e639f8e075f423d5120c007e Mon Sep 17 00:00:00 2001
Message-Id: <a4302d3590621f64e639f8e075f423d5120c007e.1528226387.git.Jim.Somerville@windriver.com>
In-Reply-To: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
References: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
From: Allain Legacy <allain.legacy@windriver.com>
Date: Fri, 29 Jan 2016 12:13:40 -0500
Subject: [PATCH 06/32] CGTS-3744: route: do not cache fib route info on local
routes with oif
For local routes that require a particular output interface we do not want to
cache the result. Caching the result causes incorrect behaviour when there are
multiple source addresses on the interface. The end result being that if the
intended recipient is waiting on that interface for the packet he won't receive
it because it will be delivered on the loopback interface and the IP_PKTINFO
ipi_ifindex will be set to the loopback interface as well.
This can be tested by running a program such as "dhcp_release" which attempts
to inject a packet on a particular interface so that it is received by another
program on the same board. The receiving process should see an IP_PKTINFO
ipi_ifndex value of the source interface (e.g., eth1) instead of the loopback
interface (e.g., lo). The packet will still appear on the loopback interface
in tcpdump but the important aspect is that the CMSG info is correct.
Sample dhcp_release command line:
dhcp_release eth1 192.168.204.222 02:11:33:22:44:66
Signed-off-by: Allain Legacy <allain.legacy@windriver.com>
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
---
net/ipv4/route.c | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/net/ipv4/route.c b/net/ipv4/route.c
index f19aca2..5246096 100644
--- a/net/ipv4/route.c
+++ b/net/ipv4/route.c
@@ -2121,6 +2121,17 @@ static struct rtable *__mkroute_output(const struct fib_result *res,
*/
if (fi && res->prefixlen < 4)
fi = NULL;
+ } else if ((type == RTN_LOCAL) && (orig_oif != 0)) {
+ /*
+ * For local routes that require a particular output interface we do
+ * not want to cache the result. Caching the result causes incorrect
+ * behaviour when there are multiple source addresses on the interface.
+ * The end result being that if the intended recipient is waiting on
+ * that interface for the packet he won't receive it because it will be
+ * delivered on the loopback interface and the IP_PKTINFO ipi_ifindex
+ * will be set to the loopback interface as well.
+ */
+ fi = NULL;
}
fnhe = NULL;
--
1.8.3.1

View File

@ -1,60 +0,0 @@
From ef42dfab80cff26850695de8c95c3e1ba294e05c Mon Sep 17 00:00:00 2001
From: Alex Shi <alex.shi@linaro.org>
Date: Thu, 12 Jan 2017 21:27:03 +0800
Subject: [PATCH] CPU / PM: expose pm_qos_resume_latency for CPUs
[ commit 37efa4b41ffb31dcdfc3beb97d47992bb2a083e5 from linux-stable ]
The cpu-dma PM QoS constraint impacts all the cpus in the system. There is no way
to let the user to choose a PM QoS constraint per cpu.
The following patch exposes to the userspace a per cpu based sysfs file
in order to let the userspace to change the value of the PM QoS latency
constraint.
This change is inoperative in its form and the cpuidle governors have to
take into account the per cpu latency constraint in addition to the
global cpu-dma latency constraint in order to operate properly.
BTW
The pm_qos_resume_latency usage defined in
Documentation/ABI/testing/sysfs-devices-power
The /sys/devices/.../power/pm_qos_resume_latency_us attribute
contains the PM QoS resume latency limit for the given device,
which is the maximum allowed time it can take to resume the
device, after it has been suspended at run time, from a resume
request to the moment the device will be ready to process I/O,
in microseconds. If it is equal to 0, however, this means that
the PM QoS resume latency may be arbitrary.
Signed-off-by: Alex Shi <alex.shi@linaro.org>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Signed-off-by: Alex Kozyrev <alex.kozyrev@windriver.com>
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
---
drivers/base/cpu.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/base/cpu.c b/drivers/base/cpu.c
index 65e786d..91d620f 100644
--- a/drivers/base/cpu.c
+++ b/drivers/base/cpu.c
@@ -15,6 +15,7 @@
#include <linux/percpu.h>
#include <linux/acpi.h>
#include <linux/tick.h>
+#include <linux/pm_qos.h>
#include "base.h"
@@ -318,6 +319,7 @@ int register_cpu(struct cpu *cpu, int num)
per_cpu(cpu_sys_devices, num) = &cpu->dev;
if (!error)
register_cpu_under_node(num, cpu_to_node(num));
+ dev_pm_qos_expose_latency_limit(&cpu->dev, 0);
#ifdef CONFIG_KEXEC
if (!error)
--
2.7.4

View File

@ -1,36 +0,0 @@
From 615791de3136070eb8fc9100aa8b5ead6905e56a Mon Sep 17 00:00:00 2001
Message-Id: <615791de3136070eb8fc9100aa8b5ead6905e56a.1528226387.git.Jim.Somerville@windriver.com>
In-Reply-To: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
References: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
From: Chris Friesen <chris.friesen@windriver.com>
Date: Wed, 11 Jan 2017 13:38:37 -0500
Subject: [PATCH 16/32] Enable building kernel with CONFIG_BLK_DEV_NBD
By default, the CentOS 7.3 kernel will fail to build if
CONFIG_BLK_DEV_NBD is enabled, either as module or builtin.
The issue seems to be due to the use of REQ_TYPE_SPECIAL in the
NBD code. Switching it to use REQ_TYPE_DRV_PRIV instead makes the
problem go away.
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
---
drivers/block/nbd.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/block/nbd.c b/drivers/block/nbd.c
index a40a4f0..e0c6b62 100644
--- a/drivers/block/nbd.c
+++ b/drivers/block/nbd.c
@@ -616,7 +616,7 @@ static int __nbd_ioctl(struct block_device *bdev, struct nbd_device *nbd,
fsync_bdev(bdev);
mutex_lock(&nbd->tx_lock);
blk_rq_init(NULL, &sreq);
- sreq.cmd_type = REQ_TYPE_SPECIAL;
+ sreq.cmd_type = REQ_TYPE_DRV_PRIV;
nbd_cmd(&sreq) = NBD_CMD_DISC;
/* Check again after getting mutex back. */
--
1.8.3.1

View File

@ -1,114 +0,0 @@
From 8eea2ba32882bcbcaf10588c99f7fec0104e9854 Mon Sep 17 00:00:00 2001
Message-Id: <8eea2ba32882bcbcaf10588c99f7fec0104e9854.1528226387.git.Jim.Somerville@windriver.com>
In-Reply-To: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
References: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
From: Alex Kozyrev <alex.kozyrev@windriver.com>
Date: Wed, 19 Jul 2017 02:25:15 -0500
Subject: [PATCH 20/32] Fix cacheinfo compilation issues for 3.10
Had to revert commit 7cc277b489b4fe91f42eb596b282879c2d13152e:
"Install the callbacks via the state machine and let the core invoke
the callbacks on the already online CPUs. No functional change."
There is no hotplug state machine in 3.10 kernel.
Also implemented cpumap_print_to_pagebuf() function in place.
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
---
drivers/base/cacheinfo.c | 65 ++++++++++++++++++++++++++++++++++++------------
1 file changed, 49 insertions(+), 16 deletions(-)
diff --git a/drivers/base/cacheinfo.c b/drivers/base/cacheinfo.c
index eb3af27..c924f7e 100644
--- a/drivers/base/cacheinfo.c
+++ b/drivers/base/cacheinfo.c
@@ -383,7 +383,12 @@ static ssize_t shared_cpumap_show_func(struct device *dev, bool list, char *buf)
struct cacheinfo *this_leaf = dev_get_drvdata(dev);
const struct cpumask *mask = &this_leaf->shared_cpu_map;
- return cpumap_print_to_pagebuf(list, buf, mask);
+ int len = list?
+ cpulist_scnprintf(buf, PAGE_SIZE-2, mask) :
+ cpumask_scnprintf(buf, PAGE_SIZE-2, mask);
+ buf[len++] = '\n';
+ buf[len] = '\0';
+ return len;
}
static ssize_t shared_cpu_map_show(struct device *dev,
@@ -633,30 +638,58 @@ err:
return rc;
}
-static int cacheinfo_cpu_online(unsigned int cpu)
+static void cache_remove_dev(unsigned int cpu)
{
- int rc = detect_cache_attributes(cpu);
+ if (!cpumask_test_cpu(cpu, &cache_dev_map))
+ return;
+ cpumask_clear_cpu(cpu, &cache_dev_map);
- if (rc)
- return rc;
- rc = cache_add_dev(cpu);
- if (rc)
- free_cache_attributes(cpu);
- return rc;
+ cpu_cache_sysfs_exit(cpu);
}
-static int cacheinfo_cpu_pre_down(unsigned int cpu)
+static int cacheinfo_cpu_callback(struct notifier_block *nfb,
+ unsigned long action, void *hcpu)
{
- if (cpumask_test_and_clear_cpu(cpu, &cache_dev_map))
- cpu_cache_sysfs_exit(cpu);
+ unsigned int cpu = (unsigned long)hcpu;
+ int rc = 0;
- free_cache_attributes(cpu);
- return 0;
+ switch (action & ~CPU_TASKS_FROZEN) {
+ case CPU_ONLINE:
+ rc = detect_cache_attributes(cpu);
+ if (!rc)
+ rc = cache_add_dev(cpu);
+ break;
+ case CPU_DEAD:
+ cache_remove_dev(cpu);
+ if (per_cpu_cacheinfo(cpu))
+ free_cache_attributes(cpu);
+ break;
+ }
+ return notifier_from_errno(rc);
}
static int __init cacheinfo_sysfs_init(void)
{
- return cpuhp_setup_state(CPUHP_AP_ONLINE_DYN, "base/cacheinfo:online",
- cacheinfo_cpu_online, cacheinfo_cpu_pre_down);
+ int cpu, rc = 0;
+
+ cpu_notifier_register_begin();
+
+ for_each_online_cpu(cpu) {
+ rc = detect_cache_attributes(cpu);
+ if (rc)
+ goto out;
+ rc = cache_add_dev(cpu);
+ if (rc) {
+ free_cache_attributes(cpu);
+ pr_err("error populating cacheinfo..cpu%d\n", cpu);
+ goto out;
+ }
+ }
+ __hotcpu_notifier(cacheinfo_cpu_callback, 0);
+
+out:
+ cpu_notifier_register_done();
+ return rc;
}
+
device_initcall(cacheinfo_sysfs_init);
--
1.8.3.1

View File

@ -1,25 +1,23 @@
From 97a7d3c050d7996f6a630184fa428a4d170c2ea8 Mon Sep 17 00:00:00 2001 From ad08e36ea088aebb3c65f98b5ea87a9f095155b3 Mon Sep 17 00:00:00 2001
Message-Id: <97a7d3c050d7996f6a630184fa428a4d170c2ea8.1528226387.git.Jim.Somerville@windriver.com>
In-Reply-To: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
References: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
From: Chris Friesen <chris.friesen@windriver.com> From: Chris Friesen <chris.friesen@windriver.com>
Date: Thu, 12 May 2016 18:00:00 -0400 Date: Thu, 12 May 2016 18:00:00 -0400
Subject: [PATCH 09/32] Make kernel start eth devices at offset Subject: [PATCH 05/10] Make kernel start eth devices at offset
In order to avoid naming collisions, we want to make the kernel In order to avoid naming collisions, we want to make the kernel
start naming its "ethX" devices at eth1000 instead of eth0. This start naming its "ethX" devices at eth1000 instead of eth0. This
will let us rename to a range starting at eth0. will let us rename to a range starting at eth0.
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com> Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
Signed-off-by: Zhang Zhiguo <zhangzhg@neusoft.com>
--- ---
net/core/dev.c | 6 ++++++ net/core/dev.c | 6 ++++++
1 file changed, 6 insertions(+) 1 file changed, 6 insertions(+)
diff --git a/net/core/dev.c b/net/core/dev.c diff --git a/net/core/dev.c b/net/core/dev.c
index 1425f9d..db04f3b 100644 index 6a531ca..980860d 100644
--- a/net/core/dev.c --- a/net/core/dev.c
+++ b/net/core/dev.c +++ b/net/core/dev.c
@@ -1092,6 +1092,12 @@ static int __dev_alloc_name(struct net *net, const char *name, char *buf) @@ -1100,6 +1100,12 @@ static int __dev_alloc_name(struct net *net, const char *name, char *buf)
set_bit(i, inuse); set_bit(i, inuse);
} }
@ -33,5 +31,5 @@ index 1425f9d..db04f3b 100644
free_page((unsigned long) inuse); free_page((unsigned long) inuse);
} }
-- --
1.8.3.1 2.7.4

View File

@ -18,30 +18,35 @@ This is exposed to userspace via the prctl() call with the
PR_DO_NOTIFY_TASK_STATE option. PR_DO_NOTIFY_TASK_STATE option.
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com> Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
Signed-off-by: Zhang Zhiguo <zhangzhg@neusoft.com>
Signed-off-by: Shuicheng Lin <shuicheng.lin@intel.com>
Signed-off-by: Austin Sun <austin.sun@intel.com>
--- ---
include/linux/init_task.h | 9 ++ include/linux/init_task.h | 9 ++
include/linux/sched.h | 6 ++ include/linux/sched.h | 6 +
include/uapi/linux/prctl.h | 18 ++++ include/uapi/linux/prctl.h | 18 +++
init/Kconfig | 15 +++ init/Kconfig | 15 +++
init/init_task.c | 1 +
kernel/Makefile | 1 + kernel/Makefile | 1 +
kernel/death_notify.c | 227 +++++++++++++++++++++++++++++++++++++++++++++ kernel/death_notify.c | 228 +++++++++++++++++++++++++++++++++++++
kernel/death_notify.h | 45 +++++++++ kernel/death_notify.h | 46 ++++++++
kernel/exit.c | 6 ++ kernel/exit.c | 6 +
kernel/fork.c | 4 + kernel/fork.c | 4 +
kernel/signal.c | 11 +++ kernel/signal.c | 11 ++
kernel/sys.c | 9 ++ kernel/sys.c | 8 ++
11 files changed, 351 insertions(+) 12 files changed, 353 insertions(+)
create mode 100644 kernel/death_notify.c create mode 100644 kernel/death_notify.c
create mode 100644 kernel/death_notify.h create mode 100644 kernel/death_notify.h
diff --git a/include/linux/init_task.h b/include/linux/init_task.h diff --git a/include/linux/init_task.h b/include/linux/init_task.h
index d8c82e0..ba0c12e 100644 index a7083a45a..1ad2341b3 100644
--- a/include/linux/init_task.h --- a/include/linux/init_task.h
+++ b/include/linux/init_task.h +++ b/include/linux/init_task.h
@@ -77,6 +77,14 @@ extern struct nsproxy init_nsproxy; @@ -24,6 +24,15 @@
.signalfd_wqh = __WAIT_QUEUE_HEAD_INITIALIZER(sighand.signalfd_wqh), \ extern struct files_struct init_files;
} extern struct fs_struct init_fs;
extern struct nsproxy init_nsproxy;
+
+#ifdef CONFIG_SIGEXIT +#ifdef CONFIG_SIGEXIT
+#define INIT_SIGEXIT(tsk) \ +#define INIT_SIGEXIT(tsk) \
+ .notify = LIST_HEAD_INIT(tsk.notify), \ + .notify = LIST_HEAD_INIT(tsk.notify), \
@ -51,22 +56,14 @@ index d8c82e0..ba0c12e 100644
+#endif +#endif
+ +
extern struct group_info init_groups; extern struct group_info init_groups;
extern struct cred init_cred;
#define INIT_STRUCT_PID { \
@@ -231,6 +239,7 @@ extern struct task_group root_task_group;
.alloc_lock = __SPIN_LOCK_UNLOCKED(tsk.alloc_lock), \
.journal_info = NULL, \
.cpu_timers = INIT_CPU_TIMERS(tsk.cpu_timers), \
+ INIT_SIGEXIT(tsk) \
.pi_lock = __RAW_SPIN_LOCK_UNLOCKED(tsk.pi_lock), \
.timer_slack_ns = 50000, /* 50 usec default slack */ \
INIT_TIMER_LIST \
diff --git a/include/linux/sched.h b/include/linux/sched.h diff --git a/include/linux/sched.h b/include/linux/sched.h
index 97ff026..0785453 100644 index 91596900f..5e34f5021 100644
--- a/include/linux/sched.h --- a/include/linux/sched.h
+++ b/include/linux/sched.h +++ b/include/linux/sched.h
@@ -1686,6 +1686,12 @@ struct task_struct { @@ -1083,6 +1083,12 @@ struct task_struct {
short il_next; short il_prev;
short pref_node_fork; short pref_node_fork;
#endif #endif
+#ifdef CONFIG_SIGEXIT +#ifdef CONFIG_SIGEXIT
@ -79,12 +76,12 @@ index 97ff026..0785453 100644
int numa_scan_seq; int numa_scan_seq;
unsigned int numa_scan_period; unsigned int numa_scan_period;
diff --git a/include/uapi/linux/prctl.h b/include/uapi/linux/prctl.h diff --git a/include/uapi/linux/prctl.h b/include/uapi/linux/prctl.h
index a817b5c..2cf7776 100644 index 327319b88..708484598 100644
--- a/include/uapi/linux/prctl.h --- a/include/uapi/linux/prctl.h
+++ b/include/uapi/linux/prctl.h +++ b/include/uapi/linux/prctl.h
@@ -55,6 +55,24 @@ @@ -63,6 +63,24 @@
#define PR_SET_NAME 15 /* Set process name */ # define PR_ENDIAN_LITTLE 1 /* True little endian mode */
#define PR_GET_NAME 16 /* Get process name */ # define PR_ENDIAN_PPC_LITTLE 2 /* "PowerPC" pseudo little endian */
+#ifdef CONFIG_SIGEXIT +#ifdef CONFIG_SIGEXIT
+#define PR_DO_NOTIFY_TASK_STATE 17 /* Set/get notification for task +#define PR_DO_NOTIFY_TASK_STATE 17 /* Set/get notification for task
@ -104,14 +101,14 @@ index a817b5c..2cf7776 100644
+}; +};
+#endif +#endif
+ +
/* Get/set process endian */ /* Get/set process seccomp mode */
#define PR_GET_ENDIAN 19 #define PR_GET_SECCOMP 21
#define PR_SET_ENDIAN 20 #define PR_SET_SECCOMP 22
diff --git a/init/Kconfig b/init/Kconfig diff --git a/init/Kconfig b/init/Kconfig
index 1d645a1..37e48c0 100644 index 7625bea9c..f88a36fef 100644
--- a/init/Kconfig --- a/init/Kconfig
+++ b/init/Kconfig +++ b/init/Kconfig
@@ -1581,6 +1581,21 @@ config VM_EVENT_COUNTERS @@ -1610,6 +1610,21 @@ config VM_EVENT_COUNTERS
on EXPERT systems. /proc/vmstat will only show page counts on EXPERT systems. /proc/vmstat will only show page counts
if VM event counters are disabled. if VM event counters are disabled.
@ -133,11 +130,23 @@ index 1d645a1..37e48c0 100644
config SLUB_DEBUG config SLUB_DEBUG
default y default y
bool "Enable SLUB debugging support" if EXPERT bool "Enable SLUB debugging support" if EXPERT
diff --git a/init/init_task.c b/init/init_task.c
index f2d3b023f..1623a4273 100644
--- a/init/init_task.c
+++ b/init/init_task.c
@@ -123,6 +123,7 @@ struct task_struct init_task
.alloc_lock = __SPIN_LOCK_UNLOCKED(init_task.alloc_lock),
.journal_info = NULL,
INIT_CPU_TIMERS(init_task)
+ INIT_SIGEXIT(init_task)
.pi_lock = __RAW_SPIN_LOCK_UNLOCKED(init_task.pi_lock),
.timer_slack_ns = 50000, /* 50 usec default slack */
INIT_TIMER_LIST
diff --git a/kernel/Makefile b/kernel/Makefile diff --git a/kernel/Makefile b/kernel/Makefile
index 762218c..d357e7d 100644 index aebf6a889..2669df332 100644
--- a/kernel/Makefile --- a/kernel/Makefile
+++ b/kernel/Makefile +++ b/kernel/Makefile
@@ -120,6 +120,7 @@ obj-$(CONFIG_TRACEPOINTS) += trace/ @@ -104,6 +104,7 @@ obj-$(CONFIG_TRACEPOINTS) += trace/
obj-$(CONFIG_IRQ_WORK) += irq_work.o obj-$(CONFIG_IRQ_WORK) += irq_work.o
obj-$(CONFIG_CPU_PM) += cpu_pm.o obj-$(CONFIG_CPU_PM) += cpu_pm.o
obj-$(CONFIG_BPF) += bpf/ obj-$(CONFIG_BPF) += bpf/
@ -147,10 +156,10 @@ index 762218c..d357e7d 100644
diff --git a/kernel/death_notify.c b/kernel/death_notify.c diff --git a/kernel/death_notify.c b/kernel/death_notify.c
new file mode 100644 new file mode 100644
index 0000000..5eb8bfc index 000000000..5819d35a2
--- /dev/null --- /dev/null
+++ b/kernel/death_notify.c +++ b/kernel/death_notify.c
@@ -0,0 +1,227 @@ @@ -0,0 +1,228 @@
+/* +/*
+ * kernel/death_notify.c, Process death notification support + * kernel/death_notify.c, Process death notification support
+ * + *
@ -172,11 +181,12 @@ index 0000000..5eb8bfc
+ */ + */
+ +
+#include <linux/errno.h> +#include <linux/errno.h>
+#include <linux/signal.h>
+#include <linux/sched.h> +#include <linux/sched.h>
+#include <linux/sched/task.h>
+#include <linux/slab.h> +#include <linux/slab.h>
+#include <linux/prctl.h> +#include <linux/prctl.h>
+#include <linux/uaccess.h> +#include <linux/uaccess.h>
+
+#include "death_notify.h" +#include "death_notify.h"
+ +
+static void unlink_status_notifier(struct signotifier *n) +static void unlink_status_notifier(struct signotifier *n)
@ -224,7 +234,6 @@ index 0000000..5eb8bfc
+ list_add_tail(&node->monitor_list, &current->monitor); + list_add_tail(&node->monitor_list, &current->monitor);
+} +}
+ +
+
+/* Returns 0 if arguments are valid, 1 if they are not. */ +/* Returns 0 if arguments are valid, 1 if they are not. */
+static int invalid_args(struct task_state_notify_info *args) +static int invalid_args(struct task_state_notify_info *args)
+{ +{
@ -259,7 +268,7 @@ index 0000000..5eb8bfc
+ * + *
+ * Must be called holding a lock on tasklist_lock. + * Must be called holding a lock on tasklist_lock.
+ */ + */
+void do_notify_others(struct task_struct *tsk, struct siginfo *info) +void do_notify_others(struct task_struct *tsk, struct kernel_siginfo *info)
+{ +{
+ struct signotifier *node; + struct signotifier *node;
+ unsigned int events; + unsigned int events;
@ -272,7 +281,7 @@ index 0000000..5eb8bfc
+ list_for_each_entry(node, &tsk->notify, notify_list) { + list_for_each_entry(node, &tsk->notify, notify_list) {
+ if (events & node->events) { + if (events & node->events) {
+ info->si_signo = node->sig; + info->si_signo = node->sig;
+ group_send_sig_info(node->sig, info, node->notify_tsk); + group_send_sig_info(node->sig, info, node->notify_tsk, PIDTYPE_TGID);
+ } + }
+ } + }
+} +}
@ -378,12 +387,13 @@ index 0000000..5eb8bfc
+out: +out:
+ return err; + return err;
+} +}
+
diff --git a/kernel/death_notify.h b/kernel/death_notify.h diff --git a/kernel/death_notify.h b/kernel/death_notify.h
new file mode 100644 new file mode 100644
index 0000000..b2b8e8c index 000000000..14a0995b7
--- /dev/null --- /dev/null
+++ b/kernel/death_notify.h +++ b/kernel/death_notify.h
@@ -0,0 +1,45 @@ @@ -0,0 +1,46 @@
+/* +/*
+ * kernel/death_notify.h, Process death notification support + * kernel/death_notify.h, Process death notification support
+ * + *
@ -418,22 +428,23 @@ index 0000000..b2b8e8c
+ +
+extern int do_notify_task_state(unsigned long arg); +extern int do_notify_task_state(unsigned long arg);
+extern void do_notify_others(struct task_struct *tsk, +extern void do_notify_others(struct task_struct *tsk,
+ struct siginfo *info); + struct kernel_siginfo *info);
+extern void release_notify_others(struct task_struct *p); +extern void release_notify_others(struct task_struct *p);
+ +
+#else /* !CONFIG_SIGEXIT */ +#else /* !CONFIG_SIGEXIT */
+ +
+static inline void do_notify_others(struct task_struct *tsk, +static inline void do_notify_others(struct task_struct *tsk,
+ struct siginfo *info) {} + struct kernel_siginfo *info) {}
+static inline void release_notify_others(struct task_struct *p) {} +static inline void release_notify_others(struct task_struct *p) {}
+ +
+#endif /* CONFIG_SIGEXIT */ +#endif /* CONFIG_SIGEXIT */
+#endif +#endif
+
diff --git a/kernel/exit.c b/kernel/exit.c diff --git a/kernel/exit.c b/kernel/exit.c
index 8a908ea..448a3c3 100644 index 6199d4812..0467ef691 100644
--- a/kernel/exit.c --- a/kernel/exit.c
+++ b/kernel/exit.c +++ b/kernel/exit.c
@@ -59,6 +59,9 @@ @@ -67,6 +67,9 @@
#include <asm/unistd.h> #include <asm/unistd.h>
#include <asm/pgtable.h> #include <asm/pgtable.h>
#include <asm/mmu_context.h> #include <asm/mmu_context.h>
@ -441,12 +452,12 @@ index 8a908ea..448a3c3 100644
+#include "death_notify.h" +#include "death_notify.h"
+#endif +#endif
static void exit_mm(struct task_struct * tsk); static void __unhash_process(struct task_struct *p, bool group_dead)
{
@@ -184,6 +187,9 @@ repeat: @@ -196,6 +199,9 @@ void release_task(struct task_struct *p)
proc_flush_task(p); proc_flush_task(p);
tasklist_write_lock_irq(); write_lock_irq(&tasklist_lock);
+#ifdef CONFIG_SIGEXIT +#ifdef CONFIG_SIGEXIT
+ release_notify_others(p); + release_notify_others(p);
+#endif +#endif
@ -454,10 +465,10 @@ index 8a908ea..448a3c3 100644
__exit_signal(p); __exit_signal(p);
diff --git a/kernel/fork.c b/kernel/fork.c diff --git a/kernel/fork.c b/kernel/fork.c
index 6bda4c0..f3cd3ad 100644 index 63245141d..c20efb927 100644
--- a/kernel/fork.c --- a/kernel/fork.c
+++ b/kernel/fork.c +++ b/kernel/fork.c
@@ -1518,6 +1518,10 @@ static struct task_struct *copy_process(unsigned long clone_flags, @@ -1953,6 +1953,10 @@ static __latent_entropy struct task_struct *copy_process(
p->sequential_io = 0; p->sequential_io = 0;
p->sequential_io_avg = 0; p->sequential_io_avg = 0;
#endif #endif
@ -469,10 +480,10 @@ index 6bda4c0..f3cd3ad 100644
/* Perform scheduler related setup. Assign this task to a CPU. */ /* Perform scheduler related setup. Assign this task to a CPU. */
retval = sched_fork(clone_flags, p); retval = sched_fork(clone_flags, p);
diff --git a/kernel/signal.c b/kernel/signal.c diff --git a/kernel/signal.c b/kernel/signal.c
index 59e84a2..728daa9 100644 index f4d847cc4..c25b78c05 100644
--- a/kernel/signal.c --- a/kernel/signal.c
+++ b/kernel/signal.c +++ b/kernel/signal.c
@@ -47,6 +47,9 @@ @@ -53,6 +53,9 @@
#include <asm/siginfo.h> #include <asm/siginfo.h>
#include <asm/cacheflush.h> #include <asm/cacheflush.h>
#include "audit.h" /* audit_signal_info() */ #include "audit.h" /* audit_signal_info() */
@ -482,7 +493,7 @@ index 59e84a2..728daa9 100644
/* /*
* SLAB caches for signal bits. * SLAB caches for signal bits.
@@ -1849,6 +1852,10 @@ bool do_notify_parent(struct task_struct *tsk, int sig) @@ -1989,6 +1992,10 @@ bool do_notify_parent(struct task_struct *tsk, int sig)
__wake_up_parent(tsk, tsk->parent); __wake_up_parent(tsk, tsk->parent);
spin_unlock_irqrestore(&psig->siglock, flags); spin_unlock_irqrestore(&psig->siglock, flags);
@ -493,7 +504,7 @@ index 59e84a2..728daa9 100644
return autoreap; return autoreap;
} }
@@ -1920,6 +1927,10 @@ static void do_notify_parent_cldstop(struct task_struct *tsk, @@ -2061,6 +2068,10 @@ static void do_notify_parent_cldstop(struct task_struct *tsk,
*/ */
__wake_up_parent(tsk, parent); __wake_up_parent(tsk, parent);
spin_unlock_irqrestore(&sighand->siglock, flags); spin_unlock_irqrestore(&sighand->siglock, flags);
@ -503,23 +514,22 @@ index 59e84a2..728daa9 100644
+#endif +#endif
} }
static inline int may_ptrace_stop(void) static inline bool may_ptrace_stop(void)
diff --git a/kernel/sys.c b/kernel/sys.c diff --git a/kernel/sys.c b/kernel/sys.c
index e79ea7e..5d43b93 100644 index 8a0fab918..e957bd5a5 100644
--- a/kernel/sys.c --- a/kernel/sys.c
+++ b/kernel/sys.c +++ b/kernel/sys.c
@@ -67,6 +67,10 @@ @@ -75,6 +75,9 @@
/* Hardening for Spectre-v1 */
#include <linux/nospec.h> #include <linux/nospec.h>
#include "uid16.h"
+#ifdef CONFIG_SIGEXIT +#ifdef CONFIG_SIGEXIT
+#include "death_notify.h" +#include "death_notify.h"
+#endif +#endif
+
#ifndef SET_UNALIGN_CTL #ifndef SET_UNALIGN_CTL
# define SET_UNALIGN_CTL(a,b) (-EINVAL) # define SET_UNALIGN_CTL(a, b) (-EINVAL)
#endif @@ -2409,6 +2412,11 @@ SYSCALL_DEFINE5(prctl, int, option, unsigned long, arg2, unsigned long, arg3,
@@ -2478,6 +2482,11 @@ SYSCALL_DEFINE5(prctl, int, option, unsigned long, arg2, unsigned long, arg3,
else else
error = PR_MCE_KILL_DEFAULT; error = PR_MCE_KILL_DEFAULT;
break; break;
@ -532,5 +542,5 @@ index e79ea7e..5d43b93 100644
error = prctl_set_mm(arg2, arg3, arg4, arg5); error = prctl_set_mm(arg2, arg3, arg4, arg5);
break; break;
-- --
2.7.4 2.19.1

View File

@ -1,24 +1,22 @@
From a0da95b0152227a9a80d98edf5fc0af345479dce Mon Sep 17 00:00:00 2001 From 43ba972baa0e075a185e34a579f920e0a3e40455 Mon Sep 17 00:00:00 2001
Message-Id: <a0da95b0152227a9a80d98edf5fc0af345479dce.1528226387.git.Jim.Somerville@windriver.com>
In-Reply-To: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
References: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
From: Dahir Osman <dahir.osman@windriver.com> From: Dahir Osman <dahir.osman@windriver.com>
Date: Wed, 13 Jan 2016 10:01:11 -0500 Date: Wed, 13 Jan 2016 10:01:11 -0500
Subject: [PATCH 12/32] PCI: Add ACS quirk for Intel Fortville NICs Subject: [PATCH 02/10] PCI: Add ACS quirk for Intel Fortville NICs
Use quirks to determine isolation for now until a later kernel can Use quirks to determine isolation for now until a later kernel can
properly read the Fortville ACS capabilities. properly read the Fortville ACS capabilities.
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com> Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
Signed-off-by: Zhang Zhiguo <zhangzhg@neusoft.com>
--- ---
drivers/pci/quirks.c | 4 ++++ drivers/pci/quirks.c | 4 ++++
1 file changed, 4 insertions(+) 1 file changed, 4 insertions(+)
diff --git a/drivers/pci/quirks.c b/drivers/pci/quirks.c diff --git a/drivers/pci/quirks.c b/drivers/pci/quirks.c
index 5614e3f..4a0bfed 100644 index 36f8e32..03c25f9 100644
--- a/drivers/pci/quirks.c --- a/drivers/pci/quirks.c
+++ b/drivers/pci/quirks.c +++ b/drivers/pci/quirks.c
@@ -4401,6 +4401,10 @@ static const struct pci_dev_acs_enabled { @@ -4422,6 +4422,10 @@ static const struct pci_dev_acs_enabled {
/* I219 */ /* I219 */
{ PCI_VENDOR_ID_INTEL, 0x15b7, pci_quirk_mf_endpoint_acs }, { PCI_VENDOR_ID_INTEL, 0x15b7, pci_quirk_mf_endpoint_acs },
{ PCI_VENDOR_ID_INTEL, 0x15b8, pci_quirk_mf_endpoint_acs }, { PCI_VENDOR_ID_INTEL, 0x15b8, pci_quirk_mf_endpoint_acs },
@ -26,9 +24,9 @@ index 5614e3f..4a0bfed 100644
+ { PCI_VENDOR_ID_INTEL, 0x1572, pci_quirk_mf_endpoint_acs }, + { PCI_VENDOR_ID_INTEL, 0x1572, pci_quirk_mf_endpoint_acs },
+ { PCI_VENDOR_ID_INTEL, 0x1586, pci_quirk_mf_endpoint_acs }, + { PCI_VENDOR_ID_INTEL, 0x1586, pci_quirk_mf_endpoint_acs },
+ { PCI_VENDOR_ID_INTEL, 0x1583, pci_quirk_mf_endpoint_acs }, + { PCI_VENDOR_ID_INTEL, 0x1583, pci_quirk_mf_endpoint_acs },
/* Intel PCH root ports */ /* QCOM QDF2xxx root ports */
{ PCI_VENDOR_ID_INTEL, PCI_ANY_ID, pci_quirk_intel_pch_acs }, { PCI_VENDOR_ID_QCOM, 0x0400, pci_quirk_qcom_rp_acs },
{ PCI_VENDOR_ID_INTEL, PCI_ANY_ID, pci_quirk_intel_spt_pch_acs }, { PCI_VENDOR_ID_QCOM, 0x0401, pci_quirk_qcom_rp_acs },
-- --
1.8.3.1 2.7.4

View File

@ -1,375 +0,0 @@
From 7e592781c3f5635f8b455cfcc2daaca572c633da Mon Sep 17 00:00:00 2001
Message-Id: <7e592781c3f5635f8b455cfcc2daaca572c633da.1528226387.git.Jim.Somerville@windriver.com>
In-Reply-To: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
References: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
From: Kam Nasim <kam.nasim@windriver.com>
Date: Wed, 23 Aug 2017 17:58:12 -0400
Subject: [PATCH 25/32] US101216: IMA support in Titanium kernel
facilitate building the IMA subsytem out-of-the-kernel tree as a Kernel
module (for which CONFIG_IMA and CONFIG_INTEGRITY will be undefined) by:
- exporting certain function symbols which will be linked to the kernel
module. This includes redefining the export symbols for kernel
functions such that when the kernel module loads, it dynamically points
to those new function definations and reverts to Kernel default
definitions on module deinit
- enabling inode readcount
- modification to ima_file_check to pass in file OPEN status
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
Signed-off-by: Robin Lu <bin1.lu@intel.com>
---
fs/namei.c | 2 +-
fs/nfsd/vfs.c | 2 +-
fs/xattr.c | 1 +
include/linux/fs.h | 15 +------
include/linux/ima.h | 77 +++++++-------------------------
include/linux/integrity.h | 22 ++++-----
security/security.c | 111 +++++++++++++++++++++++++++++++++++++++++++++-
7 files changed, 140 insertions(+), 90 deletions(-)
diff --git a/fs/namei.c b/fs/namei.c
index 9f90b63..bf91ea0 100644
--- a/fs/namei.c
+++ b/fs/namei.c
@@ -3243,7 +3243,7 @@ opened:
error = open_check_o_direct(file);
if (error)
goto exit_fput;
- error = ima_file_check(file, op->acc_mode);
+ error = ima_file_check(file, op->acc_mode, *opened);
if (error)
goto exit_fput;
diff --git a/fs/nfsd/vfs.c b/fs/nfsd/vfs.c
index 00e98c3..cb9250e 100644
--- a/fs/nfsd/vfs.c
+++ b/fs/nfsd/vfs.c
@@ -898,7 +898,7 @@ nfsd_open(struct svc_rqst *rqstp, struct svc_fh *fhp, umode_t type,
goto out_nfserr;
}
- host_err = ima_file_check(file, may_flags);
+ host_err = ima_file_check(file, may_flags, 0);
if (host_err) {
fput(file);
goto out_nfserr;
diff --git a/fs/xattr.c b/fs/xattr.c
index e540aca..cc307ec 100644
--- a/fs/xattr.c
+++ b/fs/xattr.c
@@ -208,6 +208,7 @@ vfs_getxattr_alloc(struct dentry *dentry, const char *name, char **xattr_value,
*xattr_value = value;
return error;
}
+EXPORT_SYMBOL_GPL(vfs_getxattr_alloc);
/* Compare an extended attribute value with the given value */
int vfs_xattr_cmp(struct dentry *dentry, const char *xattr_name,
diff --git a/include/linux/fs.h b/include/linux/fs.h
index eb6f994..2dbaf80 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -681,9 +681,8 @@ struct inode {
struct fsnotify_mark_connector __rcu *i_fsnotify_marks)
#endif
-#if defined(CONFIG_IMA) && defined(CONFIG_X86_64)
atomic_t i_readcount; /* struct files open RO */
-#endif
+
void *i_private; /* fs or device private pointer */
};
@@ -2852,7 +2851,6 @@ static inline bool inode_is_open_for_write(const struct inode *inode)
return atomic_read(&inode->i_writecount) > 0;
}
-#ifdef CONFIG_IMA
static inline void i_readcount_dec(struct inode *inode)
{
BUG_ON(!atomic_read(&inode->i_readcount));
@@ -2862,16 +2860,7 @@ static inline void i_readcount_inc(struct inode *inode)
{
atomic_inc(&inode->i_readcount);
}
-#else
-static inline void i_readcount_dec(struct inode *inode)
-{
- return;
-}
-static inline void i_readcount_inc(struct inode *inode)
-{
- return;
-}
-#endif
+
extern int do_pipe_flags(int *, int);
extern int kernel_read(struct file *, loff_t, char *, unsigned long);
diff --git a/include/linux/ima.h b/include/linux/ima.h
index 1b7f268..9fee45c 100644
--- a/include/linux/ima.h
+++ b/include/linux/ima.h
@@ -13,64 +13,21 @@
#include <linux/fs.h>
struct linux_binprm;
-#ifdef CONFIG_IMA
-extern int ima_bprm_check(struct linux_binprm *bprm);
-extern int ima_file_check(struct file *file, int mask);
-extern void ima_file_free(struct file *file);
-extern int ima_file_mmap(struct file *file, unsigned long prot);
-extern int ima_module_check(struct file *file);
-
-#else
-static inline int ima_bprm_check(struct linux_binprm *bprm)
-{
- return 0;
-}
-
-static inline int ima_file_check(struct file *file, int mask)
-{
- return 0;
-}
-
-static inline void ima_file_free(struct file *file)
-{
- return;
-}
-
-static inline int ima_file_mmap(struct file *file, unsigned long prot)
-{
- return 0;
-}
-
-static inline int ima_module_check(struct file *file)
-{
- return 0;
-}
-
-#endif /* CONFIG_IMA */
-
-#ifdef CONFIG_IMA_APPRAISE
-extern void ima_inode_post_setattr(struct dentry *dentry);
-extern int ima_inode_setxattr(struct dentry *dentry, const char *xattr_name,
+/*
+ * The IMA Kernel module has to redefine these symbols so that
+ * the kernel module can link a dynamic function, as a hook into
+ * the Kernel FS calls (which use these)
+ */
+/* ifdef CONFIG_IMA */
+extern int (*ima_bprm_check)(struct linux_binprm *bprm);
+extern int (*ima_file_check)(struct file *file, int mask, int opened);
+extern void (*ima_file_free)(struct file *file);
+extern int (*ima_file_mmap)(struct file *file, unsigned long prot);
+extern int (*ima_module_check)(struct file *file);
+
+/* ifdef CONFIG_IMA_APPRAISE */
+extern void (*ima_inode_post_setattr)(struct dentry *dentry);
+extern int (*ima_inode_setxattr)(struct dentry *dentry, const char *xattr_name,
const void *xattr_value, size_t xattr_value_len);
-extern int ima_inode_removexattr(struct dentry *dentry, const char *xattr_name);
-#else
-static inline void ima_inode_post_setattr(struct dentry *dentry)
-{
- return;
-}
-
-static inline int ima_inode_setxattr(struct dentry *dentry,
- const char *xattr_name,
- const void *xattr_value,
- size_t xattr_value_len)
-{
- return 0;
-}
-
-static inline int ima_inode_removexattr(struct dentry *dentry,
- const char *xattr_name)
-{
- return 0;
-}
-#endif /* CONFIG_IMA_APPRAISE */
-#endif /* _LINUX_IMA_H */
+extern int (*ima_inode_removexattr)(struct dentry *dentry, const char *xattr_name);
+#endif
diff --git a/include/linux/integrity.h b/include/linux/integrity.h
index 83222ce..a5040b6 100644
--- a/include/linux/integrity.h
+++ b/include/linux/integrity.h
@@ -21,20 +21,14 @@ enum integrity_status {
};
/* List of EVM protected security xattrs */
-#ifdef CONFIG_INTEGRITY
-extern struct integrity_iint_cache *integrity_inode_get(struct inode *inode);
-extern void integrity_inode_free(struct inode *inode);
+/*
+ * The Integrity Kernel module has to redefine these symbols so that
+ * the kernel module can link a dynamic function, as a hook into
+ * the Kernel Security subsystem (which use these)
+ */
-#else
-static inline struct integrity_iint_cache *
- integrity_inode_get(struct inode *inode)
-{
- return NULL;
-}
+/* #ifdef CONFIG_INTEGRITY */
+extern struct integrity_iint_cache *(*integrity_inode_get)(struct inode *inode);
+extern void (*integrity_inode_free)(struct inode *inode);
-static inline void integrity_inode_free(struct inode *inode)
-{
- return;
-}
-#endif /* CONFIG_INTEGRITY */
#endif /* _LINUX_INTEGRITY_H */
diff --git a/security/security.c b/security/security.c
index f069482..646a0e3 100644
--- a/security/security.c
+++ b/security/security.c
@@ -161,6 +161,110 @@ EXPORT_SYMBOL(unregister_lsm_notifier);
/* Security operations */
+/*
+ * Export these symbols since the IMA and Integrity
+ * modules will redefine it. We do this EXPORT in
+ * the security endpoint as this is the last Kernel
+ * hook into the Integrity / IMA modules
+ */
+#ifndef CONFIG_INTEGRITY
+static struct integrity_iint_cache* integrity_inode_get_kmod(struct inode *inode)
+{
+ return NULL;
+}
+
+static void integrity_inode_free_kmod(struct inode *inode)
+{
+ return;
+}
+
+struct integrity_iint_cache *
+ (*integrity_inode_get)(struct inode *) = &integrity_inode_get_kmod;
+void
+ (*integrity_inode_free)(struct inode*) = &integrity_inode_free_kmod;
+
+EXPORT_SYMBOL_GPL(integrity_inode_get);
+EXPORT_SYMBOL_GPL(integrity_inode_free);
+#endif
+
+#ifndef CONFIG_IMA
+static int ima_bprm_check_kmod(struct linux_binprm *bprm)
+{
+ return 0;
+}
+
+static int ima_file_check_kmod(struct file *file, int mask, int opened)
+{
+ return 0;
+}
+
+static void ima_file_free_kmod(struct file *file)
+{
+ return;
+}
+
+static int ima_file_mmap_kmod(struct file *file, unsigned long prot)
+{
+ return 0;
+}
+
+static int ima_module_check_kmod(struct file *file)
+{
+ return 0;
+}
+
+int
+ (*ima_bprm_check)(struct linux_binprm *) = &ima_bprm_check_kmod;
+int
+ (*ima_file_check)(struct file *, int, int) = &ima_file_check_kmod;
+void
+ (*ima_file_free)(struct file *) = &ima_file_free_kmod;
+int
+ (*ima_file_mmap)(struct file*, unsigned long) = &ima_file_mmap_kmod;
+int
+ (*ima_module_check)(struct file *) = &ima_module_check_kmod;
+
+EXPORT_SYMBOL_GPL(ima_bprm_check);
+EXPORT_SYMBOL_GPL(ima_file_check);
+EXPORT_SYMBOL_GPL(ima_file_free);
+EXPORT_SYMBOL_GPL(ima_file_mmap);
+EXPORT_SYMBOL_GPL(ima_module_check);
+#endif
+
+#ifndef CONFIG_IMA_APPRAISE
+static void ima_inode_post_setattr_kmod(struct dentry *dentry)
+{
+ return;
+}
+
+static int ima_inode_setxattr_kmod(struct dentry *dentry,
+ const char *xattr_name,
+ const void *xattr_value,
+ size_t xattr_value_len)
+{
+ return 0;
+}
+
+static int ima_inode_removexattr_kmod(struct dentry *dentry,
+ const char *xattr_name)
+{
+ return 0;
+}
+
+void
+ (*ima_inode_post_setattr)(struct dentry *) = &ima_inode_post_setattr_kmod;
+int
+ (*ima_inode_setxattr)(struct dentry *, const char *,
+ const void *, size_t) = &ima_inode_setxattr_kmod;
+int
+ (*ima_inode_removexattr)(struct dentry *,
+ const char *) = &ima_inode_removexattr_kmod;
+
+EXPORT_SYMBOL_GPL(ima_inode_post_setattr);
+EXPORT_SYMBOL_GPL(ima_inode_setxattr);
+EXPORT_SYMBOL_GPL(ima_inode_removexattr);
+#endif
+
int security_ptrace_access_check(struct task_struct *child, unsigned int mode)
{
#ifdef CONFIG_SECURITY_YAMA_STACKED
@@ -718,8 +822,11 @@ EXPORT_SYMBOL(security_inode_listsecurity);
void security_inode_getsecid(struct inode *inode, u32 *secid)
{
- security_ops->inode_getsecid(inode, secid);
+ if (unlikely(IS_PRIVATE(inode)))
+ return;
+ security_ops->inode_getsecid(inode, secid);
}
+EXPORT_SYMBOL_GPL(security_inode_getsecid);
int security_inode_copy_up(struct dentry *src, struct cred **new)
{
@@ -1528,6 +1635,7 @@ int security_audit_rule_init(u32 field, u32 op, char *rulestr, void **lsmrule)
{
return security_ops->audit_rule_init(field, op, rulestr, lsmrule);
}
+EXPORT_SYMBOL_GPL(security_audit_rule_init);
int security_audit_rule_known(struct audit_krule *krule)
{
@@ -1544,6 +1652,7 @@ int security_audit_rule_match(u32 secid, u32 field, u32 op, void *lsmrule,
{
return security_ops->audit_rule_match(secid, field, op, lsmrule, actx);
}
+EXPORT_SYMBOL_GPL(security_audit_rule_match);
#endif /* CONFIG_AUDIT */
--
1.8.3.1

View File

@ -1,236 +0,0 @@
From d84a5bd81b7ef68f35c3bbd845e71aee10e4e9b7 Mon Sep 17 00:00:00 2001
Message-Id: <d84a5bd81b7ef68f35c3bbd845e71aee10e4e9b7.1528226387.git.Jim.Somerville@windriver.com>
In-Reply-To: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
References: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
From: Kam Nasim <kam.nasim@windriver.com>
Date: Wed, 4 Oct 2017 14:02:10 -0400
Subject: [PATCH 26/32] US103091: IMA: System Configuration
Normally (if trusted integrity keyring is disabled), the _ima keyring
needs to be created by user space (specifically systemd), but that has
the added disadvantage of requiring the IMA public key to reside on the
file system as opposed to being compiled in. Somebody could render some
serious Grade A damage by corrupting this public key on the FS.
Crippling the system if IMA 'enforce' action is enabled.
We will therefore create the IMA keyring inside the kernel and load the
IMA public key as a compiled data blob, similar to how the Kernel loads
trusted X509 keys into the system truststore (.system_keyring)
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
---
include/keys/system_keyring.h | 2 ++
kernel/Makefile | 42 ++++++++++++++++++++--
kernel/ima_certificate.S | 20 +++++++++++
kernel/system_keyring.c | 82 +++++++++++++++++++++++++++++++++++++++++++
4 files changed, 144 insertions(+), 2 deletions(-)
create mode 100644 kernel/ima_certificate.S
diff --git a/include/keys/system_keyring.h b/include/keys/system_keyring.h
index 0e49b3c..6b2da90 100644
--- a/include/keys/system_keyring.h
+++ b/include/keys/system_keyring.h
@@ -34,4 +34,6 @@ static inline struct key *get_system_trusted_keyring(void)
#endif /* CONFIG_SYSTEM_TRUSTED_KEYRING */
+extern struct key *ima_keyring;
+
#endif /* _KEYS_SYSTEM_KEYRING_H */
diff --git a/kernel/Makefile b/kernel/Makefile
index d357e7d..f333b29 100644
--- a/kernel/Makefile
+++ b/kernel/Makefile
@@ -62,7 +62,7 @@ obj-$(CONFIG_QUEUED_SPINLOCKS) += qspinlock.o
obj-$(CONFIG_QUEUED_RWLOCKS) += qrwlock.o
obj-$(CONFIG_LOCK_SPIN_ON_OWNER) += osq_lock.o
obj-$(CONFIG_UID16) += uid16.o
-obj-$(CONFIG_SYSTEM_TRUSTED_KEYRING) += system_keyring.o system_certificates.o
+obj-$(CONFIG_SYSTEM_TRUSTED_KEYRING) += system_keyring.o system_certificates.o ima_certificate.o
obj-$(CONFIG_MODULES) += module.o
obj-$(CONFIG_MODULE_SIG) += module_signing.o
obj-$(CONFIG_MODULE_SIG_UEFI) += modsign_uefi.o
@@ -206,7 +206,45 @@ targets += $(obj)/.x509.list
$(obj)/.x509.list:
@echo $(X509_CERTIFICATES) >$@
-clean-files := x509_certificate_list .x509.list
+
+###############################################################################
+#
+# We will roll in the IMA X.509 certificate and pull it in the kernel
+# so that it gets loaded into the _ima keyring during boot.
+#
+# Ideally, this should have been treated similar to other .x509 certificates
+# (X509_CERTIFICATES), but those all get loaded into the system trusted keyring
+# and since the canonical pathnames are not available in the x509_certificate_list
+# compiled data blob, there is no way to isolate the IMA certificate from the
+# rest. Therefore we treat the IMA certificate as a seperate blob all together.
+#
+# We look in the source root for the IMA certificate, of name "ima_signing_key.pub"
+#
+###############################################################################
+IMA_X509_CERTIFICATE := $(srctree)/ima_signing_key.pub
+
+ifneq ($(wildcard $(obj)/.x509.ima),)
+ifneq ($(shell cat $(obj)/.x509.ima),$(IMA_X509_CERTIFICATE))
+$(info IMA: X.509 certificate changed)
+$(shell rm $(obj)/.x509.ima)
+endif
+endif
+
+kernel/ima_certificate.o: $(obj)/ima_x509_certificate
+
+quiet_cmd_imacert = CERTS $@
+ cmd_imacert = cat $(IMA_X509_CERTIFICATE) >$@ $(foreach IMA_X509,$(IMA_X509_CERTIFICATE),; echo " - Including cert $(IMA_X509)")
+
+targets += $(obj)/ima_x509_certificate
+$(obj)/ima_x509_certificate: $(IMA_X509_CERTIFICATE) $(obj)/.x509.ima
+ $(call if_changed,imacert)
+
+targets += $(obj)/.x509.ima
+$(obj)/.x509.ima:
+ @echo $(IMA_X509_CERTIFICATE) >$@
+
+
+clean-files := x509_certificate_list .x509.list ima_x509_certificate .x509.ima
endif
ifeq ($(CONFIG_MODULE_SIG),y)
diff --git a/kernel/ima_certificate.S b/kernel/ima_certificate.S
new file mode 100644
index 0000000..0c665dd
--- /dev/null
+++ b/kernel/ima_certificate.S
@@ -0,0 +1,20 @@
+#include <linux/export.h>
+#include <linux/init.h>
+
+ __INITRODATA
+
+ .align 8
+ .globl VMLINUX_SYMBOL(ima_system_certificate)
+VMLINUX_SYMBOL(ima_system_certificate):
+__cert_list_start:
+ .incbin "kernel/ima_x509_certificate"
+__cert_list_end:
+
+ .align 8
+ .globl VMLINUX_SYMBOL(ima_system_certificate_size)
+VMLINUX_SYMBOL(ima_system_certificate_size):
+#ifdef CONFIG_64BIT
+ .quad __cert_list_end - __cert_list_start
+#else
+ .long __cert_list_end - __cert_list_start
+#endif
diff --git a/kernel/system_keyring.c b/kernel/system_keyring.c
index c15e93f..92beb15 100644
--- a/kernel/system_keyring.c
+++ b/kernel/system_keyring.c
@@ -23,10 +23,15 @@ EXPORT_SYMBOL_GPL(system_trusted_keyring);
#ifdef CONFIG_SYSTEM_BLACKLIST_KEYRING
struct key *system_blacklist_keyring;
#endif
+struct key *ima_keyring;
+EXPORT_SYMBOL_GPL(ima_keyring);
extern __initconst const u8 system_certificate_list[];
extern __initconst const unsigned long system_certificate_list_size;
+extern __initconst const u8 ima_system_certificate[];
+extern __initconst const unsigned long ima_system_certificate_size;
+
/*
* Load the compiled-in keys
*/
@@ -57,6 +62,27 @@ static __init int system_trusted_keyring_init(void)
set_bit(KEY_FLAG_TRUSTED_ONLY, &system_blacklist_keyring->flags);
#endif
+ /* Normally (if trusted integrity keyring is disabled), the _ima
+ * keyring needs to be created by user space but that has the
+ * added disadvantage of requiring the IMA public key to reside on
+ * the file system as opposed to being compiled in.
+ * We will therefore form a _ima keyring here and load build
+ * the IMA X.509 certificate
+ *
+ * N.B: The IMA keyring only allows root userspace view & read ops
+ */
+ pr_notice("Initializing system IMA keyring\n");
+
+ ima_keyring = keyring_alloc("_ima",
+ KUIDT_INIT(0), KGIDT_INIT(0),
+ current_cred(),
+ ((KEY_POS_ALL & ~KEY_POS_SETATTR) |
+ KEY_USR_VIEW | KEY_USR_READ | KEY_USR_SEARCH),
+ KEY_ALLOC_NOT_IN_QUOTA, NULL);
+ if (IS_ERR(ima_keyring))
+ panic("Can't allocate system IMA keyring\n");
+
+ set_bit(KEY_FLAG_TRUSTED_ONLY, &ima_keyring->flags);
return 0;
}
@@ -121,3 +147,59 @@ dodgy_cert:
return 0;
}
late_initcall(load_system_certificate_list);
+
+/*
+ * Load the compiled-in IMA certificate.
+ */
+static __init int load_ima_system_certificate(void)
+{
+ key_ref_t key;
+ const u8 *p, *end;
+ size_t plen;
+
+ pr_notice("Loading compiled-in X.509 IMA certificate\n");
+
+ p = ima_system_certificate;
+ end = p + ima_system_certificate_size;
+ while (p < end) {
+ /* Each cert begins with an ASN.1 SEQUENCE tag and must be more
+ * than 256 bytes in size.
+ */
+ if (end - p < 4)
+ goto dodgy_cert;
+ if (p[0] != 0x30 &&
+ p[1] != 0x82)
+ goto dodgy_cert;
+ plen = (p[2] << 8) | p[3];
+ plen += 4;
+ if (plen > end - p)
+ goto dodgy_cert;
+
+ key = key_create_or_update(make_key_ref(ima_keyring, 1),
+ "asymmetric",
+ NULL,
+ p,
+ plen,
+ ((KEY_POS_ALL & ~KEY_POS_SETATTR) |
+ KEY_USR_VIEW | KEY_USR_READ),
+ KEY_ALLOC_NOT_IN_QUOTA |
+ KEY_ALLOC_TRUSTED);
+ if (IS_ERR(key)) {
+ pr_err("Problem loading in-kernel X.509 certificate (%ld)\n",
+ PTR_ERR(key));
+ } else {
+ set_bit(KEY_FLAG_BUILTIN, &key_ref_to_ptr(key)->flags);
+ pr_notice("Loaded X.509 cert '%s'\n",
+ key_ref_to_ptr(key)->description);
+ key_ref_put(key);
+ }
+ p += plen;
+ }
+
+ return 0;
+
+dodgy_cert:
+ pr_err("Problem parsing in-kernel X.509 IMA certificate\n");
+ return 0;
+}
+late_initcall(load_ima_system_certificate);
--
1.8.3.1

View File

@ -1,10 +1,7 @@
From a15588101329965ad3974bd571a9207d6a5e154a Mon Sep 17 00:00:00 2001 From a0ae6dfee3482b4da4d6f98c7e9f154f269fe5d6 Mon Sep 17 00:00:00 2001
Message-Id: <a15588101329965ad3974bd571a9207d6a5e154a.1528226387.git.Jim.Somerville@windriver.com>
In-Reply-To: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
References: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
From: Chris Friesen <chris.friesen@windriver.com> From: Chris Friesen <chris.friesen@windriver.com>
Date: Tue, 24 Nov 2015 16:27:28 -0500 Date: Tue, 24 Nov 2015 16:27:28 -0500
Subject: [PATCH 04/32] affine compute kernel threads Subject: [PATCH 03/10] affine compute kernel threads
This is a kernel enhancement to configure the cpu affinity of kernel This is a kernel enhancement to configure the cpu affinity of kernel
threads via kernel boot option kthread_cpus=<cpulist>. The compute threads via kernel boot option kthread_cpus=<cpulist>. The compute
@ -29,23 +26,24 @@ Signed-off-by: Chris Friesen <chris.friesen@windriver.com>
Signed-off-by: Vu Tran <vu.tran@windriver.com> Signed-off-by: Vu Tran <vu.tran@windriver.com>
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com> Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
Signed-off-by: Zhang Zhiguo <zhangzhg@neusoft.com>
--- ---
Documentation/kernel-parameters.txt | 10 ++++++++++ Documentation/admin-guide/kernel-parameters.txt | 9 +++++++++
include/linux/cpumask.h | 2 ++ include/linux/cpumask.h | 3 +++
init/main.c | 6 ++---- init/main.c | 2 ++
kernel/cpu.c | 13 +++++++++++++ kernel/cpu.c | 14 ++++++++++++++
kernel/kmod.c | 3 +++
kernel/kthread.c | 4 ++-- kernel/kthread.c | 4 ++--
6 files changed, 32 insertions(+), 6 deletions(-) kernel/umh.c | 3 +++
6 files changed, 33 insertions(+), 2 deletions(-)
diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt
index 02cfdf6..4eeda61 100644
--- a/Documentation/kernel-parameters.txt
+++ b/Documentation/kernel-parameters.txt
@@ -1551,6 +1551,16 @@ bytes respectively. Such letter suffixes can also be entirely omitted.
kpti [X86-64] Enable kernel page table isolation.
diff --git a/Documentation/admin-guide/kernel-parameters.txt b/Documentation/admin-guide/kernel-parameters.txt
index 5d43bff..928b525 100644
--- a/Documentation/admin-guide/kernel-parameters.txt
+++ b/Documentation/admin-guide/kernel-parameters.txt
@@ -1968,6 +1968,15 @@
Default: on
Built with CONFIG_DEBUG_KMEMLEAK_DEFAULT_OFF=y,
the default is off.
+ kthread_cpus= [KNL, SMP] Only run kernel threads on the specified + kthread_cpus= [KNL, SMP] Only run kernel threads on the specified
+ list of processors. The kernel will start threads + list of processors. The kernel will start threads
+ on the indicated processors only (unless there + on the indicated processors only (unless there
@ -55,15 +53,14 @@ index 02cfdf6..4eeda61 100644
+ control where kmod and other user space threads + control where kmod and other user space threads
+ are being spawned. Allows to keep kernel threads + are being spawned. Allows to keep kernel threads
+ away from certain cores unless absoluteluy necessary. + away from certain cores unless absoluteluy necessary.
+
kvm.ignore_msrs=[KVM] Ignore guest accesses to unhandled MSRs.
Default is 0 (don't ignore, but inject #GP)
kpti= [ARM64] Control page table isolation of user
and kernel address spaces.
diff --git a/include/linux/cpumask.h b/include/linux/cpumask.h diff --git a/include/linux/cpumask.h b/include/linux/cpumask.h
index ee335c6..46ae77a 100644 index 57f20a0..4526034 100644
--- a/include/linux/cpumask.h --- a/include/linux/cpumask.h
+++ b/include/linux/cpumask.h +++ b/include/linux/cpumask.h
@@ -52,6 +52,7 @@ extern int nr_cpu_ids; @@ -54,6 +54,7 @@ extern unsigned int nr_cpu_ids;
* cpu_present_mask - has bit 'cpu' set iff cpu is populated * cpu_present_mask - has bit 'cpu' set iff cpu is populated
* cpu_online_mask - has bit 'cpu' set iff cpu available to scheduler * cpu_online_mask - has bit 'cpu' set iff cpu available to scheduler
* cpu_active_mask - has bit 'cpu' set iff cpu available to migration * cpu_active_mask - has bit 'cpu' set iff cpu available to migration
@ -71,50 +68,52 @@ index ee335c6..46ae77a 100644
* *
* If !CONFIG_HOTPLUG_CPU, present == possible, and active == online. * If !CONFIG_HOTPLUG_CPU, present == possible, and active == online.
* *
@@ -88,6 +89,7 @@ extern const struct cpumask *const cpu_possible_mask; @@ -90,10 +91,12 @@ extern struct cpumask __cpu_possible_mask;
extern const struct cpumask *const cpu_online_mask; extern struct cpumask __cpu_online_mask;
extern const struct cpumask *const cpu_present_mask; extern struct cpumask __cpu_present_mask;
extern const struct cpumask *const cpu_active_mask; extern struct cpumask __cpu_active_mask;
+extern const struct cpumask *const cpu_kthread_mask; +extern struct cpumask __cpu_kthread_mask;
#define cpu_possible_mask ((const struct cpumask *)&__cpu_possible_mask)
#define cpu_online_mask ((const struct cpumask *)&__cpu_online_mask)
#define cpu_present_mask ((const struct cpumask *)&__cpu_present_mask)
#define cpu_active_mask ((const struct cpumask *)&__cpu_active_mask)
+#define cpu_kthread_mask ((const struct cpumask *)&__cpu_kthread_mask)
#if NR_CPUS > 1 #if NR_CPUS > 1
#define num_online_cpus() cpumask_weight(cpu_online_mask) #define num_online_cpus() cpumask_weight(cpu_online_mask)
diff --git a/init/main.c b/init/main.c diff --git a/init/main.c b/init/main.c
index 2e4ecd4..6e265d0 100644 index 42c2f2e..f248b7f 100644
--- a/init/main.c --- a/init/main.c
+++ b/init/main.c +++ b/init/main.c
@@ -961,10 +961,6 @@ static noinline void __init kernel_init_freeable(void) @@ -1142,6 +1142,8 @@ static noinline void __init kernel_init_freeable(void)
* init can allocate pages on any node
*/
set_mems_allowed(node_states[N_MEMORY]);
- /*
- * init can run on any cpu.
- */
- set_cpus_allowed_ptr(current, cpu_all_mask);
cad_pid = task_pid(current);
@@ -980,6 +976,8 @@ static noinline void __init kernel_init_freeable(void)
do_basic_setup(); do_basic_setup();
+ set_cpus_allowed_ptr(current, cpu_kthread_mask); + set_cpus_allowed_ptr(current, cpu_kthread_mask);
+ +
/* Open the /dev/console on the rootfs, this should never fail */ /* Open the /dev/console on the rootfs, this should never fail */
if (sys_open((const char __user *) "/dev/console", O_RDWR, 0) < 0) if (ksys_open((const char __user *) "/dev/console", O_RDWR, 0) < 0)
pr_err("Warning: unable to open an initial console.\n"); pr_err("Warning: unable to open an initial console.\n");
diff --git a/kernel/cpu.c b/kernel/cpu.c diff --git a/kernel/cpu.c b/kernel/cpu.c
index 6fe84e4..325a47a 100644 index d94cf04..0f2e63f 100644
--- a/kernel/cpu.c --- a/kernel/cpu.c
+++ b/kernel/cpu.c +++ b/kernel/cpu.c
@@ -1329,6 +1329,19 @@ static DECLARE_BITMAP(cpu_active_bits, CONFIG_NR_CPUS) __read_mostly; @@ -2226,6 +2226,9 @@ EXPORT_SYMBOL_GPL(cpu_bit_bitmap);
const struct cpumask *const cpu_active_mask = to_cpumask(cpu_active_bits); const DECLARE_BITMAP(cpu_all_bits, NR_CPUS) = CPU_BITS_ALL;
EXPORT_SYMBOL(cpu_active_mask); EXPORT_SYMBOL(cpu_all_bits);
+static DECLARE_BITMAP(cpu_kthread_bits, CONFIG_NR_CPUS) __read_mostly +const DECLARE_BITMAP(cpu_kthread_bits, NR_CPUS) = CPU_BITS_ALL;
+ = CPU_BITS_ALL; +EXPORT_SYMBOL(cpu_kthread_bits);
+const struct cpumask *const cpu_kthread_mask = to_cpumask(cpu_kthread_bits); +
+EXPORT_SYMBOL(cpu_kthread_mask); #ifdef CONFIG_INIT_ALL_POSSIBLE
struct cpumask __cpu_possible_mask __read_mostly
= {CPU_BITS_ALL};
@@ -2243,6 +2246,17 @@ EXPORT_SYMBOL(__cpu_present_mask);
struct cpumask __cpu_active_mask __read_mostly;
EXPORT_SYMBOL(__cpu_active_mask);
+struct cpumask __cpu_kthread_mask __read_mostly;
+EXPORT_SYMBOL(__cpu_kthread_mask);
+ +
+static int __init kthread_setup(char *str) +static int __init kthread_setup(char *str)
+{ +{
@ -124,37 +123,23 @@ index 6fe84e4..325a47a 100644
+__setup("kthread_cpus=", kthread_setup); +__setup("kthread_cpus=", kthread_setup);
+ +
+ +
void set_cpu_possible(unsigned int cpu, bool possible) void init_cpu_present(const struct cpumask *src)
{ {
if (possible) cpumask_copy(&__cpu_present_mask, src);
diff --git a/kernel/kmod.c b/kernel/kmod.c
index 86ab754..4bf584b 100644
--- a/kernel/kmod.c
+++ b/kernel/kmod.c
@@ -204,6 +204,9 @@ static int ____call_usermodehelper(void *data)
flush_signal_handlers(current, 1);
spin_unlock_irq(&current->sighand->siglock);
+ /* We can run only where init is allowed to run. */
+ set_cpus_allowed_ptr(current, cpu_kthread_mask);
+
/*
* Our parent is keventd, which runs with elevated scheduling priority.
* Avoid propagating that into the userspace child.
diff --git a/kernel/kthread.c b/kernel/kthread.c diff --git a/kernel/kthread.c b/kernel/kthread.c
index 703d910..7ea32eb 100644 index 1f0bf2d..3a5f1af 100644
--- a/kernel/kthread.c --- a/kernel/kthread.c
+++ b/kernel/kthread.c +++ b/kernel/kthread.c
@@ -284,7 +284,7 @@ struct task_struct *kthread_create_on_node(int (*threadfn)(void *data), @@ -339,7 +339,7 @@ struct task_struct *__kthread_create_on_node(int (*threadfn)(void *data),
* The kernel thread should not inherit these properties. * The kernel thread should not inherit these properties.
*/ */
sched_setscheduler_nocheck(create.result, SCHED_NORMAL, &param); sched_setscheduler_nocheck(task, SCHED_NORMAL, &param);
- set_cpus_allowed_ptr(create.result, cpu_all_mask); - set_cpus_allowed_ptr(task, cpu_all_mask);
+ set_cpus_allowed_ptr(create.result, cpu_kthread_mask); + set_cpus_allowed_ptr(task, cpu_kthread_mask);
} }
return create.result; kfree(create);
} return task;
@@ -454,7 +454,7 @@ int kthreadd(void *unused) @@ -562,7 +562,7 @@ int kthreadd(void *unused)
/* Setup a clean context for our children to inherit. */ /* Setup a clean context for our children to inherit. */
set_task_comm(tsk, "kthreadd"); set_task_comm(tsk, "kthreadd");
ignore_signals(tsk); ignore_signals(tsk);
@ -163,6 +148,20 @@ index 703d910..7ea32eb 100644
set_mems_allowed(node_states[N_MEMORY]); set_mems_allowed(node_states[N_MEMORY]);
current->flags |= PF_NOFREEZE; current->flags |= PF_NOFREEZE;
-- diff --git a/kernel/umh.c b/kernel/umh.c
1.8.3.1 index d937cba..94715df 100644
--- a/kernel/umh.c
+++ b/kernel/umh.c
@@ -74,6 +74,9 @@ static int call_usermodehelper_exec_async(void *data)
flush_signal_handlers(current, 1);
spin_unlock_irq(&current->sighand->siglock);
+ /* We can run only where init is allowed to run. */
+ set_cpus_allowed_ptr(current, cpu_kthread_mask);
+
/*
* Our parent (unbound workqueue) runs with elevated scheduling
* priority. Avoid propagating that into the userspace child.
--
2.7.4

View File

@ -1,55 +0,0 @@
From 1b9b21d80f85665b29dda49dd52d80058111d811 Mon Sep 17 00:00:00 2001
Message-Id: <1b9b21d80f85665b29dda49dd52d80058111d811.1528226387.git.Jim.Somerville@windriver.com>
In-Reply-To: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
References: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
From: Hannes Reinecke <hare@suse.de>
Date: Mon, 6 Jul 2015 13:07:58 +0200
Subject: [PATCH 29/32] aic94xx: Skip reading user settings if flash is not
found
If no user settings are found it's pointless trying to
read them from flash. So skip that step.
This also fixes a compilation warning about uninitialized variables in
aic94xx.
Signed-off-by: Hannes Reinecke <hare@suse.de>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: James Bottomley <JBottomley@Odin.com>
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
---
drivers/scsi/aic94xx/aic94xx_sds.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/scsi/aic94xx/aic94xx_sds.c b/drivers/scsi/aic94xx/aic94xx_sds.c
index edb43fd..c831e30 100644
--- a/drivers/scsi/aic94xx/aic94xx_sds.c
+++ b/drivers/scsi/aic94xx/aic94xx_sds.c
@@ -983,7 +983,7 @@ static int asd_process_ctrl_a_user(struct asd_ha_struct *asd_ha,
{
int err, i;
u32 offs, size;
- struct asd_ll_el *el;
+ struct asd_ll_el *el = NULL;
struct asd_ctrla_phy_settings *ps;
struct asd_ctrla_phy_settings dflt_ps;
@@ -1004,6 +1004,7 @@ static int asd_process_ctrl_a_user(struct asd_ha_struct *asd_ha,
size = sizeof(struct asd_ctrla_phy_settings);
ps = &dflt_ps;
+ goto out_process;
}
if (size == 0)
@@ -1028,7 +1029,7 @@ static int asd_process_ctrl_a_user(struct asd_ha_struct *asd_ha,
ASD_DPRINTK("couldn't find ctrla phy settings struct\n");
goto out2;
}
-
+out_process:
err = asd_process_ctrla_phy_settings(asd_ha, ps);
if (err) {
ASD_DPRINTK("couldn't process ctrla phy settings\n");
--
1.8.3.1

View File

@ -1,224 +0,0 @@
From 0bce5a8a5158d690f232873efa3379bd00dfa9f5 Mon Sep 17 00:00:00 2001
Message-Id: <0bce5a8a5158d690f232873efa3379bd00dfa9f5.1528226387.git.Jim.Somerville@windriver.com>
In-Reply-To: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
References: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
From: Akinobu Mita <akinobu.mita@gmail.com>
Date: Tue, 31 May 2016 16:09:04 -0400
Subject: [PATCH 07/32] cma: add placement specifier for "cma=" kernel
parameter
Commit 5ea3b1b2f8ad9162684431ce6188102ca4c64b7a upstream
Backported-by: Nam Ninh <nam.ninh@windriver.com>
Currently, "cma=" kernel parameter is used to specify the size of CMA,
but we can't specify where it is located. We want to locate CMA below
4GB for devices only supporting 32-bit addressing on 64-bit systems
without iommu.
This enables to specify the placement of CMA by extending "cma=" kernel
parameter.
Examples:
1. locate 64MB CMA below 4GB by "cma=64M@0-4G"
2. locate 64MB CMA exact at 512MB by "cma=64M@512M"
Note that the DMA contiguous memory allocator on x86 assumes that
page_address() works for the pages to allocate. So this change requires
to limit end address of contiguous memory area upto max_pfn_mapped to
prevent from locating it on highmem area by the argument of
dma_contiguous_reserve().
Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
Cc: Marek Szyprowski <m.szyprowski@samsung.com>
Cc: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Cc: David Woodhouse <dwmw2@infradead.org>
Cc: Don Dutile <ddutile@redhat.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: Andi Kleen <andi@firstfloor.org>
Cc: Yinghai Lu <yinghai@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
---
Documentation/kernel-parameters.txt | 7 +++++--
arch/x86/kernel/setup.c | 2 +-
drivers/base/dma-contiguous.c | 42 ++++++++++++++++++++++++++++---------
include/linux/dma-contiguous.h | 9 +++++---
4 files changed, 44 insertions(+), 16 deletions(-)
diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt
index 4eeda61..685554b 100644
--- a/Documentation/kernel-parameters.txt
+++ b/Documentation/kernel-parameters.txt
@@ -580,8 +580,11 @@ bytes respectively. Such letter suffixes can also be entirely omitted.
Also note the kernel might malfunction if you disable
some critical bits.
- cma=nn[MG] [ARM,KNL]
- Sets the size of kernel global memory area for contiguous
+ cma=nn[MG]@[start[MG][-end[MG]]]
+ [ARM,X86,KNL]
+ Sets the size of kernel global memory area for
+ contiguous memory allocations and optionally the
+ placement constraint by the physical address range of
memory allocations. For more information, see
include/linux/dma-contiguous.h
diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c
index 9eca4ac..4e39287 100644
--- a/arch/x86/kernel/setup.c
+++ b/arch/x86/kernel/setup.c
@@ -1298,7 +1298,7 @@ void __init setup_arch(char **cmdline_p)
setup_real_mode();
memblock_set_current_limit(get_max_mapped());
- dma_contiguous_reserve(0);
+ dma_contiguous_reserve(max_pfn_mapped << PAGE_SHIFT);
/*
* NOTE: On x86-32, only from this point on, fixmaps are ready for use.
diff --git a/drivers/base/dma-contiguous.c b/drivers/base/dma-contiguous.c
index a0f89fc..a7d5bda 100644
--- a/drivers/base/dma-contiguous.c
+++ b/drivers/base/dma-contiguous.c
@@ -59,11 +59,22 @@ struct cma *dma_contiguous_default_area;
*/
static const phys_addr_t size_bytes = CMA_SIZE_MBYTES * SZ_1M;
static phys_addr_t size_cmdline = -1;
+static phys_addr_t base_cmdline;
+static phys_addr_t limit_cmdline;
static int __init early_cma(char *p)
{
pr_debug("%s(%s)\n", __func__, p);
size_cmdline = memparse(p, &p);
+ if (*p != '@')
+ return 0;
+ base_cmdline = memparse(p + 1, &p);
+ if (*p != '-') {
+ limit_cmdline = base_cmdline + size_cmdline;
+ return 0;
+ }
+ limit_cmdline = memparse(p + 1, &p);
+
return 0;
}
early_param("cma", early_cma);
@@ -107,11 +118,18 @@ static inline __maybe_unused phys_addr_t cma_early_percent_memory(void)
void __init dma_contiguous_reserve(phys_addr_t limit)
{
phys_addr_t selected_size = 0;
+ phys_addr_t selected_base = 0;
+ phys_addr_t selected_limit = limit;
+ bool fixed = false;
pr_debug("%s(limit %08lx)\n", __func__, (unsigned long)limit);
if (size_cmdline != -1) {
selected_size = size_cmdline;
+ selected_base = base_cmdline;
+ selected_limit = min_not_zero(limit_cmdline, limit);
+ if (base_cmdline + size_cmdline == limit_cmdline)
+ fixed = true;
} else {
#ifdef CONFIG_CMA_SIZE_SEL_MBYTES
selected_size = size_bytes;
@@ -128,10 +146,12 @@ void __init dma_contiguous_reserve(phys_addr_t limit)
pr_debug("%s: reserving %ld MiB for global area\n", __func__,
(unsigned long)selected_size / SZ_1M);
- dma_contiguous_reserve_area(selected_size, 0, limit,
- &dma_contiguous_default_area);
+ dma_contiguous_reserve_area(selected_size, selected_base,
+ selected_limit,
+ &dma_contiguous_default_area,
+ fixed);
}
-};
+}
static DEFINE_MUTEX(cma_mutex);
@@ -187,15 +207,20 @@ core_initcall(cma_init_reserved_areas);
* @base: Base address of the reserved area optional, use 0 for any
* @limit: End address of the reserved memory (optional, 0 for any).
* @res_cma: Pointer to store the created cma region.
+ * @fixed: hint about where to place the reserved area
*
* This function reserves memory from early allocator. It should be
* called by arch specific code once the early allocator (memblock or bootmem)
* has been activated and all other subsystems have already allocated/reserved
* memory. This function allows to create custom reserved areas for specific
* devices.
+ *
+ * If @fixed is true, reserve contiguous area at exactly @base. If false,
+ * reserve in range from @base to @limit.
*/
int __init dma_contiguous_reserve_area(phys_addr_t size, phys_addr_t base,
- phys_addr_t limit, struct cma **res_cma)
+ phys_addr_t limit, struct cma **res_cma,
+ bool fixed)
{
struct cma *cma = &cma_areas[cma_area_count];
phys_addr_t alignment;
@@ -221,18 +246,15 @@ int __init dma_contiguous_reserve_area(phys_addr_t size, phys_addr_t base,
limit &= ~(alignment - 1);
/* Reserve memory */
- if (base) {
+ if (base && fixed) {
if (memblock_is_region_reserved(base, size) ||
memblock_reserve(base, size) < 0) {
ret = -EBUSY;
goto err;
}
} else {
- /*
- * Use __memblock_alloc_base() since
- * memblock_alloc_base() panic()s.
- */
- phys_addr_t addr = __memblock_alloc_base(size, alignment, limit);
+ phys_addr_t addr = memblock_alloc_range(size, alignment, base,
+ limit);
if (!addr) {
ret = -ENOMEM;
goto err;
diff --git a/include/linux/dma-contiguous.h b/include/linux/dma-contiguous.h
index 1421a95..5e3f586 100644
--- a/include/linux/dma-contiguous.h
+++ b/include/linux/dma-contiguous.h
@@ -88,7 +88,8 @@ static inline void dma_contiguous_set_default(struct cma *cma)
void dma_contiguous_reserve(phys_addr_t addr_limit);
int __init dma_contiguous_reserve_area(phys_addr_t size, phys_addr_t base,
- phys_addr_t limit, struct cma **res_cma);
+ phys_addr_t limit, struct cma **res_cma,
+ bool fixed);
/**
* dma_declare_contiguous() - reserve area for contiguous memory handling
@@ -108,7 +109,7 @@ static inline int dma_declare_contiguous(struct device *dev, phys_addr_t size,
{
struct cma *cma;
int ret;
- ret = dma_contiguous_reserve_area(size, base, limit, &cma);
+ ret = dma_contiguous_reserve_area(size, base, limit, &cma, true);
if (ret == 0)
dev_set_cma_area(dev, cma);
@@ -136,7 +137,9 @@ static inline void dma_contiguous_set_default(struct cma *cma) { }
static inline void dma_contiguous_reserve(phys_addr_t limit) { }
static inline int dma_contiguous_reserve_area(phys_addr_t size, phys_addr_t base,
- phys_addr_t limit, struct cma **res_cma) {
+ phys_addr_t limit, struct cma **res_cma,
+ bool fixed)
+{
return -ENOSYS;
}
--
1.8.3.1

View File

@ -1,35 +0,0 @@
From a209e9637eacb353adb97f29dd059e63084d30df Mon Sep 17 00:00:00 2001
From: Bart Wensley <barton.wensley@windriver.com>
Date: Tue, 9 Jul 2019 07:25:32 -0500
Subject: [PATCH 1/1] compile fix for disabling CONFIG_MEMCG_KMEM
Signed-off-by: Bart Wensley <barton.wensley@windriver.com>
---
mm/memcontrol.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/mm/memcontrol.c b/mm/memcontrol.c
index da97e2c..68fd46b 100644
--- a/mm/memcontrol.c
+++ b/mm/memcontrol.c
@@ -2998,6 +2998,8 @@ static void __mem_cgroup_commit_charge(struct mem_cgroup *memcg,
memcg_check_events(memcg, page);
}
+static DEFINE_MUTEX(memcg_limit_mutex);
+
#ifdef CONFIG_MEMCG_KMEM
/*
* The memcg_slab_mutex is held whenever a per memcg kmem cache is created or
@@ -3378,8 +3380,6 @@ static inline void memcg_resume_kmem_account(void)
current->memcg_kmem_skip_account--;
}
-static DEFINE_MUTEX(memcg_limit_mutex);
-
int __kmem_cache_destroy_memcg_children(struct kmem_cache *s)
{
struct kmem_cache *c;
--
1.8.3.1

View File

@ -1,92 +0,0 @@
From 5d7f38974c3279339c7d12d13980471fb50cf6c6 Mon Sep 17 00:00:00 2001
Message-Id: <5d7f38974c3279339c7d12d13980471fb50cf6c6.1528226387.git.Jim.Somerville@windriver.com>
In-Reply-To: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
References: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
From: "Rafael J. Wysocki" <rafael.j.wysocki@intel.com>
Date: Fri, 24 Feb 2017 13:25:14 +0100
Subject: [PATCH 24/32] cpuidle: menu: Avoid taking spinlock for accessing QoS
values
[commit 6dbf5cea05a7098a69f294c96b6d76f08562cae5 from linux-stable ]
After commit 9908859acaa9 (cpuidle/menu: add per CPU PM QoS resume
latency consideration) the cpuidle menu governor calls
dev_pm_qos_read_value() on CPU devices to read the current resume latency QoS
constraint values for them. That function takes a spinlock to prevent the
device's power.qos pointer from becoming NULL during the access which is a
problem for the RT patchset where spinlocks are converted into mutexes and
the idle loop stops working.
However, it is not even necessary for the menu governor to take
that spinlock, because the power.qos pointer accessed under it
cannot be modified during the access anyway.
For this reason, introduce a "raw" routine for accessing device
QoS resume latency constraints without locking and use it in the
menu governor.
Fixes: 9908859acaa9 (cpuidle/menu: add per CPU PM QoS resume latency consideration)
Acked-by: Alex Shi <alex.shi@linaro.org>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Signed-off-by: Alex Kozyrev <alex.kozyrev@windriver.com>
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
---
drivers/base/power/qos.c | 3 +--
drivers/cpuidle/governors/menu.c | 2 +-
include/linux/pm_qos.h | 6 ++++++
3 files changed, 8 insertions(+), 3 deletions(-)
diff --git a/drivers/base/power/qos.c b/drivers/base/power/qos.c
index b2ca302..0cc2a13 100644
--- a/drivers/base/power/qos.c
+++ b/drivers/base/power/qos.c
@@ -104,8 +104,7 @@ EXPORT_SYMBOL_GPL(dev_pm_qos_flags);
*/
s32 __dev_pm_qos_read_value(struct device *dev)
{
- return IS_ERR_OR_NULL(dev->power.qos) ?
- 0 : pm_qos_read_value(&dev->power.qos->latency);
+ return dev_pm_qos_raw_read_value(dev);
}
/**
diff --git a/drivers/cpuidle/governors/menu.c b/drivers/cpuidle/governors/menu.c
index fe2dcb8..f9861fd 100644
--- a/drivers/cpuidle/governors/menu.c
+++ b/drivers/cpuidle/governors/menu.c
@@ -265,7 +265,7 @@ static int menu_select(struct cpuidle_driver *drv, struct cpuidle_device *dev)
int i;
int multiplier;
struct timespec t;
- int resume_latency = dev_pm_qos_read_value(device);
+ int resume_latency = dev_pm_qos_raw_read_value(device);
if (data->needs_update) {
menu_update(drv, dev);
diff --git a/include/linux/pm_qos.h b/include/linux/pm_qos.h
index 5281e7f..1d8b629 100644
--- a/include/linux/pm_qos.h
+++ b/include/linux/pm_qos.h
@@ -217,6 +217,11 @@ static inline s32 dev_pm_qos_requested_flags(struct device *dev)
{
return dev->power.qos->flags_req->data.flr.flags;
}
+static inline s32 dev_pm_qos_raw_read_value(struct device *dev)
+{
+ return IS_ERR_OR_NULL(dev->power.qos) ?
+ 0 : pm_qos_read_value(&dev->power.qos->latency);
+}
#else
static inline int dev_pm_qos_expose_latency_limit(struct device *dev, s32 value)
{ return 0; }
@@ -236,6 +241,7 @@ static inline void dev_pm_qos_hide_latency_tolerance(struct device *dev) {}
static inline s32 dev_pm_qos_requested_latency(struct device *dev) { return 0; }
static inline s32 dev_pm_qos_requested_flags(struct device *dev) { return 0; }
+static inline s32 dev_pm_qos_raw_read_value(struct device *dev) { return 0; }
#endif
#endif
--
1.8.3.1

View File

@ -1,71 +0,0 @@
From f5020c58583d04f0c6f8df1cbbd7d2e747fcb537 Mon Sep 17 00:00:00 2001
Message-Id: <f5020c58583d04f0c6f8df1cbbd7d2e747fcb537.1528226387.git.Jim.Somerville@windriver.com>
In-Reply-To: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
References: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
From: Alex Shi <alex.shi@linaro.org>
Date: Thu, 12 Jan 2017 21:27:04 +0800
Subject: [PATCH 22/32] cpuidle/menu: add per CPU PM QoS resume latency
consideration
[ commit 9908859acaa95640d4a07991a93f7cd5bfc18e02 from linux-stable ]
There may be special requirements on CPU response time, like if
a interrupt is pinned to a CPU, that CPU should not go into excessively deep
idle states. For this reason, add a mechanism for adding PM QoS resume
latency constraints for individual CPUs and modify the menu governor to take
them into account.
To that end, extend the device PM QoS pm_qos_resume_latency attribute
to CPUs, which is possible, because the exit latency for CPUs is
effectively equivalent to the resume latency for devices.
Signed-off-by: Alex Shi <alex.shi@linaro.org>
Acked-by: Rik van Riel <riel@redhat.com>
[ rjw : Subject & changelog ]
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Signed-off-by: Alex Kozyrev <alex.kozyrev@windriver.com>
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
---
drivers/cpuidle/governors/menu.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/drivers/cpuidle/governors/menu.c b/drivers/cpuidle/governors/menu.c
index eb9fb0e..fe2dcb8 100644
--- a/drivers/cpuidle/governors/menu.c
+++ b/drivers/cpuidle/governors/menu.c
@@ -19,6 +19,7 @@
#include <linux/tick.h>
#include <linux/sched.h>
#include <linux/math64.h>
+#include <linux/cpu.h>
#include <linux/module.h>
#define BUCKETS 12
@@ -259,10 +260,12 @@ again:
static int menu_select(struct cpuidle_driver *drv, struct cpuidle_device *dev)
{
struct menu_device *data = &__get_cpu_var(menu_devices);
+ struct device *device = get_cpu_device(dev->cpu);
int latency_req = pm_qos_request(PM_QOS_CPU_DMA_LATENCY);
int i;
int multiplier;
struct timespec t;
+ int resume_latency = dev_pm_qos_read_value(device);
if (data->needs_update) {
menu_update(drv, dev);
@@ -271,6 +274,10 @@ static int menu_select(struct cpuidle_driver *drv, struct cpuidle_device *dev)
data->exit_us = 0;
+ /* resume_latency is 0 means no restriction */
+ if (resume_latency && resume_latency < latency_req)
+ latency_req = resume_latency;
+
/* Special case when user has set very strict latency requirement */
if (unlikely(latency_req == 0))
return 0;
--
1.8.3.1

View File

@ -1,52 +0,0 @@
From 9218064183a57581be8b7b980ce4b8ac9821555b Mon Sep 17 00:00:00 2001
Message-Id: <9218064183a57581be8b7b980ce4b8ac9821555b.1528226387.git.Jim.Somerville@windriver.com>
In-Reply-To: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
References: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
From: Alex Shi <alex.shi@linaro.org>
Date: Thu, 12 Jan 2017 21:27:02 +0800
Subject: [PATCH 21/32] cpuidle/menu: stop seeking deeper idle if current state
is deep enough
[ commit 8e37e1a2a3295f5d99e6dbe99eca24eca7a034ef from linux-stable ]
Obsolete commit 71abbbf856a0 (cpuidle: extend cpuidle and menu
governor to handle dynamic states) wanted to introduce dynamic C-states, but
that idea was dropped long ago. The nonsense deeper C-state checking
remained, though.
Since both target_residency and exit_latency are longer for deeper
idle state, there's no need to waste CPU time on useless checks.
Signed-off-by: Alex Shi <alex.shi@linaro.org>
Acked-by: Rik van Riel <riel@redhat.com>
[ rjw: Subject & changelog ]
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Signed-off-by: Alex Kozyrev <alex.kozyrev@windriver.com>
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
---
drivers/cpuidle/governors/menu.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/cpuidle/governors/menu.c b/drivers/cpuidle/governors/menu.c
index c99fee9..eb9fb0e 100644
--- a/drivers/cpuidle/governors/menu.c
+++ b/drivers/cpuidle/governors/menu.c
@@ -323,11 +323,11 @@ static int menu_select(struct cpuidle_driver *drv, struct cpuidle_device *dev)
if (s->disabled || su->disable)
continue;
if (s->target_residency > data->predicted_us)
- continue;
+ break;
if (s->exit_latency > latency_req)
- continue;
+ break;
if (s->exit_latency * multiplier > data->predicted_us)
- continue;
+ break;
data->last_state_idx = i;
data->exit_us = s->exit_latency;
--
1.8.3.1

View File

@ -1,3 +0,0 @@
# See 'cpupower help' and cpupower(1) for more info
CPUPOWER_START_OPTS="frequency-set -g performance"
CPUPOWER_STOP_OPTS="frequency-set -g ondemand"

View File

@ -1,13 +0,0 @@
[Unit]
Description=Configure CPU power related settings
After=syslog.target
[Service]
Type=oneshot
RemainAfterExit=yes
EnvironmentFile=/etc/sysconfig/cpupower
ExecStart=/usr/bin/cpupower $CPUPOWER_START_OPTS
ExecStop=/usr/bin/cpupower $CPUPOWER_STOP_OPTS
[Install]
WantedBy=multi-user.target

View File

@ -1,29 +1,27 @@
From 7d1684c010cbbc13b80056d53932ef62d280dc3f Mon Sep 17 00:00:00 2001 From 472b6cdd9e6d8df5b1574b05ca8d9ef6511c0ce1 Mon Sep 17 00:00:00 2001
Message-Id: <7d1684c010cbbc13b80056d53932ef62d280dc3f.1528226387.git.Jim.Somerville@windriver.com>
In-Reply-To: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
References: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
From: Jim Somerville <Jim.Somerville@windriver.com> From: Jim Somerville <Jim.Somerville@windriver.com>
Date: Tue, 3 Apr 2018 18:07:37 -0400 Date: Tue, 3 Apr 2018 18:07:37 -0400
Subject: [PATCH 03/32] debrand rh i686 cpu Subject: [PATCH 2/2] debrand rh i686 cpu
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com> Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
Signed-off-by: Austin Sun <austin.sun@intel.com>
--- ---
arch/x86/boot/main.c | 2 +- arch/x86/boot/main.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-) 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/x86/boot/main.c b/arch/x86/boot/main.c diff --git a/arch/x86/boot/main.c b/arch/x86/boot/main.c
index 0d12b19..99dcb04 100644 index 89f9e047b..0ea44ce3d 100644
--- a/arch/x86/boot/main.c --- a/arch/x86/boot/main.c
+++ b/arch/x86/boot/main.c +++ b/arch/x86/boot/main.c
@@ -147,7 +147,7 @@ void main(void) @@ -147,7 +147,7 @@ void main(void)
/* Make sure we have all the proper CPU support */ /* Make sure we have all the proper CPU support */
if (validate_cpu()) { if (validate_cpu()) {
- puts("This processor is unsupported in RHEL7.\n"); - puts("This processor is not supported in this version of RHEL.\n");
+ puts("This processor is unsupported in CentOS 7.\n"); + puts("This processor is not supported in this version of CentOS.\n");
die(); die();
} }
-- --
1.8.3.1 2.19.1

View File

@ -7,15 +7,43 @@ Date: Thu, 19 Jun 2014 10:05:12 -0500
Subject: [PATCH 02/32] debrand rh_taint Subject: [PATCH 02/32] debrand rh_taint
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com> Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
Signed-off-by: Sun Austin <austin.sun@intel.com>
Signed-off-by: Dongqi Chen <chen.dq@neusoft.com>
--- ---
kernel/rh_taint.c | 2 +- kernel/rh_taint.c | 26 +++++++++++++-------------
1 file changed, 1 insertion(+), 1 deletion(-) 1 file changed, 13 insertions(+), 13 deletions(-)
diff --git a/kernel/rh_taint.c b/kernel/rh_taint.c diff --git a/kernel/rh_taint.c b/kernel/rh_taint.c
index 22f0324..28c369f 100644 index 22f0324..28c369f 100644
--- a/kernel/rh_taint.c --- a/kernel/rh_taint.c
+++ b/kernel/rh_taint.c +++ b/kernel/rh_taint.c
@@ -24,7 +24,7 @@ @@ -2,12 +2,12 @@
#include <linux/module.h>
/*
- * The following functions are used by Red Hat to indicate to users that
- * hardware and drivers are unsupported, or have limited support in RHEL major
+ * The following functions are used by CentOS to indicate to users that
+ * hardware and drivers are unsupported, or have limited support in CentOS Linux major
* and minor releases. These functions output loud warning messages to the end
* user and should be USED WITH CAUTION.
*
- * Any use of these functions _MUST_ be documented in the RHEL Release Notes,
+ * Any use of these functions _MUST_ be documented in the CentOS Linux Release Notes,
* and have approval of management.
*/
@@ -16,15 +16,15 @@
* @msg: Hardware name, class, or type
*
* Called to mark a device, class of devices, or types of devices as not having
- * support in any RHEL minor release. This does not TAINT the kernel. Red Hat
- * will not fix bugs against this hardware in this minor release. Red Hat may
+ * support in any CentOS Linux minor release. This does not TAINT the kernel. CentOS
+ * will not fix bugs against this hardware in this minor release. CentOS may
* declare support in a future major or minor update release. This cannot be
* used to mark drivers unsupported.
*/
void mark_hardware_unsupported(const char *msg) void mark_hardware_unsupported(const char *msg)
{ {
/* Print one single message */ /* Print one single message */
@ -24,6 +52,50 @@ index 22f0324..28c369f 100644
} }
EXPORT_SYMBOL(mark_hardware_unsupported); EXPORT_SYMBOL(mark_hardware_unsupported);
-- @@ -35,12 +35,12 @@ EXPORT_SYMBOL(mark_hardware_unsupported);
1.8.3.1 * Called to minimize the support status of a previously supported device in
* a minor release. This does not TAINT the kernel. Marking hardware
* deprecated is usually done in conjunction with the hardware vendor. Future
- * RHEL major releases may not include this driver. Driver updates and fixes
+ * CentOS Linux major releases may not include this driver. Driver updates and fixes
* for this device will be limited to critical issues in future minor releases.
*/
void mark_hardware_deprecated(const char *msg)
{
- pr_crit("Warning: %s - this hardware is not recommended for new deployments. It continues to be supported in this RHEL release, but it is likely to be removed in the next major release. Driver updates and fixes for this device will be limited to critical issues. Please contact Red Hat Support or your device's hardware vendor for additional information.\n", msg);
+ pr_crit("Warning: %s - this hardware is not recommended for new deployments. It continues to be supported in this CentOS Linux release, but it is likely to be removed in the next major release. Driver updates and fixes for this device will be limited to critical issues. Please contact CentOS Support or your device's hardware vendor for additional information.\n", msg);
}
EXPORT_SYMBOL(mark_hardware_deprecated);
@@ -50,9 +50,9 @@ EXPORT_SYMBOL(mark_hardware_deprecated);
*
* Called to minimize the support status of a new driver. This does TAINT the
* kernel. Calling this function indicates that the driver or subsystem has
- * had limited testing and is not marked for full support within this RHEL
- * minor release. The next RHEL minor release may contain full support for
- * this driver. Red Hat does not guarantee that bugs reported against this
+ * had limited testing and is not marked for full support within this CentOS Linux
+ * minor release. The next CentOS Linux minor release may contain full support for
+ * this driver. CentOS does not guarantee that bugs reported against this
* driver or subsystem will be resolved.
*/
void mark_tech_preview(const char *msg, struct module *mod)
@@ -81,13 +81,13 @@ EXPORT_SYMBOL(mark_tech_preview);
* mark_driver_unsupported - drivers that we know we don't want to support
* @name: the name of the driver
*
- * In some cases Red Hat has chosen to build a driver for internal QE
+ * In some cases CentOS has chosen to build a driver for internal QE
* use. Use this function to mark those drivers as unsupported for
* customers.
*/
void mark_driver_unsupported(const char *name)
{
- pr_crit("Warning: %s - This driver has not undergone sufficient testing by Red Hat for this release and therefore cannot be used in production systems.\n",
+ pr_crit("Warning: %s - This driver has not undergone sufficient testing by CentOS for this release and therefore cannot be used in production systems.\n",
name ? name : "kernel");
}
EXPORT_SYMBOL(mark_driver_unsupported);
--
2.7.4

View File

@ -5,6 +5,8 @@ Date: Thu, 19 Jun 2014 09:53:13 -0500
Subject: [PATCH 01/32] debrand single cpu Subject: [PATCH 01/32] debrand single cpu
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com> Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
Signed-off-by: Sun Austin <austin.sun@intel.com>
Signed-off-by: Dongqi Chen <chen.dq@neusoft.com>
--- ---
arch/x86/kernel/setup.c | 2 +- arch/x86/kernel/setup.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-) 1 file changed, 1 insertion(+), 1 deletion(-)
@ -13,15 +15,15 @@ diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c
index f27ca00..9eca4ac 100644 index f27ca00..9eca4ac 100644
--- a/arch/x86/kernel/setup.c --- a/arch/x86/kernel/setup.c
+++ b/arch/x86/kernel/setup.c +++ b/arch/x86/kernel/setup.c
@@ -964,7 +964,7 @@ static void rh_check_supported(void) @@ -926,7 +926,7 @@ static void rh_check_supported(void)
if (((boot_cpu_data.x86_max_cores * smp_num_siblings) == 1) && if (((boot_cpu_data.x86_max_cores * smp_num_siblings) == 1) &&
!guest && !is_kdump_kernel()) { !guest && is_kdump_kernel()) {
pr_crit("Detected single cpu native boot.\n"); pr_crit("Detected single cpu native boot.\n");
- pr_crit("Important: In Red Hat Enterprise Linux 7, single threaded, single CPU 64-bit physical systems are unsupported by Red Hat. Please contact your Red Hat support representative for a list of certified and supported systems."); - pr_crit("Important: In Red Hat Enterprise Linux 8, single threaded, single CPU 64-bit physical systems are unsupported by Red Hat. Please contact your Red Hat support representative for a list of certified and supported systems.");
+ pr_crit("Important: In CentOS 7, single threaded, single CPU 64-bit physical systems are unsupported. Please see http://wiki.centos.org/FAQ for more information"); + pr_crit("Important: In CentOS 8, single threaded, single CPU 64-bit physical systems are unsupported. Please see http://wiki.centos.org/FAQ for more information");
} }
/* The RHEL7 kernel does not support this hardware. The kernel will /*
-- --
1.8.3.1 2.7.4

View File

@ -1,44 +0,0 @@
From 143c2720aaa898f6e4cd53598808ff1230c33cd8 Mon Sep 17 00:00:00 2001
Message-Id: <143c2720aaa898f6e4cd53598808ff1230c33cd8.1528226387.git.Jim.Somerville@windriver.com>
In-Reply-To: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
References: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
From: Sudip Mukherjee <sudipm.mukherjee@gmail.com>
Date: Thu, 18 Feb 2016 13:59:13 +0530
Subject: [PATCH 30/32] dpt_i2o: fix build warning
We were getting build warning about:
drivers/scsi/dpt_i2o.c:183:29: warning: 'dptids' defined but not used
dptids[] is only used in the MODULE_DEVICE_TABLE so when MODULE is not
defined then dptids[] becomes unused.
Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
---
drivers/scsi/dpt_i2o.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/scsi/dpt_i2o.c b/drivers/scsi/dpt_i2o.c
index 2bce881..cb62223 100644
--- a/drivers/scsi/dpt_i2o.c
+++ b/drivers/scsi/dpt_i2o.c
@@ -180,11 +180,14 @@ static u8 adpt_read_blink_led(adpt_hba* host)
*============================================================================
*/
+#ifdef MODULE
static struct pci_device_id dptids[] = {
{ PCI_DPT_VENDOR_ID, PCI_DPT_DEVICE_ID, PCI_ANY_ID, PCI_ANY_ID,},
{ PCI_DPT_VENDOR_ID, PCI_DPT_RAPTOR_DEVICE_ID, PCI_ANY_ID, PCI_ANY_ID,},
{ 0, }
};
+#endif
+
MODULE_DEVICE_TABLE(pci,dptids);
static int adpt_detect(struct scsi_host_template* sht)
--
1.8.3.1

View File

@ -1,52 +0,0 @@
From ebe06187bf2aec10d537ce4595e416035367d703 Mon Sep 17 00:00:00 2001
From: Konstantin Khlebnikov <koct9i@gmail.com>
Date: Tue, 17 Jun 2014 06:58:05 +0400
Subject: [PATCH] epoll: fix use-after-free in eventpoll_release_file
This fixes use-after-free of epi->fllink.next inside list loop macro.
This loop actually releases elements in the body. The list is
rcu-protected but here we cannot hold rcu_read_lock because we need to
lock mutex inside.
The obvious solution is to use list_for_each_entry_safe(). RCU-ness
isn't essential because nobody can change this list under us, it's final
fput for this file.
The bug was introduced by ae10b2b4eb01 ("epoll: optimize EPOLL_CTL_DEL
using rcu")
Signed-off-by: Konstantin Khlebnikov <koct9i@gmail.com>
Reported-by: Cyrill Gorcunov <gorcunov@openvz.org>
Cc: Stable <stable@vger.kernel.org> # 3.13+
Cc: Sasha Levin <sasha.levin@oracle.com>
Cc: Jason Baron <jbaron@akamai.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
---
fs/eventpoll.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/fs/eventpoll.c b/fs/eventpoll.c
index b73e062..b10b48c 100644
--- a/fs/eventpoll.c
+++ b/fs/eventpoll.c
@@ -910,7 +910,7 @@ static const struct file_operations eventpoll_fops = {
void eventpoll_release_file(struct file *file)
{
struct eventpoll *ep;
- struct epitem *epi;
+ struct epitem *epi, *next;
/*
* We don't want to get "file->f_lock" because it is not
@@ -926,7 +926,7 @@ void eventpoll_release_file(struct file *file)
* Besides, ep_remove() acquires the lock, so we can't hold it here.
*/
mutex_lock(&epmutex);
- list_for_each_entry_rcu(epi, &file->f_ep_links, fllink) {
+ list_for_each_entry_safe(epi, next, &file->f_ep_links, fllink) {
ep = epi->ep;
mutex_lock_nested(&ep->mtx, 0);
ep_remove(ep, epi);
--
2.7.4

View File

@ -1,66 +0,0 @@
From c48d3f2683c28939b3c11bdfa67e4446cd11beee Mon Sep 17 00:00:00 2001
From: "Martin, Chen" <haochuan.z.chen@intel.com>
Date: Mon, 14 Jan 2019 17:59:03 +0000
Subject: [PATCH] fix CentOS 7.6 upgrade compile error
1, fix improper call of part_round_stats and part_inc_in_flight
in drbd_req.c, as CONFIG_BLK_DEV_DRBD=m defined in
kernel-3.10.0-x86_64.config.tis_extra
2, add explicit declaration for trace_bpf_int_jit_compile,
trace_bpf_jit_compile, trace_bpf_jit_free, if pmd_read_atomic not
defined
Signed-off-by: Martin, Chen <haochuan.z.chen@intel.com>
---
drivers/block/drbd/drbd_req.c | 8 ++++----
include/linux/filter.h | 3 +++
2 files changed, 7 insertions(+), 4 deletions(-)
diff --git a/drivers/block/drbd/drbd_req.c b/drivers/block/drbd/drbd_req.c
index a6f13f7..cbd0a49 100644
--- a/drivers/block/drbd/drbd_req.c
+++ b/drivers/block/drbd/drbd_req.c
@@ -39,12 +39,12 @@ static void _drbd_start_io_acct(struct drbd_conf *mdev, struct drbd_request *req
const int rw = bio_data_dir(req->master_bio);
int cpu;
cpu = part_stat_lock();
- part_round_stats(cpu, &mdev->vdisk->part0);
+ part_round_stats(mdev->rq_queue, cpu, &mdev->vdisk->part0);
part_stat_inc(cpu, &mdev->vdisk->part0, ios[rw]);
part_stat_add(cpu, &mdev->vdisk->part0, sectors[rw], req->i.size >> 9);
(void) cpu; /* The macro invocations above want the cpu argument, I do not like
the compiler warning about cpu only assigned but never used... */
- part_inc_in_flight(&mdev->vdisk->part0, rw);
+ part_inc_in_flight(mdev->rq_queue, &mdev->vdisk->part0, rw);
part_stat_unlock();
}
@@ -56,8 +56,8 @@ static void _drbd_end_io_acct(struct drbd_conf *mdev, struct drbd_request *req)
int cpu;
cpu = part_stat_lock();
part_stat_add(cpu, &mdev->vdisk->part0, ticks[rw], duration);
- part_round_stats(cpu, &mdev->vdisk->part0);
- part_dec_in_flight(&mdev->vdisk->part0, rw);
+ part_round_stats(mdev->rq_queue, cpu, &mdev->vdisk->part0);
+ part_dec_in_flight(mdev->rq_queue, &mdev->vdisk->part0, rw);
part_stat_unlock();
}
diff --git a/include/linux/filter.h b/include/linux/filter.h
index cddbb31..15ce55f 100644
--- a/include/linux/filter.h
+++ b/include/linux/filter.h
@@ -763,6 +763,9 @@ void bpf_prog_kallsyms_add(struct bpf_prog *fp);
void bpf_prog_kallsyms_del(struct bpf_prog *fp);
#else /* CONFIG_BPF_JIT */
+struct bpf_prog * __weak trace_bpf_int_jit_compile(struct bpf_prog *prog);
+void __weak trace_bpf_jit_compile(struct bpf_prog *prog);
+void __weak trace_bpf_jit_free(struct bpf_prog *fp);
static inline bool bpf_prog_ebpf_jited(const struct bpf_prog *fp)
{
--
1.8.3.1

View File

@ -1,27 +0,0 @@
From 8b830ee6b0abaae23ca437b0f37e640f9b64582a Mon Sep 17 00:00:00 2001
Message-Id: <8b830ee6b0abaae23ca437b0f37e640f9b64582a.1528231742.git.Jim.Somerville@windriver.com>
From: Jim Somerville <Jim.Somerville@windriver.com>
Date: Wed, 30 May 2018 13:06:58 -0400
Subject: [PATCH 1/1] fix compilation issues
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
---
drivers/base/dma-contiguous.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/base/dma-contiguous.c b/drivers/base/dma-contiguous.c
index a7d5bda..403101d 100644
--- a/drivers/base/dma-contiguous.c
+++ b/drivers/base/dma-contiguous.c
@@ -309,7 +309,7 @@ struct page *dma_alloc_from_contiguous(struct device *dev, size_t count,
if (align > CONFIG_CMA_ALIGNMENT)
align = CONFIG_CMA_ALIGNMENT;
- pr_debug("%s(cma %p, count %d, align %d)\n", __func__, (void *)cma,
+ pr_debug("%s(cma %p, count %zu, align %d)\n", __func__, (void *)cma,
count, align);
if (!count)
--
1.8.3.1

View File

@ -1,10 +1,7 @@
From 02f7bfe8cb36d7903bd7904b05071a2c91bc02a1 Mon Sep 17 00:00:00 2001 From d5c26ebe8a51ee66a644973fb13b3dbd3152203e Mon Sep 17 00:00:00 2001
Message-Id: <02f7bfe8cb36d7903bd7904b05071a2c91bc02a1.1528226387.git.Jim.Somerville@windriver.com>
In-Reply-To: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
References: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
From: Matt Peters <matt.peters@windriver.com> From: Matt Peters <matt.peters@windriver.com>
Date: Mon, 30 May 2016 10:51:02 -0400 Date: Mon, 30 May 2016 10:51:02 -0400
Subject: [PATCH 08/32] intel-iommu: allow ignoring Ethernet device RMRR with Subject: [PATCH 06/10] intel-iommu: allow ignoring Ethernet device RMRR with
IOMMU passthrough IOMMU passthrough
Some BIOS's are reporting DMAR RMRR entries for Ethernet devices Some BIOS's are reporting DMAR RMRR entries for Ethernet devices
@ -16,21 +13,21 @@ passthrough is enabled.
Originally-by: Matt Peters <matt.peters@windriver.com> Originally-by: Matt Peters <matt.peters@windriver.com>
[PG: Added bootarg wrapper and documentation entries.] [PG: Added bootarg wrapper and documentation entries.]
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
Signed-off-by: Nam Ninh <nam.ninh@windriver.com>
Signed-off-by: Nam Ninh <nam.ninh@windriver.com> Signed-off-by: Nam Ninh <nam.ninh@windriver.com>
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com> Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
Signed-off-by: Zhang Zhiguo <zhangzhg@neusoft.com>
Signed-off-by: Dongqi Chen <chen.dq@neusoft.com>
--- ---
Documentation/Intel-IOMMU.txt | 18 ++++++++++++++++++ Documentation/Intel-IOMMU.txt | 18 ++++++++++++++++++
Documentation/kernel-parameters.txt | 5 +++++ Documentation/admin-guide/kernel-parameters.txt | 5 +++++
drivers/iommu/intel-iommu.c | 19 +++++++++++++++++++ drivers/iommu/intel-iommu.c | 19 +++++++++++++++++++
3 files changed, 42 insertions(+) 3 files changed, 42 insertions(+)
diff --git a/Documentation/Intel-IOMMU.txt b/Documentation/Intel-IOMMU.txt diff --git a/Documentation/Intel-IOMMU.txt b/Documentation/Intel-IOMMU.txt
index cf9431d..1dcc349 100644 index 9dae6b4..1080fcb 100644
--- a/Documentation/Intel-IOMMU.txt --- a/Documentation/Intel-IOMMU.txt
+++ b/Documentation/Intel-IOMMU.txt +++ b/Documentation/Intel-IOMMU.txt
@@ -32,6 +32,24 @@ regions will fail. Hence BIOS uses RMRR to specify these regions along with @@ -33,6 +33,24 @@ regions will fail. Hence BIOS uses RMRR to specify these regions along with
devices that need to access these regions. OS is expected to setup devices that need to access these regions. OS is expected to setup
unity mappings for these regions for these devices to access these regions. unity mappings for these regions for these devices to access these regions.
@ -39,7 +36,7 @@ index cf9431d..1dcc349 100644
+ +
+There are reports of BIOS out there that indicate RMRR regions for things +There are reports of BIOS out there that indicate RMRR regions for things
+like ethernet devices. As per mainline commit c875d2c1b8083 ("iommu/vt-d: +like ethernet devices. As per mainline commit c875d2c1b8083 ("iommu/vt-d:
+ Exclude devices using RMRRs from IOMMU API domains") such a device is +Exclude devices using RMRRs from IOMMU API domains") such a device is
+"fundamentally incompatible" with the IOMMU API and "we must prevent such +"fundamentally incompatible" with the IOMMU API and "we must prevent such
+devices from being used by the IOMMU API." However, in the event that +devices from being used by the IOMMU API." However, in the event that
+the RMRR indicated by the BIOS is assumed to be just a reporting error, +the RMRR indicated by the BIOS is assumed to be just a reporting error,
@ -53,13 +50,13 @@ index cf9431d..1dcc349 100644
+may result. +may result.
+ +
How is IOVA generated? How is IOVA generated?
--------------------- ----------------------
diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt diff --git a/Documentation/admin-guide/kernel-parameters.txt b/Documentation/admin-guide/kernel-parameters.txt
index 685554b..0ca635a 100644 index 928b525..cea7932 100644
--- a/Documentation/kernel-parameters.txt --- a/Documentation/admin-guide/kernel-parameters.txt
+++ b/Documentation/kernel-parameters.txt +++ b/Documentation/admin-guide/kernel-parameters.txt
@@ -1318,6 +1318,11 @@ bytes respectively. Such letter suffixes can also be entirely omitted. @@ -1672,6 +1672,11 @@
than 32-bit addressing. The default is to look than 32-bit addressing. The default is to look
for translation below 32-bit and if not available for translation below 32-bit and if not available
then look in the higher range. then look in the higher range.
@ -72,18 +69,18 @@ index 685554b..0ca635a 100644
With this option on every unmap_single operation will With this option on every unmap_single operation will
result in a hardware IOTLB flush operation as opposed result in a hardware IOTLB flush operation as opposed
diff --git a/drivers/iommu/intel-iommu.c b/drivers/iommu/intel-iommu.c diff --git a/drivers/iommu/intel-iommu.c b/drivers/iommu/intel-iommu.c
index 05b0971..d6f4723 100644 index 0962d65..ea478fa 100644
--- a/drivers/iommu/intel-iommu.c --- a/drivers/iommu/intel-iommu.c
+++ b/drivers/iommu/intel-iommu.c +++ b/drivers/iommu/intel-iommu.c
@@ -480,6 +480,7 @@ static int dmar_forcedac; @@ -485,6 +485,7 @@ static int dmar_forcedac;
static int intel_iommu_strict; static int intel_iommu_strict;
static int intel_iommu_superpage = 1; static int intel_iommu_superpage = 1;
static int intel_iommu_ecs = 1; static int intel_iommu_ecs = 1;
+static int intel_iommu_ethrmrr = 1; +static int intel_iommu_ethrmrr = 1;
static int intel_iommu_pasid28;
static int iommu_identity_mapping;
/* We only actually use ECS when PASID support (on the new bit 40) @@ -569,6 +570,15 @@ static int __init intel_iommu_setup(char *str)
* is also advertised. Some early implementations — the ones with
@@ -539,6 +540,15 @@ static int __init intel_iommu_setup(char *str)
} else if (!strncmp(str, "forcedac", 8)) { } else if (!strncmp(str, "forcedac", 8)) {
pr_info("Forcing DAC for PCI devices\n"); pr_info("Forcing DAC for PCI devices\n");
dmar_forcedac = 1; dmar_forcedac = 1;
@ -99,7 +96,7 @@ index 05b0971..d6f4723 100644
} else if (!strncmp(str, "strict", 6)) { } else if (!strncmp(str, "strict", 6)) {
pr_info("Disable batched IOTLB flush\n"); pr_info("Disable batched IOTLB flush\n");
intel_iommu_strict = 1; intel_iommu_strict = 1;
@@ -2820,6 +2830,15 @@ static bool device_is_rmrr_locked(struct device *dev) @@ -2920,6 +2930,15 @@ static bool device_is_rmrr_locked(struct device *dev)
if (IS_USB_DEVICE(pdev) || IS_GFX_DEVICE(pdev)) if (IS_USB_DEVICE(pdev) || IS_GFX_DEVICE(pdev))
return false; return false;
@ -116,5 +113,5 @@ index 05b0971..d6f4723 100644
return true; return true;
-- --
1.8.3.1 2.7.4

View File

@ -1,57 +0,0 @@
From fdb837fb87ff4907436dfab16709b64d6c3488fd Mon Sep 17 00:00:00 2001
Message-Id: <fdb837fb87ff4907436dfab16709b64d6c3488fd.1566590430.git.Jim.Somerville@windriver.com>
From: Tommi Rantala <tt.rantala@gmail.com>
Date: Thu, 7 May 2015 15:12:21 +0300
Subject: [PATCH 1/3] ipvs: fix memory leak in ip_vs_ctl.c
[ commit f30bf2a5cac6c60ab366c4bc6db913597bf4d6ab in Linus' repo ]
Fix memory leak introduced in commit a0840e2e165a ("IPVS: netns,
ip_vs_ctl local vars moved to ipvs struct."):
unreferenced object 0xffff88005785b800 (size 2048):
comm "(-localed)", pid 1434, jiffies 4294755650 (age 1421.089s)
hex dump (first 32 bytes):
bb 89 0b 83 ff ff ff ff b0 78 f0 4e 00 88 ff ff .........x.N....
04 00 00 00 a4 01 00 00 00 00 00 00 00 00 00 00 ................
backtrace:
[<ffffffff8262ea8e>] kmemleak_alloc+0x4e/0xb0
[<ffffffff811fba74>] __kmalloc_track_caller+0x244/0x430
[<ffffffff811b88a0>] kmemdup+0x20/0x50
[<ffffffff823276b7>] ip_vs_control_net_init+0x1f7/0x510
[<ffffffff8231d630>] __ip_vs_init+0x100/0x250
[<ffffffff822363a1>] ops_init+0x41/0x190
[<ffffffff82236583>] setup_net+0x93/0x150
[<ffffffff82236cc2>] copy_net_ns+0x82/0x140
[<ffffffff810ab13d>] create_new_namespaces+0xfd/0x190
[<ffffffff810ab49a>] unshare_nsproxy_namespaces+0x5a/0xc0
[<ffffffff810833e3>] SyS_unshare+0x173/0x310
[<ffffffff8265cbd7>] system_call_fastpath+0x12/0x6f
[<ffffffffffffffff>] 0xffffffffffffffff
Fixes: a0840e2e165a ("IPVS: netns, ip_vs_ctl local vars moved to ipvs struct.")
Signed-off-by: Tommi Rantala <tt.rantala@gmail.com>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Simon Horman <horms@verge.net.au>
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
---
net/netfilter/ipvs/ip_vs_ctl.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/net/netfilter/ipvs/ip_vs_ctl.c b/net/netfilter/ipvs/ip_vs_ctl.c
index 02409f3..3738b84 100644
--- a/net/netfilter/ipvs/ip_vs_ctl.c
+++ b/net/netfilter/ipvs/ip_vs_ctl.c
@@ -3843,6 +3843,9 @@ static void __net_exit ip_vs_control_net_cleanup_sysctl(struct net *net)
cancel_delayed_work_sync(&ipvs->defense_work);
cancel_work_sync(&ipvs->defense_work.work);
unregister_net_sysctl_table(ipvs->sysctl_hdr);
+
+ if (!net_eq(net, &init_net))
+ kfree(ipvs->sysctl_tbl);
}
#else
--
1.8.3.1

View File

@ -1,6 +0,0 @@
CONFIG_SIGEXIT=y
CONFIG_DMA_CMA=y
CONFIG_CMA_SIZE_MBYTES=16
CONFIG_CMA_SIZE_SEL_MBYTES=y
CONFIG_CMA_ALIGNMENT=8
CONFIG_CMA_AREAS=7

View File

@ -1,6 +0,0 @@
CONFIG_SIGEXIT=y
CONFIG_DMA_CMA=y
CONFIG_CMA_SIZE_MBYTES=16
CONFIG_CMA_SIZE_SEL_MBYTES=y
CONFIG_CMA_ALIGNMENT=8
CONFIG_CMA_AREAS=7

View File

@ -1,965 +0,0 @@
# Add builtin
CONFIG_MAXSMP=n
CONFIG_NR_CPUS=256
CONFIG_BLK_DEV_LOOP=y
CONFIG_BLK_DEV_SR=y
CONFIG_SCSI_SAS_ATTRS=y
CONFIG_ISCSI_TCP=y
# SCSI Related Drivers
# Let's enable lots of them, pretty much anything RAID capable
CONFIG_ATA=y
CONFIG_SCSI_SAS_LIBSAS=y
CONFIG_SCSI_SAS_ATA=y
CONFIG_BLK_DEV_3W_XXXX_RAID=y
CONFIG_SCSI_3W_9XXX=y
CONFIG_SCSI_3W_SAS=y
CONFIG_SCSI_AACRAID=y
CONFIG_SCSI_DPT_I2O=y
CONFIG_SCSI_ARCMSR=y
CONFIG_SCSI_HPTIOP=y
CONFIG_SCSI_GDTH=y
CONFIG_SCSI_IPS=y
CONFIG_SCSI_STEX=y
CONFIG_SCSI_PMCRAID=y
CONFIG_SCSI_HPSA=y
CONFIG_MEGARAID_SAS=y
CONFIG_SCSI_SMARTPQI=y
# These two will only build as modules
CONFIG_SCSI_MPT2SAS=m
CONFIG_SCSI_MPT3SAS=m
CONFIG_SCSI_VIRTIO=y
CONFIG_FUSION_SAS=y
CONFIG_SCSI_AIC94XX=y
CONFIG_SCSI_MVSAS=y
#
CONFIG_SOFT_WATCHDOG=y
CONFIG_VIRTIO=y
CONFIG_VIRTIO_PCI=y
CONFIG_VIRTIO_MMIO=y
CONFIG_ISO9660_FS=y
CONFIG_VFAT_FS=y
CONFIG_NLS_ISO8859_1=y
#CONFIG_MCORE2=y
CONFIG_SIGEXIT=y
CONFIG_SCHEDSTATS=y
# Enable runtime Huge TLB support
CONFIG_DMA_CMA=y
CONFIG_CMA_SIZE_MBYTES=16
CONFIG_CMA_SIZE_SEL_MBYTES=y
CONFIG_CMA_ALIGNMENT=8
CONFIG_CMA_AREAS=7
# Turn on Intel IOMMU
CONFIG_INTEL_IOMMU_DEFAULT_ON=y
# Turn off network drivers that we want
# to build out-of-tree
CONFIG_I40E=n
CONFIG_I40EVF=n
CONFIG_IXGB=n
CONFIG_IXGBE=n
CONFIG_IXGBEVF=n
CONFIG_MLX4_EN=n
CONFIG_MLX4_CORE=n
CONFIG_MLX5_EN=n
CONFIG_MLX5_CORE=n
# Turn off TPM drivers that we want
# to build out-of-tree. This will
# disable the TPM HW-RandomNUmberGenerator(RNG)
# and TrustedKeys modules as well, since
# they require the in-kernel TPM driver.
# Both these modules will also need to be
# built out-of-tree when needed.
CONFIG_TCG_TPM=n
CONFIG_TCG_TIS=n
CONFIG_HW_RANDOM_TPM=n
CONFIG_TRUSTED_KEYS=n
CONFIG_TCG_TIS_I2C_ATMEL=n
CONFIG_TCG_TIS_I2C_INFINEON=n
CONFIG_TCG_TIS_I2C_NUVOTON=n
CONFIG_TCG_NSC=n
CONFIG_TCG_ATMEL=n
CONFIG_TCG_INFINEON=n
CONFIG_TCG_CRB=n
CONFIG_TCG_TIS_ST33ZP24=n
CONFIG_TCG_TIS_ST33ZP24_I2C=n
# Also disable TPM Integrity Measurement Architecture
# (IMA), as this will be built out of tree but ensure
# that all their dependencies (that comes from the base kernel)
# that are marked as "select" within the Integrity / IMA
# Kconfigs are still enabled
CONFIG_INTEGRITY=n
CONFIG_IMA=n
CONFIG_EVM=n
CONFIG_SIGNATURE=y
CONFIG_KEYS=y
CONFIG_ASYMMETRIC_KEY_TYPE=y
CONFIG_ASYMMETRIC_PUBLIC_KEY_SUBTYPE=y
CONFIG_PUBLIC_KEY_ALGO_RSA=y
CONFIG_X509_CERTIFICATE_PARSER=y
CONFIG_SECURITYFS=y
CONFIG_CRYPTO=y
CONFIG_CRYPTO_HMAC=y
CONFIG_CRYPTO_MD5=y
CONFIG_CRYPTO_SHA1=y
#Enable Intel RDT
CONFIG_KERNFS=y
CONFIG_INTEL_RDT_A=y
#Enable PTP clock support
CONFIG_PPS=y
CONFIG_PTP_1588_CLOCK=y
CONFIG_PTP_1588_CLOCK_PCH=y
CONFIG_PTP_1588_CLOCK_KVM=y
CONFIG_DP83640_PHY=y
# Remove unneeded stuff (including stuff exposed
# by saying y to new options above.
CONFIG_VIRTIO_MMIO_CMDLINE_DEVICES=n
CONFIG_PANIC_ON_OOPS=n
CONFIG_SOUND=n
CONFIG_FIREWIRE=n
CONFIG_KPROBES=n
CONFIG_XEN=n
CONFIG_BT=n
CONFIG_INTEL_MEI=n
CONFIG_USB_USBNET=n
CONFIG_RTL8187=n
CONFIG_MWL8K=n
CONFIG_CFG80211=n
CONFIG_WAN=n
CONFIG_ISDN=n
CONFIG_INPUT_TOUCHSCREEN=n
CONFIG_SSB=n
CONFIG_BCMA=n
CONFIG_MEDIA_SUPPORT=n
CONFIG_ACPI_PROCESSOR_AGGREGATOR=n
CONFIG_ACPI_EXTLOG=n
CONFIG_NET_FOU=n
CONFIG_NET_FOU_IP_TUNNELS=n
CONFIG_GENEVE=n
CONFIG_IPV6_VTI=n
CONFIG_NETFILTER_XT_TARGET_TPROXY=n
CONFIG_NETFILTER_XT_MATCH_CGROUP=n
CONFIG_NETFILTER_XT_MATCH_SOCKET=n
CONFIG_NET_SCH_FQ=n
CONFIG_NET_CLS_BPF=n
CONFIG_BLK_DEV_NULL_BLK=n
CONFIG_GENWQE=n
CONFIG_CXL_BASE=n
CONFIG_DM_ERA=n
CONFIG_DM_RAID=n
CONFIG_DM_SWITCH=n
CONFIG_NLMON=n
CONFIG_FM10K=n
CONFIG_CRASH=n
CONFIG_IPMI_SSIF=n
CONFIG_POWERCAP=n
CONFIG_DRM_BOCHS=n
CONFIG_HID_RMI=n
CONFIG_NET_DMA_RH_KABI=n
CONFIG_HP_WIRELESS=n
CONFIG_NFSD_V4_SECURITY_LABEL=n
CONFIG_DEBUG_SHIRQ=n
CONFIG_PERSISTENT_KEYRINGS=n
CONFIG_BIG_KEYS=n
CONFIG_SECURITY_SECURELEVEL=n
CONFIG_CRYPTO_MCRYPTD=n
CONFIG_CRYPTO_SHA1_MB=n
CONFIG_CRYPTO_DRBG_MENU=n
CONFIG_CRYPTO_DEV_QAT=n
CONFIG_CRYPTO_DEV_QAT_DH895xCCVF=n
CONFIG_CRYPTO_DEV_QAT_DH895xCC=n
CONFIG_CRYPTO_DEV_QAT_C3XXX=n
CONFIG_CRYPTO_DEV_QAT_C62X=n
CONFIG_CRYPTO_DEV_QAT_C3XXXVF=n
CONFIG_CRYPTO_DEV_QAT_C62XVF=n
CONFIG_BPF_JIT=n
CONFIG_PARPORT=n
CONFIG_CDROM_PKTCDVD=n
CONFIG_SENSORS_LIS3LV02D=n
CONFIG_SGI_IOC4=n
CONFIG_TIFM_CORE=n
CONFIG_ENCLOSURE_SERVICES=n
CONFIG_APDS9802ALS=n
CONFIG_ISL29003=n
CONFIG_ISL29020=n
CONFIG_SENSORS_TSL2550=n
CONFIG_SENSORS_BH1770=n
CONFIG_SENSORS_APDS990X=n
CONFIG_PCH_PHUB=n
CONFIG_EEPROM_AT24=n
CONFIG_EEPROM_MAX6875=n
CONFIG_EEPROM_93CX6=n
CONFIG_CB710_CORE=n
CONFIG_SENSORS_LIS3_I2C=n
CONFIG_ALTERA_STAPL=n
CONFIG_VMWARE_VMCI=n
CONFIG_CHR_DEV_ST=n
CONFIG_CHR_DEV_OSST=n
CONFIG_CHR_DEV_SG=n
CONFIG_CHR_DEV_SCH=n
CONFIG_SCSI_CONSTANTS=n
CONFIG_SCSI_LOGGING=n
CONFIG_SCSI_CXGB3_ISCSI=n
CONFIG_SCSI_CXGB4_ISCSI=n
CONFIG_SCSI_AIC79XX=n
CONFIG_SCSI_MVUMI=n
CONFIG_SCSI_MPT2SAS_LOGGING=n
CONFIG_SCSI_MPT3SAS_LOGGING=n
CONFIG_SCSI_UFSHCD=n
CONFIG_VMWARE_PVSCSI=n
CONFIG_FCOE=n
CONFIG_FCOE_FNIC=n
CONFIG_SCSI_INITIO=n
CONFIG_SCSI_PM8001=n
CONFIG_SCSI_SRP=n
CONFIG_SATA_ACARD_AHCI=n
CONFIG_SATA_SIL24=n
CONFIG_PDC_ADMA=n
CONFIG_SATA_QSTOR=n
CONFIG_SATA_SX4=n
CONFIG_SATA_MV=n
CONFIG_SATA_NV=n
CONFIG_SATA_PROMISE=n
CONFIG_SATA_SIL=n
CONFIG_SATA_SIS=n
CONFIG_SATA_SVW=n
CONFIG_SATA_ULI=n
CONFIG_SATA_VIA=n
CONFIG_SATA_VITESSE=n
CONFIG_PATA_ALI=n
CONFIG_PATA_AMD=n
CONFIG_PATA_ARASAN_CF=n
CONFIG_PATA_ARTOP=n
CONFIG_PATA_ATIIXP=n
CONFIG_PATA_ATP867X=n
CONFIG_PATA_CMD64X=n
CONFIG_PATA_CS5536=n
CONFIG_PATA_HPT366=n
CONFIG_PATA_HPT37X=n
CONFIG_PATA_HPT3X2N=n
CONFIG_PATA_HPT3X3=n
CONFIG_PATA_IT8213=n
CONFIG_PATA_IT821X=n
CONFIG_PATA_JMICRON=n
CONFIG_PATA_MARVELL=n
CONFIG_PATA_NETCELL=n
CONFIG_PATA_NINJA32=n
CONFIG_PATA_OLDPIIX=n
CONFIG_PATA_PDC2027X=n
CONFIG_PATA_PDC_OLD=n
CONFIG_PATA_RDC=n
CONFIG_PATA_SCH=n
CONFIG_PATA_SERVERWORKS=n
CONFIG_PATA_SIL680=n
CONFIG_PATA_SIS=n
CONFIG_PATA_TOSHIBA=n
CONFIG_PATA_VIA=n
CONFIG_DM_DEBUG=n
CONFIG_MACINTOSH_DRIVERS=n
CONFIG_NET_FC=n
CONFIG_NET_TEAM=n
CONFIG_ATL2=n
CONFIG_ATL1=n
CONFIG_ATL1E=n
CONFIG_ATL1C=n
CONFIG_ALX=n
CONFIG_ARM_AT91_ETHER=n
CONFIG_MACB=n
CONFIG_B44=n
CONFIG_BNA=n
CONFIG_NET_CALXEDA_XGMAC=n
CONFIG_CHELSIO_T3=n
CONFIG_CHELSIO_T4=n
CONFIG_CHELSIO_T4VF=n
CONFIG_NET_TULIP=n
CONFIG_IP1000=n
CONFIG_JME=n
CONFIG_MVMDIO=n
CONFIG_SKGE=n
CONFIG_SKY2=n
CONFIG_MYRI10GE=n
CONFIG_PCH_GBE=n
CONFIG_ETHOC=n
CONFIG_QLCNIC=n
CONFIG_QLGE=n
CONFIG_NETXEN_NIC=n
CONFIG_SFC=n
CONFIG_EPIC100=n
CONFIG_SMSC9420=n
CONFIG_AT803X_PHY=n
CONFIG_DAVICOM_PHY=n
CONFIG_QSEMI_PHY=n
CONFIG_LXT_PHY=n
CONFIG_CICADA_PHY=n
CONFIG_VITESSE_PHY=n
CONFIG_SMSC_PHY=n
CONFIG_BCM87XX_PHY=n
CONFIG_ICPLUS_PHY=n
CONFIG_REALTEK_PHY=n
CONFIG_NATIONAL_PHY=n
CONFIG_STE10XP=n
CONFIG_LSI_ET1011C_PHY=n
CONFIG_MICREL_PHY=n
CONFIG_MDIO_BITBANG=n
CONFIG_RT_GROUP_SCHED=n
CONFIG_OPROFILE=n
CONFIG_SYSTEM_BLACKLIST_KEYRING=n
CONFIG_OSF_PARTITION=n
CONFIG_AMIGA_PARTITION=n
CONFIG_MAC_PARTITION=n
CONFIG_BSD_DISKLABEL=n
CONFIG_MINIX_SUBPARTITION=n
CONFIG_SOLARIS_X86_PARTITION=n
CONFIG_UNIXWARE_DISKLABEL=n
CONFIG_SGI_PARTITION=n
CONFIG_SUN_PARTITION=n
CONFIG_KARMA_PARTITION=n
CONFIG_X86_UV=n
CONFIG_I8K=n
CONFIG_MICROCODE_AMD=n
CONFIG_MICROCODE_AMD_EARLY=n
CONFIG_MOVABLE_NODE=n
CONFIG_MEMORY_HOTPLUG=n
CONFIG_BOOTPARAM_HOTPLUG_CPU0=n
CONFIG_X86_POWERNOW_K8=n
CONFIG_X86_AMD_FREQ_SENSITIVITY=n
CONFIG_X86_P4_CLOCKMOD=n
CONFIG_PCIE_ECRC=n
CONFIG_PCIEAER_INJECT=n
CONFIG_PCCARD=n
CONFIG_HOTPLUG_PCI_ACPI_IBM=n
CONFIG_HOTPLUG_PCI_SHPC=n
CONFIG_XFRM_STATISTICS=n
CONFIG_IP_FIB_TRIE_STATS=n
CONFIG_PPP_MPPE=n
CONFIG_USB_CATC=n
CONFIG_USB_KAWETH=n
CONFIG_USB_PEGASUS=n
CONFIG_USB_RTL8150=n
CONFIG_USB_RTL8152=n
CONFIG_USB_HSO=n
CONFIG_USB_IPHETH=n
CONFIG_INPUT_FF_MEMLESS=n
CONFIG_INPUT_POLLDEV=n
CONFIG_INPUT_SPARSEKMAP=n
CONFIG_MOUSE_PS2_ELANTECH=n
CONFIG_MOUSE_PS2_SENTELIC=n
CONFIG_MOUSE_APPLETOUCH=n
CONFIG_MOUSE_BCM5974=n
CONFIG_MOUSE_CYAPA=n
CONFIG_MOUSE_VSXXXAA=n
CONFIG_MOUSE_SYNAPTICS_I2C=n
CONFIG_MOUSE_SYNAPTICS_USB=n
CONFIG_INPUT_TABLET=n
CONFIG_INPUT_PCSPKR=n
CONFIG_INPUT_APANEL=n
CONFIG_INPUT_ATLAS_BTNS=n
CONFIG_INPUT_ATI_REMOTE2=n
CONFIG_INPUT_KEYSPAN_REMOTE=n
CONFIG_INPUT_POWERMATE=n
CONFIG_INPUT_YEALINK=n
CONFIG_INPUT_CM109=n
CONFIG_INPUT_UINPUT=n
CONFIG_SERIO_ALTERA_PS2=n
CONFIG_SERIO_ARC_PS2=n
CONFIG_NOZOMI=n
CONFIG_N_GSM=n
CONFIG_SERIAL_JSM=n
CONFIG_SERIAL_ARC=n
CONFIG_HANGCHECK_TIMER=n
CONFIG_TELCLOCK=n
CONFIG_I2C_AMD756=n
CONFIG_I2C_AMD8111=n
CONFIG_I2C_PIIX4=n
CONFIG_I2C_NFORCE2=n
CONFIG_I2C_SIS96X=n
CONFIG_I2C_VIA=n
CONFIG_I2C_VIAPRO=n
CONFIG_I2C_PCA_PLATFORM=n
CONFIG_I2C_SIMTEC=n
CONFIG_I2C_DIOLAN_U2C=n
CONFIG_I2C_PARPORT_LIGHT=n
CONFIG_PPS_CLIENT_LDISC=n
CONFIG_PPS_CLIENT_GPIO=n
CONFIG_CHARGER_SMB347=n
CONFIG_SENSORS_ABITUGURU=n
CONFIG_SENSORS_ABITUGURU3=n
CONFIG_SENSORS_AD7414=n
CONFIG_SENSORS_AD7418=n
CONFIG_SENSORS_ADM1021=n
CONFIG_SENSORS_ADM1025=n
CONFIG_SENSORS_ADM1026=n
CONFIG_SENSORS_ADM1029=n
CONFIG_SENSORS_ADM1031=n
CONFIG_SENSORS_ADM9240=n
CONFIG_SENSORS_ADT7410=n
CONFIG_SENSORS_ADT7411=n
CONFIG_SENSORS_ADT7462=n
CONFIG_SENSORS_ADT7470=n
CONFIG_SENSORS_ADT7475=n
CONFIG_SENSORS_ASC7621=n
CONFIG_SENSORS_K8TEMP=n
CONFIG_SENSORS_K10TEMP=n
CONFIG_SENSORS_FAM15H_POWER=n
CONFIG_SENSORS_ASB100=n
CONFIG_SENSORS_ATXP1=n
CONFIG_SENSORS_DS620=n
CONFIG_SENSORS_DS1621=n
CONFIG_SENSORS_I5K_AMB=n
CONFIG_SENSORS_F71805F=n
CONFIG_SENSORS_F71882FG=n
CONFIG_SENSORS_F75375S=n
CONFIG_SENSORS_FSCHMD=n
CONFIG_SENSORS_G760A=n
CONFIG_SENSORS_GL518SM=n
CONFIG_SENSORS_GL520SM=n
CONFIG_SENSORS_IBMAEM=n
CONFIG_SENSORS_IBMPEX=n
CONFIG_SENSORS_IT87=n
CONFIG_SENSORS_LINEAGE=n
CONFIG_SENSORS_LM63=n
CONFIG_SENSORS_LM73=n
CONFIG_SENSORS_LM75=n
CONFIG_SENSORS_LM77=n
CONFIG_SENSORS_LM78=n
CONFIG_SENSORS_LM80=n
CONFIG_SENSORS_LM83=n
CONFIG_SENSORS_LM85=n
CONFIG_SENSORS_LM87=n
CONFIG_SENSORS_LM90=n
CONFIG_SENSORS_LM92=n
CONFIG_SENSORS_LM93=n
CONFIG_SENSORS_LTC4151=n
CONFIG_SENSORS_LTC4215=n
CONFIG_SENSORS_LTC4245=n
CONFIG_SENSORS_LTC4261=n
CONFIG_SENSORS_LM95234=n
CONFIG_SENSORS_LM95241=n
CONFIG_SENSORS_LM95245=n
CONFIG_SENSORS_MAX16065=n
CONFIG_SENSORS_MAX1619=n
CONFIG_SENSORS_MAX1668=n
CONFIG_SENSORS_MAX197=n
CONFIG_SENSORS_MAX6639=n
CONFIG_SENSORS_MAX6642=n
CONFIG_SENSORS_MAX6650=n
CONFIG_SENSORS_MAX6697=n
CONFIG_SENSORS_MCP3021=n
CONFIG_SENSORS_NCT6775=n
CONFIG_SENSORS_NTC_THERMISTOR=n
CONFIG_SENSORS_PC87360=n
CONFIG_SENSORS_PC87427=n
CONFIG_SENSORS_PCF8591=n
CONFIG_SENSORS_PMBUS=n
CONFIG_SENSORS_ADM1275=n
CONFIG_SENSORS_LM25066=n
CONFIG_SENSORS_LTC2978=n
CONFIG_SENSORS_MAX16064=n
CONFIG_SENSORS_MAX34440=n
CONFIG_SENSORS_MAX8688=n
CONFIG_SENSORS_UCD9000=n
CONFIG_SENSORS_UCD9200=n
CONFIG_SENSORS_ZL6100=n
CONFIG_SENSORS_SHT21=n
CONFIG_SENSORS_SIS5595=n
CONFIG_SENSORS_DME1737=n
CONFIG_SENSORS_EMC1403=n
CONFIG_SENSORS_EMC6W201=n
CONFIG_SENSORS_SMSC47M1=n
CONFIG_SENSORS_SMSC47M192=n
CONFIG_SENSORS_SMSC47B397=n
CONFIG_SENSORS_SCH56XX_COMMON=n
CONFIG_SENSORS_SCH5627=n
CONFIG_SENSORS_SCH5636=n
CONFIG_SENSORS_ADS1015=n
CONFIG_SENSORS_ADS7828=n
CONFIG_SENSORS_AMC6821=n
CONFIG_SENSORS_INA209=n
CONFIG_SENSORS_INA2XX=n
CONFIG_SENSORS_THMC50=n
CONFIG_SENSORS_TMP102=n
CONFIG_SENSORS_TMP401=n
CONFIG_SENSORS_TMP421=n
CONFIG_SENSORS_VIA_CPUTEMP=n
CONFIG_SENSORS_VIA686A=n
CONFIG_SENSORS_VT1211=n
CONFIG_SENSORS_VT8231=n
CONFIG_SENSORS_W83781D=n
CONFIG_SENSORS_W83791D=n
CONFIG_SENSORS_W83792D=n
CONFIG_SENSORS_W83793=n
CONFIG_SENSORS_W83795=n
CONFIG_SENSORS_W83L785TS=n
CONFIG_SENSORS_W83L786NG=n
CONFIG_SENSORS_W83627HF=n
CONFIG_SENSORS_W83627EHF=n
CONFIG_SENSORS_APPLESMC=n
CONFIG_SENSORS_ATK0110=n
CONFIG_ALIM1535_WDT=n
CONFIG_ALIM7101_WDT=n
CONFIG_F71808E_WDT=n
CONFIG_SP5100_TCO=n
CONFIG_SBC_FITPC2_WATCHDOG=n
CONFIG_IB700_WDT=n
CONFIG_IBMASR=n
CONFIG_IT8712F_WDT=n
CONFIG_IT87_WDT=n
CONFIG_NV_TCO=n
CONFIG_SMSC_SCH311X_WDT=n
CONFIG_VIA_WDT=n
CONFIG_W83627HF_WDT=n
CONFIG_W83697HF_WDT=n
CONFIG_W83697UG_WDT=n
CONFIG_W83877F_WDT=n
CONFIG_W83977F_WDT=n
CONFIG_MACHZ_WDT=n
CONFIG_PCIPCWATCHDOG=n
CONFIG_WDTPCI=n
CONFIG_USBPCWATCHDOG=n
CONFIG_MFD_VIPERBOARD=n
CONFIG_MFD_SM501=n
CONFIG_MFD_VX855=n
CONFIG_AGP_AMD64=n
CONFIG_AGP_SIS=n
CONFIG_AGP_VIA=n
CONFIG_VGA_SWITCHEROO=n
CONFIG_DRM_LOAD_EDID_FIRMWARE=n
CONFIG_DRM_I2C_CH7006=n
CONFIG_DRM_I2C_SIL164=n
CONFIG_DRM_I2C_NXP_TDA998X=n
CONFIG_DRM_RADEON=n
CONFIG_DRM_NOUVEAU=n
CONFIG_DRM_VMWGFX=n
CONFIG_DRM_GMA500=n
CONFIG_DRM_GMA600=n
CONFIG_DRM_GMA3600=n
CONFIG_DRM_UDL=n
CONFIG_DRM_AST=n
CONFIG_DRM_MGAG200=n
CONFIG_DRM_CIRRUS_QEMU=n
CONFIG_DRM_QXL=n
CONFIG_FB_SYS_FILLRECT=n
CONFIG_FB_SYS_COPYAREA=n
CONFIG_FB_SYS_IMAGEBLIT=n
CONFIG_FB_SYS_FOPS=n
CONFIG_FB_BACKLIGHT=n
CONFIG_LCD_PLATFORM=n
CONFIG_BACKLIGHT_APPLE=n
CONFIG_BACKLIGHT_LP855X=n
CONFIG_VGACON_SOFT_SCROLLBACK=n
CONFIG_FRAMEBUFFER_CONSOLE_ROTATION=n
CONFIG_LOGO=n
CONFIG_HID_BATTERY_STRENGTH=n
CONFIG_HIDRAW=n
CONFIG_UHID=n
CONFIG_HID_ACRUX=n
CONFIG_HID_APPLEIR=n
CONFIG_HID_AUREAL=n
CONFIG_HID_DRAGONRISE=n
CONFIG_HID_ELECOM=n
CONFIG_HID_HOLTEK=n
CONFIG_HID_KEYTOUCH=n
CONFIG_HID_KYE=n
CONFIG_HID_UCLOGIC=n
CONFIG_HID_WALTOP=n
CONFIG_HID_GYRATION=n
CONFIG_HID_ICADE=n
CONFIG_HID_TWINHAN=n
CONFIG_HID_LCPOWER=n
CONFIG_HID_LENOVO_TPKBD=n
CONFIG_HID_MAGICMOUSE=n
CONFIG_HID_NTRIG=n
CONFIG_HID_ORTEK=n
CONFIG_HID_PANTHERLORD=n
CONFIG_HID_PETALYNX=n
CONFIG_HID_PICOLCD=n
CONFIG_HID_PRIMAX=n
CONFIG_HID_PS3REMOTE=n
CONFIG_HID_ROCCAT=n
CONFIG_HID_SAITEK=n
CONFIG_HID_SAMSUNG=n
CONFIG_HID_SONY=n
CONFIG_HID_SPEEDLINK=n
CONFIG_HID_STEELSERIES=n
CONFIG_HID_SUNPLUS=n
CONFIG_HID_GREENASIA=n
CONFIG_HID_SMARTJOYPLUS=n
CONFIG_HID_TIVO=n
CONFIG_HID_TOPSEED=n
CONFIG_HID_THINGM=n
CONFIG_HID_THRUSTMASTER=n
CONFIG_HID_WACOM=n
CONFIG_HID_WIIMOTE=n
CONFIG_HID_ZEROPLUS=n
CONFIG_HID_ZYDACRON=n
CONFIG_HID_PID=n
CONFIG_USB_HIDDEV=n
CONFIG_USB_ANNOUNCE_NEW_DEVICES=n
CONFIG_USB_MON=n
CONFIG_USB_WUSB_CBAF=n
CONFIG_USB_OHCI_HCD=n
CONFIG_USB_ACM=n
CONFIG_USB_PRINTER=n
CONFIG_USB_WDM=n
CONFIG_USB_TMC=n
CONFIG_USB_STORAGE_REALTEK=n
CONFIG_USB_STORAGE_DATAFAB=n
CONFIG_USB_STORAGE_FREECOM=n
CONFIG_USB_STORAGE_ISD200=n
CONFIG_USB_STORAGE_USBAT=n
CONFIG_USB_STORAGE_SDDR09=n
CONFIG_USB_STORAGE_SDDR55=n
CONFIG_USB_STORAGE_JUMPSHOT=n
CONFIG_USB_STORAGE_ALAUDA=n
CONFIG_USB_STORAGE_ONETOUCH=n
CONFIG_USB_STORAGE_KARMA=n
CONFIG_USB_STORAGE_CYPRESS_ATACB=n
CONFIG_USB_STORAGE_ENE_UB6250=n
CONFIG_USB_MDC800=n
CONFIG_USB_MICROTEK=n
CONFIG_USB_SERIAL_AIRCABLE=n
CONFIG_USB_SERIAL_ARK3116=n
CONFIG_USB_SERIAL_BELKIN=n
CONFIG_USB_SERIAL_WHITEHEAT=n
CONFIG_USB_SERIAL_DIGI_ACCELEPORT=n
CONFIG_USB_SERIAL_CYPRESS_M8=n
CONFIG_USB_SERIAL_EMPEG=n
CONFIG_USB_SERIAL_VISOR=n
CONFIG_USB_SERIAL_IPAQ=n
CONFIG_USB_SERIAL_IR=n
CONFIG_USB_SERIAL_EDGEPORT=n
CONFIG_USB_SERIAL_EDGEPORT_TI=n
CONFIG_USB_SERIAL_GARMIN=n
CONFIG_USB_SERIAL_IPW=n
CONFIG_USB_SERIAL_IUU=n
CONFIG_USB_SERIAL_KEYSPAN_PDA=n
CONFIG_USB_SERIAL_KEYSPAN=n
CONFIG_USB_SERIAL_KLSI=n
CONFIG_USB_SERIAL_KOBIL_SCT=n
CONFIG_USB_SERIAL_MCT_U232=n
CONFIG_USB_SERIAL_MOS7720=n
CONFIG_USB_SERIAL_MOS7840=n
CONFIG_USB_SERIAL_NAVMAN=n
CONFIG_USB_SERIAL_OTI6858=n
CONFIG_USB_SERIAL_QCAUX=n
CONFIG_USB_SERIAL_QUALCOMM=n
CONFIG_USB_SERIAL_SPCP8X5=n
CONFIG_USB_SERIAL_SAFE=n
CONFIG_USB_SERIAL_SIERRAWIRELESS=n
CONFIG_USB_SERIAL_SYMBOL=n
CONFIG_USB_SERIAL_TI=n
CONFIG_USB_SERIAL_CYBERJACK=n
CONFIG_USB_SERIAL_XIRCOM=n
CONFIG_USB_SERIAL_OPTION=n
CONFIG_USB_SERIAL_OMNINET=n
CONFIG_USB_SERIAL_OPTICON=n
CONFIG_USB_SERIAL_XSENS_MT=n
CONFIG_USB_SERIAL_SSU100=n
CONFIG_USB_SERIAL_QT2=n
CONFIG_USB_SERIAL_DEBUG=n
CONFIG_USB_EMI62=n
CONFIG_USB_EMI26=n
CONFIG_USB_ADUTUX=n
CONFIG_USB_SEVSEG=n
CONFIG_USB_LEGOTOWER=n
CONFIG_USB_LCD=n
CONFIG_USB_LED=n
CONFIG_USB_IDMOUSE=n
CONFIG_USB_FTDI_ELAN=n
CONFIG_USB_APPLEDISPLAY=n
CONFIG_USB_SISUSBVGA=n
CONFIG_USB_LD=n
CONFIG_USB_IOWARRIOR=n
CONFIG_USB_ISIGHTFW=n
CONFIG_USB_EZUSB_FX2=n
CONFIG_USB_HSIC_USB3503=n
CONFIG_USB_ATM=n
CONFIG_UWB=n
CONFIG_MMC_RICOH_MMC=n
CONFIG_MMC_TIFM_SD=n
CONFIG_MMC_CB710=n
CONFIG_MMC_VIA_SDMMC=n
CONFIG_MMC_VUB300=n
CONFIG_MMC_USHC=n
CONFIG_MEMSTICK=n
CONFIG_LEDS_LM3530=n
CONFIG_LEDS_LP3944=n
CONFIG_LEDS_LP5521=n
CONFIG_LEDS_LP5523=n
CONFIG_LEDS_LP5562=n
CONFIG_LEDS_CLEVO_MAIL=n
CONFIG_LEDS_INTEL_SS4200=n
CONFIG_LEDS_BLINKM=n
CONFIG_LEDS_TRIGGER_TIMER=n
CONFIG_LEDS_TRIGGER_ONESHOT=n
CONFIG_LEDS_TRIGGER_HEARTBEAT=n
CONFIG_LEDS_TRIGGER_BACKLIGHT=n
CONFIG_LEDS_TRIGGER_TRANSIENT=n
CONFIG_LEDS_TRIGGER_CAMERA=n
CONFIG_INFINIBAND=n
CONFIG_EDAC=n
CONFIG_UIO_CIF=n
CONFIG_UIO_AEC=n
CONFIG_UIO_SERCOS3=n
CONFIG_STAGING=n
CONFIG_ACERHDF=n
CONFIG_ASUS_LAPTOP=n
CONFIG_CHROMEOS_LAPTOP=n
CONFIG_FUJITSU_LAPTOP=n
CONFIG_FUJITSU_TABLET=n
CONFIG_AMILO_RFKILL=n
CONFIG_HP_ACCEL=n
CONFIG_MSI_LAPTOP=n
CONFIG_PANASONIC_LAPTOP=n
CONFIG_COMPAL_LAPTOP=n
CONFIG_SONY_LAPTOP=n
CONFIG_IDEAPAD_LAPTOP=n
CONFIG_THINKPAD_ACPI=n
CONFIG_SENSORS_HDAPS=n
CONFIG_EEEPC_LAPTOP=n
CONFIG_ACPI_WMI=n
CONFIG_TOPSTAR_LAPTOP=n
CONFIG_TOSHIBA_BT_RFKILL=n
CONFIG_ACPI_CMPC=n
CONFIG_SAMSUNG_LAPTOP=n
CONFIG_INTEL_OAKTRAIL=n
CONFIG_SAMSUNG_Q10=n
CONFIG_APPLE_GMUX=n
CONFIG_PVPANIC=n
CONFIG_EDD=n
CONFIG_DELL_RBU=n
CONFIG_DCDBAS=n
CONFIG_JBD_DEBUG=n
CONFIG_FANOTIFY=n
CONFIG_JOLIET=n
CONFIG_UDF_FS=n
CONFIG_CRAMFS=n
CONFIG_SQUASHFS=n
CONFIG_EFIVAR_FS=n
CONFIG_SUNRPC_DEBUG=n
CONFIG_NLS_MAC_ROMAN=n
CONFIG_NLS_MAC_CELTIC=n
CONFIG_NLS_MAC_CENTEURO=n
CONFIG_NLS_MAC_CROATIAN=n
CONFIG_NLS_MAC_CYRILLIC=n
CONFIG_NLS_MAC_GAELIC=n
CONFIG_NLS_MAC_GREEK=n
CONFIG_NLS_MAC_ICELAND=n
CONFIG_NLS_MAC_INUIT=n
CONFIG_NLS_MAC_ROMANIAN=n
CONFIG_NLS_MAC_TURKISH=n
CONFIG_SCHED_TRACER=n
CONFIG_TRACER_SNAPSHOT=n
CONFIG_UPROBE_EVENT=n
CONFIG_PROBE_EVENTS=n
CONFIG_FUNCTION_PROFILER=n
CONFIG_RING_BUFFER_BENCHMARK=n
CONFIG_ATOMIC64_SELFTEST=n
CONFIG_ASYNC_RAID6_TEST=n
CONFIG_KGDB=n
CONFIG_TEST_KSTRTOX=n
CONFIG_STRICT_DEVMEM=n
CONFIG_DEBUG_SET_MODULE_RONX=n
CONFIG_DEBUG_NX_TEST=n
CONFIG_CRYPTO_BLOWFISH_X86_64=n
CONFIG_CRYPTO_CAMELLIA_X86_64=n
CONFIG_CRYPTO_CAMELLIA_AESNI_AVX_X86_64=n
CONFIG_CRYPTO_CAMELLIA_AESNI_AVX2_X86_64=n
CONFIG_CRYPTO_CAST5_AVX_X86_64=n
CONFIG_CRYPTO_CAST6_AVX_X86_64=n
CONFIG_CRYPTO_SALSA20=n
CONFIG_CRYPTO_SALSA20_X86_64=n
CONFIG_CRYPTO_SERPENT_SSE2_X86_64=n
CONFIG_CRYPTO_SERPENT_AVX_X86_64=n
CONFIG_CRYPTO_SERPENT_AVX2_X86_64=n
CONFIG_CRYPTO_TWOFISH_X86_64=n
CONFIG_CRYPTO_TWOFISH_X86_64_3WAY=n
CONFIG_CRYPTO_TWOFISH_AVX_X86_64=n
CONFIG_CRYPTO_USER_API_HASH=n
CONFIG_CRYPTO_USER_API_SKCIPHER=n
CONFIG_CRYPTO_DEV_PADLOCK=n
#Disable unused options from rt kernel
CONFIG_WIRELESS_EXT=n
CONFIG_DLCI=n
CONFIG_IPPP_FILTER=n
CONFIG_HISAX_EURO=n
CONFIG_DE_AOC=n
CONFIG_HISAX_NO_SENDCOMPLETE=n
CONFIG_HISAX_NO_LLC=n
CONFIG_HISAX_NO_KEYPAD=n
CONFIG_HISAX_1TR6=n
CONFIG_HISAX_NI1=n
CONFIG_HISAX_16_3=n
CONFIG_HISAX_TELESPCI=n
CONFIG_HISAX_S0BOX=n
CONFIG_HISAX_FRITZPCI=n
CONFIG_HISAX_AVM_A1_PCMCIA=n
CONFIG_HISAX_ELSA=n
CONFIG_HISAX_DIEHLDIVA=n
CONFIG_HISAX_SEDLBAUER=n
CONFIG_HISAX_NETJET=n
CONFIG_HISAX_NETJET_U=n
CONFIG_HISAX_NICCY=n
CONFIG_HISAX_BKM_A4T=n
CONFIG_HISAX_SCT_QUADRO=n
CONFIG_HISAX_GAZEL=n
CONFIG_HISAX_HFC_PCI=n
CONFIG_HISAX_W6692=n
CONFIG_HISAX_HFC_SX=n
CONFIG_HISAX_ENTERNOW_PCI=n
CONFIG_HISAX_ST5481=n
CONFIG_HISAX_HFC4S8S=n
CONFIG_HISAX_FRITZ_PCIPNP=n
CONFIG_CAPI_AVM=n
CONFIG_GIGASET_CAPI=n
CONFIG_GIGASET_BASE=n
CONFIG_GIGASET_M105=n
CONFIG_GIGASET_M101=n
CONFIG_HYSDN=n
CONFIG_HYSDN_CAPI=n
CONFIG_MISDN=n
CONFIG_MISDN_DSP=n
CONFIG_MISDN_L1OIP=n
CONFIG_MISDN_HFCPCI=n
CONFIG_MISDN_HFCMULTI=n
CONFIG_MISDN_HFCUSB=n
CONFIG_MISDN_AVMFRITZ=n
CONFIG_MISDN_SPEEDFAX=n
CONFIG_MISDN_INFINEON=n
CONFIG_MISDN_W6692=n
CONFIG_MISDN_NETJET=n
CONFIG_MISDN_IPAC=n
CONFIG_MISDN_ISAR=n
CONFIG_MEDIA_CAMERA_SUPPORT=n
CONFIG_MEDIA_ANALOG_TV_SUPPORT=n
CONFIG_MEDIA_DIGITAL_TV_SUPPORT=n
CONFIG_MEDIA_RADIO_SUPPORT=n
CONFIG_MEDIA_RC_SUPPORT=n
CONFIG_VIDEO_DEV=n
CONFIG_VIDEO_V4L2=n
CONFIG_VIDEO_TUNER=n
CONFIG_VIDEOBUF_GEN=n
CONFIG_VIDEOBUF_DMA_SG=n
CONFIG_VIDEOBUF_VMALLOC=n
CONFIG_VIDEOBUF_DVB=n
CONFIG_VIDEOBUF2_CORE=n
CONFIG_VIDEOBUF2_MEMOPS=n
CONFIG_VIDEOBUF2_VMALLOC=n
CONFIG_DVB=n
CONFIG_DVB_CORE=n
CONFIG_DVB_NET=n
CONFIG_TTPCI_EEPROM=n
CONFIG_DVB_DYNAMIC_MINORS=n
CONFIG_RC_CORE=n
CONFIG_RC_MAP=n
CONFIG_RC_DECODERS=n
CONFIG_LIRC=n
CONFIG_IR_LIRC_CODEC=n
CONFIG_IR_NEC_DECODER=n
CONFIG_IR_RC5_DECODER=n
CONFIG_IR_RC6_DECODER=n
CONFIG_IR_JVC_DECODER=n
CONFIG_IR_SONY_DECODER=n
CONFIG_IR_RC5_SZ_DECODER=n
CONFIG_IR_SANYO_DECODER=n
CONFIG_IR_MCE_KBD_DECODER=n
CONFIG_RC_DEVICES=n
CONFIG_RC_ATI_REMOTE=n
CONFIG_IR_ENE=n
CONFIG_IR_IMON=n
CONFIG_IR_MCEUSB=n
CONFIG_IR_ITE_CIR=n
CONFIG_IR_FINTEK=n
CONFIG_IR_NUVOTON=n
CONFIG_IR_REDRAT3=n
CONFIG_IR_STREAMZAP=n
CONFIG_IR_WINBOND_CIR=n
CONFIG_IR_IGUANA=n
CONFIG_IR_TTUSBIR=n
CONFIG_VIDEO_EM28XX=n
CONFIG_VIDEO_EM28XX_ALSA=n
CONFIG_VIDEO_EM28XX_DVB=n
CONFIG_VIDEO_EM28XX_RC=n
CONFIG_MEDIA_PCI_SUPPORT=n
CONFIG_VIDEO_IVTV=n
CONFIG_VIDEO_FB_IVTV=n
CONFIG_VIDEO_CX18=n
CONFIG_VIDEO_CX18_ALSA=n
CONFIG_VIDEO_CX23885=n
CONFIG_MEDIA_ALTERA_CI=n
CONFIG_VIDEO_CX88=n
CONFIG_VIDEO_CX88_ALSA=n
CONFIG_VIDEO_CX88_BLACKBIRD=n
CONFIG_VIDEO_CX88_DVB=n
CONFIG_VIDEO_CX88_VP3054=n
CONFIG_VIDEO_CX88_MPEG=n
CONFIG_VIDEO_BT848=n
CONFIG_VIDEO_SAA7134=n
CONFIG_VIDEO_SAA7134_ALSA=n
CONFIG_VIDEO_SAA7134_RC=n
CONFIG_VIDEO_SAA7134_DVB=n
CONFIG_VIDEO_SAA7164=n
CONFIG_MANTIS_CORE=n
CONFIG_SMS_SDIO_DRV=n
CONFIG_MEDIA_COMMON_OPTIONS=n
CONFIG_VIDEO_CX2341X=n
CONFIG_VIDEO_BTCX=n
CONFIG_VIDEO_TVEEPROM=n
CONFIG_CYPRESS_FIRMWARE=n
CONFIG_VIDEO_SAA7146=n
CONFIG_VIDEO_SAA7146_VV=n
CONFIG_SMS_SIANO_MDTV=n
CONFIG_SMS_SIANO_RC=n
CONFIG_MEDIA_SUBDRV_AUTOSELECT=n
CONFIG_MEDIA_ATTACH=n
CONFIG_VIDEO_IR_I2C=n
CONFIG_VIDEO_TVAUDIO=n
CONFIG_VIDEO_TDA7432=n
CONFIG_VIDEO_MSP3400=n
CONFIG_VIDEO_CS5345=n
CONFIG_VIDEO_CS53L32A=n
CONFIG_VIDEO_WM8775=n
CONFIG_VIDEO_WM8739=n
CONFIG_VIDEO_VP27SMPX=n
CONFIG_VIDEO_SAA6588=n
CONFIG_VIDEO_SAA711X=n
CONFIG_VIDEO_TVP5150=n
CONFIG_VIDEO_SAA717X=n
CONFIG_VIDEO_CX25840=n
CONFIG_VIDEO_SAA7127=n
CONFIG_VIDEO_MT9V011=n
CONFIG_VIDEO_UPD64031A=n
CONFIG_VIDEO_UPD64083=n
CONFIG_VIDEO_M52790=n
CONFIG_MEDIA_TUNER=n
CONFIG_SND=n
CONFIG_IR_GPIO_CIR=n
CONFIG_BLK_DEV_NBD=m
CONFIG_AIC94XX_DEBUG=n
CONFIG_GPIO_BT8XX=n
# Disable transparent huge pages
CONFIG_TRANSPARENT_HUGEPAGE=n
CONFIG_TRANSPARENT_HUGEPAGE_ALWAYS=n
# Make performance default governor
CONFIG_CPU_FREQ_DEFAULT_GOV_ONDEMAND=n
CONFIG_CPU_FREQ_DEFAULT_GOV_PERFORMANCE=y
CONFIG_TORTURE_TEST=n
CONFIG_RCU_TORTURE_TEST=n
CONFIG_LOCK_TORTURE_TEST=n
# Disable kernel memory accounting, which is broken
CONFIG_MEMCG_KMEM=n
# Needed for opae fpga kernel module
# as it turns on hidden option REGMAP_MMIO
CONFIG_MFD_SYSCON=y

View File

@ -0,0 +1,980 @@
# Add builtin
# CONFIG_MAXSMP is not set
CONFIG_NR_CPUS=256
CONFIG_BLK_DEV_LOOP=y
CONFIG_BLK_DEV_SR=y
CONFIG_SCSI_ISCSI_ATTRS=y
CONFIG_SCSI_SAS_ATTRS=y
CONFIG_ISCSI_TCP=y
# SCSI Related Drivers
# Let's enable lots of them, pretty much anything RAID capable
CONFIG_ATA=y
CONFIG_SCSI_SAS_LIBSAS=y
CONFIG_SCSI_SAS_ATA=y
CONFIG_BLK_DEV_3W_XXXX_RAID=y
CONFIG_SCSI_3W_9XXX=y
CONFIG_SCSI_3W_SAS=y
CONFIG_SCSI_AACRAID=y
CONFIG_SCSI_DPT_I2O=y
CONFIG_SCSI_ARCMSR=y
CONFIG_SCSI_HPTIOP=y
CONFIG_SCSI_GDTH=y
CONFIG_SCSI_IPS=y
CONFIG_SCSI_STEX=y
CONFIG_SCSI_PMCRAID=y
CONFIG_SCSI_HPSA=y
CONFIG_MEGARAID_SAS=y
CONFIG_SCSI_SMARTPQI=y
# These two will only build as modules
CONFIG_SCSI_MPT2SAS=m
CONFIG_SCSI_MPT3SAS=m
CONFIG_SCSI_VIRTIO=y
CONFIG_FUSION_SAS=y
CONFIG_SCSI_AIC94XX=y
CONFIG_SCSI_MVSAS=y
CONFIG_RAID_ATTRS=y
#
CONFIG_SOFT_WATCHDOG=y
CONFIG_VIRTIO=y
CONFIG_VIRTIO_PCI=y
CONFIG_VIRTIO_MMIO=y
CONFIG_ISO9660_FS=y
CONFIG_FAT_FS=y
CONFIG_VFAT_FS=y
CONFIG_NLS_ISO8859_1=y
# CONFIG_GENERIC_CPU is not set
CONFIG_MCORE2=y
CONFIG_SIGEXIT=y
CONFIG_SCHEDSTATS=y
# Enable runtime Huge TLB support
CONFIG_DMA_CMA=y
CONFIG_CMA_SIZE_MBYTES=16
CONFIG_CMA_SIZE_SEL_MBYTES=y
CONFIG_CMA_ALIGNMENT=8
CONFIG_CMA_AREAS=7
# Turn on Intel IOMMU
CONFIG_INTEL_IOMMU_DEFAULT_ON=y
# Turn off network drivers that we want
# to build out-of-tree
# CONFIG_E1000E is not set
# CONFIG_E1000E_HWTS is not set
# CONFIG_I40E is not set
# CONFIG_I40EVF is not set
# CONFIG_IXGB is not set
# CONFIG_IXGBE is not set
# CONFIG_IXGBEVF is not set
# CONFIG_MLX4_EN is not set
# CONFIG_MLX4_CORE is not set
# CONFIG_MLX5_EN is not set
# CONFIG_MLX5_CORE is not set
# Turn off TPM drivers that we want
# to build out-of-tree. This will
# disable the TPM HW-RandomNUmberGenerator(RNG)
# and TrustedKeys modules as well, since
# they require the in-kernel TPM driver.
# Both these modules will also need to be
# built out-of-tree when needed.
# CONFIG_TCG_TPM is not set
# CONFIG_TCG_TIS is not set
# CONFIG_HW_RANDOM_TPM is not set
# CONFIG_TRUSTED_KEYS is not set
# CONFIG_TCG_TIS_I2C_ATMEL is not set
# CONFIG_TCG_TIS_I2C_INFINEON is not set
# CONFIG_TCG_TIS_I2C_NUVOTON is not set
# CONFIG_TCG_NSC is not set
# CONFIG_TCG_ATMEL is not set
# CONFIG_TCG_INFINEON is not set
# CONFIG_TCG_CRB is not set
# CONFIG_TCG_TIS_ST33ZP24 is not set
# CONFIG_TCG_TIS_ST33ZP24_I2C is not set
# Also disable TPM Integrity Measurement Architecture
# (IMA), as this will be built out of tree but ensure
# that all their dependencies (that comes from the base kernel)
# that are marked as "select" within the Integrity / IMA
# Kconfigs are still enabled
# CONFIG_INTEGRITY is not set
# CONFIG_IMA is not set
# CONFIG_EVM is not set
CONFIG_SIGNATURE=y
CONFIG_KEYS=y
CONFIG_ASYMMETRIC_KEY_TYPE=y
CONFIG_ASYMMETRIC_PUBLIC_KEY_SUBTYPE=y
CONFIG_PUBLIC_KEY_ALGO_RSA=y
CONFIG_X509_CERTIFICATE_PARSER=y
CONFIG_SECURITYFS=y
CONFIG_CRYPTO=y
CONFIG_CRYPTO_HMAC=y
CONFIG_CRYPTO_MD5=y
CONFIG_CRYPTO_SHA1=y
#Enable Intel RDT
CONFIG_KERNFS=y
CONFIG_INTEL_RDT_A=y
#Enable PTP clock support
CONFIG_PPS=y
CONFIG_PTP_1588_CLOCK=y
CONFIG_PTP_1588_CLOCK_PCH=y
CONFIG_PTP_1588_CLOCK_KVM=y
CONFIG_DP83640_PHY=y
# Remove unneeded stuff (including stuff exposed
# by saying y to new options above.
# CONFIG_VIRTIO_MMIO_CMDLINE_DEVICES is not set
# CONFIG_PANIC_ON_OOPS is not set
# CONFIG_SOUND is not set
# CONFIG_FIREWIRE is not set
# CONFIG_KPROBES is not set
# CONFIG_XEN is not set
# CONFIG_BT is not set
# CONFIG_USB_USBNET is not set
# CONFIG_RTL8187 is not set
# CONFIG_MWL8K is not set
# CONFIG_CFG80211 is not set
# CONFIG_WAN is not set
# CONFIG_ISDN is not set
# CONFIG_INPUT_TOUCHSCREEN is not set
# CONFIG_INPUT_JOYDEV is not set
# CONFIG_INPUT_JOYSTICK is not set
# CONFIG_INPUT_FF_MEMLESS is not set
# CONFIG_GAMEPORT is not set
# CONFIG_THUNDERBOLT is not set
# CONFIG_APPLE_PROPERTIES is not set
# CONFIG_SSB is not set
# CONFIG_BCMA is not set
# CONFIG_MEDIA_SUPPORT is not set
# CONFIG_ACPI_PROCESSOR_AGGREGATOR is not set
# CONFIG_ACPI_EXTLOG is not set
# CONFIG_NET_FOU is not set
# CONFIG_NET_FOU_IP_TUNNELS is not set
# CONFIG_GENEVE is not set
# CONFIG_IPV6_VTI is not set
# CONFIG_NETFILTER_XT_TARGET_TPROXY is not set
# CONFIG_NETFILTER_XT_MATCH_CGROUP is not set
# CONFIG_NETFILTER_XT_MATCH_SOCKET is not set
# CONFIG_NET_SCH_FQ is not set
# CONFIG_NET_CLS_BPF is not set
# CONFIG_BLK_DEV_NULL_BLK is not set
# CONFIG_GENWQE is not set
# CONFIG_CXL_BASE is not set
# CONFIG_DM_ERA is not set
# CONFIG_DM_RAID is not set
# CONFIG_DM_SWITCH is not set
# CONFIG_NLMON is not set
# CONFIG_FM10K is not set
# CONFIG_CRASH is not set
# CONFIG_IPMI_SSIF is not set
# CONFIG_POWERCAP is not set
# CONFIG_DRM_BOCHS is not set
# CONFIG_HID_RMI is not set
# CONFIG_NET_DMA_RH_KABI is not set
# CONFIG_HP_WIRELESS is not set
# CONFIG_NFSD_V4_SECURITY_LABEL is not set
# CONFIG_DEBUG_SHIRQ is not set
# CONFIG_PERSISTENT_KEYRINGS is not set
# CONFIG_BIG_KEYS is not set
# CONFIG_SECURITY_SECURELEVEL is not set
# CONFIG_CRYPTO_SHA1_MB is not set
# CONFIG_CRYPTO_DEV_QAT is not set
# CONFIG_CRYPTO_DEV_QAT_DH895xCCVF is not set
# CONFIG_CRYPTO_DEV_QAT_DH895xCC is not set
# CONFIG_CRYPTO_DEV_QAT_C3XXX is not set
# CONFIG_CRYPTO_DEV_QAT_C62X is not set
# CONFIG_CRYPTO_DEV_QAT_C3XXXVF is not set
# CONFIG_CRYPTO_DEV_QAT_C62XVF is not set
# CONFIG_BPF_JIT is not set
# CONFIG_PARPORT is not set
# CONFIG_CDROM_PKTCDVD is not set
# CONFIG_SENSORS_LIS3LV02D is not set
# CONFIG_SGI_IOC4 is not set
# CONFIG_TIFM_CORE is not set
# CONFIG_ENCLOSURE_SERVICES is not set
# CONFIG_APDS9802ALS is not set
# CONFIG_ISL29003 is not set
# CONFIG_ISL29020 is not set
# CONFIG_SENSORS_TSL2550 is not set
# CONFIG_SENSORS_BH1770 is not set
# CONFIG_SENSORS_APDS990X is not set
# CONFIG_PCH_PHUB is not set
# CONFIG_EEPROM_AT24 is not set
# CONFIG_EEPROM_MAX6875 is not set
# CONFIG_EEPROM_93CX6 is not set
# CONFIG_CB710_CORE is not set
# CONFIG_SENSORS_LIS3_I2C is not set
# CONFIG_ALTERA_STAPL is not set
# CONFIG_VMWARE_VMCI is not set
# CONFIG_CHR_DEV_ST is not set
# CONFIG_CHR_DEV_OSST is not set
# CONFIG_CHR_DEV_SG is not set
# CONFIG_CHR_DEV_SCH is not set
# CONFIG_SCSI_CONSTANTS is not set
# CONFIG_SCSI_LOGGING is not set
# CONFIG_SCSI_CXGB3_ISCSI is not set
# CONFIG_SCSI_CXGB4_ISCSI is not set
# CONFIG_SCSI_AIC79XX is not set
# CONFIG_SCSI_MVUMI is not set
# CONFIG_SCSI_MPT2SAS_LOGGING is not set
# CONFIG_SCSI_MPT3SAS_LOGGING is not set
# CONFIG_SCSI_UFSHCD is not set
# CONFIG_VMWARE_PVSCSI is not set
# CONFIG_FCOE is not set
# CONFIG_FCOE_FNIC is not set
# CONFIG_SCSI_INITIO is not set
# CONFIG_SCSI_PM8001 is not set
# CONFIG_SCSI_SRP is not set
# CONFIG_SATA_ACARD_AHCI is not set
# CONFIG_SATA_SIL24 is not set
# CONFIG_PDC_ADMA is not set
# CONFIG_SATA_QSTOR is not set
# CONFIG_SATA_SX4 is not set
# CONFIG_SATA_MV is not set
# CONFIG_SATA_NV is not set
# CONFIG_SATA_PROMISE is not set
# CONFIG_SATA_SIL is not set
# CONFIG_SATA_SIS is not set
# CONFIG_SATA_SVW is not set
# CONFIG_SATA_ULI is not set
# CONFIG_SATA_VIA is not set
# CONFIG_SATA_VITESSE is not set
# CONFIG_PATA_ALI is not set
# CONFIG_PATA_AMD is not set
# CONFIG_PATA_ARASAN_CF is not set
# CONFIG_PATA_ARTOP is not set
# CONFIG_PATA_ATIIXP is not set
# CONFIG_PATA_ATP867X is not set
# CONFIG_PATA_CMD64X is not set
# CONFIG_PATA_CS5536 is not set
# CONFIG_PATA_HPT366 is not set
# CONFIG_PATA_HPT37X is not set
# CONFIG_PATA_HPT3X2N is not set
# CONFIG_PATA_HPT3X3 is not set
# CONFIG_PATA_IT8213 is not set
# CONFIG_PATA_IT821X is not set
# CONFIG_PATA_JMICRON is not set
# CONFIG_PATA_MARVELL is not set
# CONFIG_PATA_NETCELL is not set
# CONFIG_PATA_NINJA32 is not set
# CONFIG_PATA_OLDPIIX is not set
# CONFIG_PATA_PDC2027X is not set
# CONFIG_PATA_PDC_OLD is not set
# CONFIG_PATA_RDC is not set
# CONFIG_PATA_SCH is not set
# CONFIG_PATA_SERVERWORKS is not set
# CONFIG_PATA_SIL680 is not set
# CONFIG_PATA_SIS is not set
# CONFIG_PATA_TOSHIBA is not set
# CONFIG_PATA_VIA is not set
# CONFIG_DM_DEBUG is not set
# CONFIG_MACINTOSH_DRIVERS is not set
# CONFIG_NET_FC is not set
# CONFIG_NET_TEAM is not set
# CONFIG_ATL2 is not set
# CONFIG_ATL1 is not set
# CONFIG_ATL1E is not set
# CONFIG_ATL1C is not set
# CONFIG_ALX is not set
# CONFIG_ARM_AT91_ETHER is not set
# CONFIG_MACB is not set
# CONFIG_B44 is not set
# CONFIG_BNA is not set
# CONFIG_NET_CALXEDA_XGMAC is not set
# CONFIG_CHELSIO_T3 is not set
# CONFIG_CHELSIO_T4 is not set
# CONFIG_CHELSIO_T4VF is not set
# CONFIG_NET_TULIP is not set
# CONFIG_IP1000 is not set
# CONFIG_JME is not set
# CONFIG_MVMDIO is not set
# CONFIG_SKGE is not set
# CONFIG_SKY2 is not set
# CONFIG_MYRI10GE is not set
# CONFIG_PCH_GBE is not set
# CONFIG_ETHOC is not set
# CONFIG_QLCNIC is not set
# CONFIG_QLGE is not set
# CONFIG_NETXEN_NIC is not set
# CONFIG_SFC is not set
# CONFIG_EPIC100 is not set
# CONFIG_SMSC9420 is not set
# CONFIG_AT803X_PHY is not set
# CONFIG_DAVICOM_PHY is not set
# CONFIG_QSEMI_PHY is not set
# CONFIG_LXT_PHY is not set
# CONFIG_CICADA_PHY is not set
# CONFIG_VITESSE_PHY is not set
# CONFIG_SMSC_PHY is not set
# CONFIG_BCM87XX_PHY is not set
# CONFIG_ICPLUS_PHY is not set
# CONFIG_REALTEK_PHY is not set
# CONFIG_NATIONAL_PHY is not set
# CONFIG_STE10XP is not set
# CONFIG_LSI_ET1011C_PHY is not set
# CONFIG_MICREL_PHY is not set
# CONFIG_MDIO_BITBANG is not set
# CONFIG_RT_GROUP_SCHED is not set
# CONFIG_OPROFILE is not set
# CONFIG_SYSTEM_BLACKLIST_KEYRING is not set
# CONFIG_OSF_PARTITION is not set
# CONFIG_AMIGA_PARTITION is not set
# CONFIG_MAC_PARTITION is not set
# CONFIG_BSD_DISKLABEL is not set
# CONFIG_MINIX_SUBPARTITION is not set
# CONFIG_SOLARIS_X86_PARTITION is not set
# CONFIG_UNIXWARE_DISKLABEL is not set
# CONFIG_SGI_PARTITION is not set
# CONFIG_SUN_PARTITION is not set
# CONFIG_KARMA_PARTITION is not set
# CONFIG_X86_UV is not set
# CONFIG_I8K is not set
# CONFIG_MICROCODE_AMD is not set
# CONFIG_MICROCODE_AMD_EARLY is not set
# CONFIG_MOVABLE_NODE is not set
# CONFIG_MEMORY_HOTPLUG is not set
# CONFIG_BOOTPARAM_HOTPLUG_CPU0 is not set
# CONFIG_X86_POWERNOW_K8 is not set
# CONFIG_X86_AMD_FREQ_SENSITIVITY is not set
# CONFIG_X86_P4_CLOCKMOD is not set
# CONFIG_PCIE_ECRC is not set
# CONFIG_PCIEAER_INJECT is not set
# CONFIG_PCCARD is not set
# CONFIG_HOTPLUG_PCI_ACPI_IBM is not set
# CONFIG_HOTPLUG_PCI_SHPC is not set
# CONFIG_XFRM_STATISTICS is not set
# CONFIG_IP_FIB_TRIE_STATS is not set
# CONFIG_PPP_MPPE is not set
# CONFIG_USB_CATC is not set
# CONFIG_USB_KAWETH is not set
# CONFIG_USB_PEGASUS is not set
# CONFIG_USB_RTL8150 is not set
# CONFIG_USB_RTL8152 is not set
# CONFIG_USB_HSO is not set
# CONFIG_USB_IPHETH is not set
# CONFIG_INPUT_POLLDEV is not set
# CONFIG_INPUT_SPARSEKMAP is not set
# CONFIG_MOUSE_PS2_ELANTECH is not set
# CONFIG_MOUSE_PS2_SENTELIC is not set
# CONFIG_MOUSE_APPLETOUCH is not set
# CONFIG_MOUSE_BCM5974 is not set
# CONFIG_MOUSE_CYAPA is not set
# CONFIG_MOUSE_VSXXXAA is not set
# CONFIG_MOUSE_SYNAPTICS_I2C is not set
# CONFIG_MOUSE_SYNAPTICS_USB is not set
# CONFIG_INPUT_TABLET is not set
# CONFIG_INPUT_PCSPKR is not set
# CONFIG_INPUT_APANEL is not set
# CONFIG_INPUT_ATLAS_BTNS is not set
# CONFIG_INPUT_ATI_REMOTE2 is not set
# CONFIG_INPUT_KEYSPAN_REMOTE is not set
# CONFIG_INPUT_POWERMATE is not set
# CONFIG_INPUT_YEALINK is not set
# CONFIG_INPUT_CM109 is not set
# CONFIG_INPUT_UINPUT is not set
# CONFIG_SERIO_ALTERA_PS2 is not set
# CONFIG_SERIO_ARC_PS2 is not set
# CONFIG_NOZOMI is not set
# CONFIG_N_GSM is not set
# CONFIG_SERIAL_JSM is not set
# CONFIG_SERIAL_ARC is not set
# CONFIG_HANGCHECK_TIMER is not set
# CONFIG_TELCLOCK is not set
# CONFIG_I2C_AMD756 is not set
# CONFIG_I2C_AMD8111 is not set
# CONFIG_I2C_PIIX4 is not set
# CONFIG_I2C_NFORCE2 is not set
# CONFIG_I2C_SIS96X is not set
# CONFIG_I2C_VIA is not set
# CONFIG_I2C_VIAPRO is not set
# CONFIG_I2C_PCA_PLATFORM is not set
# CONFIG_I2C_SIMTEC is not set
# CONFIG_I2C_DIOLAN_U2C is not set
# CONFIG_I2C_PARPORT_LIGHT is not set
# CONFIG_PPS_CLIENT_LDISC is not set
# CONFIG_PPS_CLIENT_GPIO is not set
# CONFIG_CHARGER_SMB347 is not set
# CONFIG_SENSORS_ABITUGURU is not set
# CONFIG_SENSORS_ABITUGURU3 is not set
# CONFIG_SENSORS_AD7414 is not set
# CONFIG_SENSORS_AD7418 is not set
# CONFIG_SENSORS_ADM1021 is not set
# CONFIG_SENSORS_ADM1025 is not set
# CONFIG_SENSORS_ADM1026 is not set
# CONFIG_SENSORS_ADM1029 is not set
# CONFIG_SENSORS_ADM1031 is not set
# CONFIG_SENSORS_ADM9240 is not set
# CONFIG_SENSORS_ADT7410 is not set
# CONFIG_SENSORS_ADT7411 is not set
# CONFIG_SENSORS_ADT7462 is not set
# CONFIG_SENSORS_ADT7470 is not set
# CONFIG_SENSORS_ADT7475 is not set
# CONFIG_SENSORS_ASC7621 is not set
# CONFIG_SENSORS_K8TEMP is not set
# CONFIG_SENSORS_K10TEMP is not set
# CONFIG_SENSORS_FAM15H_POWER is not set
# CONFIG_SENSORS_ASB100 is not set
# CONFIG_SENSORS_ATXP1 is not set
# CONFIG_SENSORS_DS620 is not set
# CONFIG_SENSORS_DS1621 is not set
# CONFIG_SENSORS_I5K_AMB is not set
# CONFIG_SENSORS_F71805F is not set
# CONFIG_SENSORS_F71882FG is not set
# CONFIG_SENSORS_F75375S is not set
# CONFIG_SENSORS_FSCHMD is not set
# CONFIG_SENSORS_G760A is not set
# CONFIG_SENSORS_GL518SM is not set
# CONFIG_SENSORS_GL520SM is not set
# CONFIG_SENSORS_IBMAEM is not set
# CONFIG_SENSORS_IBMPEX is not set
# CONFIG_SENSORS_IT87 is not set
# CONFIG_SENSORS_LINEAGE is not set
# CONFIG_SENSORS_LM63 is not set
# CONFIG_SENSORS_LM73 is not set
# CONFIG_SENSORS_LM75 is not set
# CONFIG_SENSORS_LM77 is not set
# CONFIG_SENSORS_LM78 is not set
# CONFIG_SENSORS_LM80 is not set
# CONFIG_SENSORS_LM83 is not set
# CONFIG_SENSORS_LM85 is not set
# CONFIG_SENSORS_LM87 is not set
# CONFIG_SENSORS_LM90 is not set
# CONFIG_SENSORS_LM92 is not set
# CONFIG_SENSORS_LM93 is not set
# CONFIG_SENSORS_LTC4151 is not set
# CONFIG_SENSORS_LTC4215 is not set
# CONFIG_SENSORS_LTC4245 is not set
# CONFIG_SENSORS_LTC4261 is not set
# CONFIG_SENSORS_LM95234 is not set
# CONFIG_SENSORS_LM95241 is not set
# CONFIG_SENSORS_LM95245 is not set
# CONFIG_SENSORS_MAX16065 is not set
# CONFIG_SENSORS_MAX1619 is not set
# CONFIG_SENSORS_MAX1668 is not set
# CONFIG_SENSORS_MAX197 is not set
# CONFIG_SENSORS_MAX6639 is not set
# CONFIG_SENSORS_MAX6642 is not set
# CONFIG_SENSORS_MAX6650 is not set
# CONFIG_SENSORS_MAX6697 is not set
# CONFIG_SENSORS_MCP3021 is not set
# CONFIG_SENSORS_NCT6775 is not set
# CONFIG_SENSORS_NTC_THERMISTOR is not set
# CONFIG_SENSORS_PC87360 is not set
# CONFIG_SENSORS_PC87427 is not set
# CONFIG_SENSORS_PCF8591 is not set
# CONFIG_SENSORS_PMBUS is not set
# CONFIG_SENSORS_ADM1275 is not set
# CONFIG_SENSORS_LM25066 is not set
# CONFIG_SENSORS_LTC2978 is not set
# CONFIG_SENSORS_MAX16064 is not set
# CONFIG_SENSORS_MAX34440 is not set
# CONFIG_SENSORS_MAX8688 is not set
# CONFIG_SENSORS_UCD9000 is not set
# CONFIG_SENSORS_UCD9200 is not set
# CONFIG_SENSORS_ZL6100 is not set
# CONFIG_SENSORS_SHT21 is not set
# CONFIG_SENSORS_SIS5595 is not set
# CONFIG_SENSORS_DME1737 is not set
# CONFIG_SENSORS_EMC1403 is not set
# CONFIG_SENSORS_EMC6W201 is not set
# CONFIG_SENSORS_SMSC47M1 is not set
# CONFIG_SENSORS_SMSC47M192 is not set
# CONFIG_SENSORS_SMSC47B397 is not set
# CONFIG_SENSORS_SCH56XX_COMMON is not set
# CONFIG_SENSORS_SCH5627 is not set
# CONFIG_SENSORS_SCH5636 is not set
# CONFIG_SENSORS_ADS1015 is not set
# CONFIG_SENSORS_ADS7828 is not set
# CONFIG_SENSORS_AMC6821 is not set
# CONFIG_SENSORS_INA209 is not set
# CONFIG_SENSORS_INA2XX is not set
# CONFIG_SENSORS_THMC50 is not set
# CONFIG_SENSORS_TMP102 is not set
# CONFIG_SENSORS_TMP401 is not set
# CONFIG_SENSORS_TMP421 is not set
# CONFIG_SENSORS_VIA_CPUTEMP is not set
# CONFIG_SENSORS_VIA686A is not set
# CONFIG_SENSORS_VT1211 is not set
# CONFIG_SENSORS_VT8231 is not set
# CONFIG_SENSORS_W83781D is not set
# CONFIG_SENSORS_W83791D is not set
# CONFIG_SENSORS_W83792D is not set
# CONFIG_SENSORS_W83793 is not set
# CONFIG_SENSORS_W83795 is not set
# CONFIG_SENSORS_W83L785TS is not set
# CONFIG_SENSORS_W83L786NG is not set
# CONFIG_SENSORS_W83627HF is not set
# CONFIG_SENSORS_W83627EHF is not set
# CONFIG_SENSORS_APPLESMC is not set
# CONFIG_SENSORS_ATK0110 is not set
# CONFIG_ALIM1535_WDT is not set
# CONFIG_ALIM7101_WDT is not set
# CONFIG_F71808E_WDT is not set
# CONFIG_SP5100_TCO is not set
# CONFIG_SBC_FITPC2_WATCHDOG is not set
# CONFIG_IB700_WDT is not set
# CONFIG_IBMASR is not set
# CONFIG_IT8712F_WDT is not set
# CONFIG_IT87_WDT is not set
# CONFIG_NV_TCO is not set
# CONFIG_SMSC_SCH311X_WDT is not set
# CONFIG_VIA_WDT is not set
# CONFIG_W83627HF_WDT is not set
# CONFIG_W83697HF_WDT is not set
# CONFIG_W83697UG_WDT is not set
# CONFIG_W83877F_WDT is not set
# CONFIG_W83977F_WDT is not set
# CONFIG_MACHZ_WDT is not set
# CONFIG_PCIPCWATCHDOG is not set
# CONFIG_WDTPCI is not set
# CONFIG_USBPCWATCHDOG is not set
# CONFIG_MFD_VIPERBOARD is not set
# CONFIG_MFD_SM501 is not set
# CONFIG_MFD_VX855 is not set
# CONFIG_AGP_AMD64 is not set
# CONFIG_AGP_SIS is not set
# CONFIG_AGP_VIA is not set
# CONFIG_VGA_SWITCHEROO is not set
# CONFIG_DRM_LOAD_EDID_FIRMWARE is not set
# CONFIG_DRM_I2C_CH7006 is not set
# CONFIG_DRM_I2C_SIL164 is not set
# CONFIG_DRM_I2C_NXP_TDA998X is not set
# CONFIG_DRM_RADEON is not set
# CONFIG_DRM_NOUVEAU is not set
# CONFIG_DRM_VMWGFX is not set
# CONFIG_DRM_GMA500 is not set
# CONFIG_DRM_GMA600 is not set
# CONFIG_DRM_GMA3600 is not set
# CONFIG_DRM_UDL is not set
# CONFIG_DRM_AST is not set
# CONFIG_DRM_MGAG200 is not set
# CONFIG_DRM_CIRRUS_QEMU is not set
# CONFIG_DRM_QXL is not set
# CONFIG_FB_BACKLIGHT is not set
# CONFIG_LCD_PLATFORM is not set
# CONFIG_BACKLIGHT_APPLE is not set
# CONFIG_BACKLIGHT_LP855X is not set
# CONFIG_VGACON_SOFT_SCROLLBACK is not set
# CONFIG_FRAMEBUFFER_CONSOLE_ROTATION is not set
# CONFIG_LOGO is not set
# CONFIG_HID_BATTERY_STRENGTH is not set
# CONFIG_HIDRAW is not set
# CONFIG_UHID is not set
# CONFIG_HID_ACRUX is not set
# CONFIG_HID_BETOP_FF is not set
# CONFIG_HID_APPLEIR is not set
# CONFIG_HID_AUREAL is not set
# CONFIG_HID_DRAGONRISE is not set
# CONFIG_HID_ELECOM is not set
# CONFIG_HID_HOLTEK is not set
# CONFIG_HID_KEYTOUCH is not set
# CONFIG_HID_KYE is not set
# CONFIG_HID_UCLOGIC is not set
# CONFIG_HID_WALTOP is not set
# CONFIG_HID_GYRATION is not set
# CONFIG_HID_ICADE is not set
# CONFIG_HID_TWINHAN is not set
# CONFIG_HID_LCPOWER is not set
# CONFIG_HID_LENOVO_TPKBD is not set
# CONFIG_HID_MAGICMOUSE is not set
# CONFIG_HID_NTRIG is not set
# CONFIG_HID_ORTEK is not set
# CONFIG_HID_PANTHERLORD is not set
# CONFIG_HID_PETALYNX is not set
# CONFIG_HID_PICOLCD is not set
# CONFIG_HID_PRIMAX is not set
# CONFIG_HID_PS3REMOTE is not set
# CONFIG_HID_ROCCAT is not set
# CONFIG_HID_SAITEK is not set
# CONFIG_HID_SAMSUNG is not set
# CONFIG_HID_SONY is not set
# CONFIG_HID_SPEEDLINK is not set
# CONFIG_HID_STEELSERIES is not set
# CONFIG_HID_SUNPLUS is not set
# CONFIG_HID_GREENASIA is not set
# CONFIG_HID_SMARTJOYPLUS is not set
# CONFIG_HID_TIVO is not set
# CONFIG_HID_TOPSEED is not set
# CONFIG_HID_THINGM is not set
# CONFIG_HID_THRUSTMASTER is not set
# CONFIG_HID_WACOM is not set
# CONFIG_HID_WIIMOTE is not set
# CONFIG_HID_ZEROPLUS is not set
# CONFIG_HID_ZYDACRON is not set
# CONFIG_HID_PID is not set
# CONFIG_USB_HIDDEV is not set
# CONFIG_USB_ANNOUNCE_NEW_DEVICES is not set
# CONFIG_USB_MON is not set
# CONFIG_USB_WUSB_CBAF is not set
# CONFIG_USB_OHCI_HCD is not set
# CONFIG_USB_ACM is not set
# CONFIG_USB_PRINTER is not set
# CONFIG_USB_WDM is not set
# CONFIG_USB_TMC is not set
# CONFIG_USB_STORAGE_REALTEK is not set
# CONFIG_USB_STORAGE_DATAFAB is not set
# CONFIG_USB_STORAGE_FREECOM is not set
# CONFIG_USB_STORAGE_ISD200 is not set
# CONFIG_USB_STORAGE_USBAT is not set
# CONFIG_USB_STORAGE_SDDR09 is not set
# CONFIG_USB_STORAGE_SDDR55 is not set
# CONFIG_USB_STORAGE_JUMPSHOT is not set
# CONFIG_USB_STORAGE_ALAUDA is not set
# CONFIG_USB_STORAGE_ONETOUCH is not set
# CONFIG_USB_STORAGE_KARMA is not set
# CONFIG_USB_STORAGE_CYPRESS_ATACB is not set
# CONFIG_USB_STORAGE_ENE_UB6250 is not set
# CONFIG_USB_MDC800 is not set
# CONFIG_USB_MICROTEK is not set
# CONFIG_USB_SERIAL_AIRCABLE is not set
# CONFIG_USB_SERIAL_ARK3116 is not set
# CONFIG_USB_SERIAL_BELKIN is not set
# CONFIG_USB_SERIAL_WHITEHEAT is not set
# CONFIG_USB_SERIAL_DIGI_ACCELEPORT is not set
# CONFIG_USB_SERIAL_CYPRESS_M8 is not set
# CONFIG_USB_SERIAL_EMPEG is not set
# CONFIG_USB_SERIAL_VISOR is not set
# CONFIG_USB_SERIAL_IPAQ is not set
# CONFIG_USB_SERIAL_IR is not set
# CONFIG_USB_SERIAL_EDGEPORT is not set
# CONFIG_USB_SERIAL_EDGEPORT_TI is not set
# CONFIG_USB_SERIAL_GARMIN is not set
# CONFIG_USB_SERIAL_IPW is not set
# CONFIG_USB_SERIAL_IUU is not set
# CONFIG_USB_SERIAL_KEYSPAN_PDA is not set
# CONFIG_USB_SERIAL_KEYSPAN is not set
# CONFIG_USB_SERIAL_KLSI is not set
# CONFIG_USB_SERIAL_KOBIL_SCT is not set
# CONFIG_USB_SERIAL_MCT_U232 is not set
# CONFIG_USB_SERIAL_MOS7720 is not set
# CONFIG_USB_SERIAL_MOS7840 is not set
# CONFIG_USB_SERIAL_NAVMAN is not set
# CONFIG_USB_SERIAL_OTI6858 is not set
# CONFIG_USB_SERIAL_QCAUX is not set
# CONFIG_USB_SERIAL_QUALCOMM is not set
# CONFIG_USB_SERIAL_SPCP8X5 is not set
# CONFIG_USB_SERIAL_SAFE is not set
# CONFIG_USB_SERIAL_SIERRAWIRELESS is not set
# CONFIG_USB_SERIAL_SYMBOL is not set
# CONFIG_USB_SERIAL_TI is not set
# CONFIG_USB_SERIAL_CYBERJACK is not set
# CONFIG_USB_SERIAL_XIRCOM is not set
# CONFIG_USB_SERIAL_OPTION is not set
# CONFIG_USB_SERIAL_OMNINET is not set
# CONFIG_USB_SERIAL_OPTICON is not set
# CONFIG_USB_SERIAL_XSENS_MT is not set
# CONFIG_USB_SERIAL_SSU100 is not set
# CONFIG_USB_SERIAL_QT2 is not set
# CONFIG_USB_SERIAL_DEBUG is not set
# CONFIG_USB_EMI62 is not set
# CONFIG_USB_EMI26 is not set
# CONFIG_USB_ADUTUX is not set
# CONFIG_USB_SEVSEG is not set
# CONFIG_USB_LEGOTOWER is not set
# CONFIG_USB_LCD is not set
# CONFIG_USB_LED is not set
# CONFIG_USB_IDMOUSE is not set
# CONFIG_USB_FTDI_ELAN is not set
# CONFIG_USB_APPLEDISPLAY is not set
# CONFIG_USB_SISUSBVGA is not set
# CONFIG_USB_LD is not set
# CONFIG_USB_IOWARRIOR is not set
# CONFIG_USB_ISIGHTFW is not set
# CONFIG_USB_EZUSB_FX2 is not set
# CONFIG_USB_HSIC_USB3503 is not set
# CONFIG_USB_ATM is not set
# CONFIG_UWB is not set
# CONFIG_MMC_RICOH_MMC is not set
# CONFIG_MMC_TIFM_SD is not set
# CONFIG_MMC_CB710 is not set
# CONFIG_MMC_VIA_SDMMC is not set
# CONFIG_MMC_VUB300 is not set
# CONFIG_MMC_USHC is not set
# CONFIG_MEMSTICK is not set
# CONFIG_LEDS_LM3530 is not set
# CONFIG_LEDS_LP3944 is not set
# CONFIG_LEDS_LP5521 is not set
# CONFIG_LEDS_LP5523 is not set
# CONFIG_LEDS_LP5562 is not set
# CONFIG_LEDS_CLEVO_MAIL is not set
# CONFIG_LEDS_INTEL_SS4200 is not set
# CONFIG_LEDS_BLINKM is not set
# CONFIG_LEDS_TRIGGER_TIMER is not set
# CONFIG_LEDS_TRIGGER_ONESHOT is not set
# CONFIG_LEDS_TRIGGER_HEARTBEAT is not set
# CONFIG_LEDS_TRIGGER_BACKLIGHT is not set
# CONFIG_LEDS_TRIGGER_TRANSIENT is not set
# CONFIG_LEDS_TRIGGER_CAMERA is not set
# CONFIG_INFINIBAND is not set
# CONFIG_EDAC is not set
# CONFIG_UIO_CIF is not set
# CONFIG_UIO_AEC is not set
# CONFIG_UIO_SERCOS3 is not set
# CONFIG_STAGING is not set
# CONFIG_ACERHDF is not set
# CONFIG_ACER_WMI is not set
# CONFIG_DELL_WMI is not set
# CONFIG_DELL_WMI_AIO is not set
# CONFIG_HP_WMI is not set
# CONFIG_ASUS_LAPTOP is not set
# CONFIG_ASUS_WMI is not set
# CONFIG_MSI_WMI is not set
# CONFIG_INTEL_HID_EVENT is not set
# CONFIG_INTEL_VBTN is not set
# CONFIG_CHROMEOS_LAPTOP is not set
# CONFIG_FUJITSU_LAPTOP is not set
# CONFIG_FUJITSU_TABLET is not set
# CONFIG_AMILO_RFKILL is not set
# CONFIG_HP_ACCEL is not set
# CONFIG_MSI_LAPTOP is not set
# CONFIG_PANASONIC_LAPTOP is not set
# CONFIG_COMPAL_LAPTOP is not set
# CONFIG_SONY_LAPTOP is not set
# CONFIG_IDEAPAD_LAPTOP is not set
# CONFIG_THINKPAD_ACPI is not set
# CONFIG_SENSORS_HDAPS is not set
# CONFIG_EEEPC_LAPTOP is not set
# CONFIG_ACPI_WMI is not set
# CONFIG_TOPSTAR_LAPTOP is not set
# CONFIG_TOSHIBA_BT_RFKILL is not set
# CONFIG_ACPI_CMPC is not set
# CONFIG_SAMSUNG_LAPTOP is not set
# CONFIG_INTEL_OAKTRAIL is not set
# CONFIG_SAMSUNG_Q10 is not set
# CONFIG_APPLE_GMUX is not set
# CONFIG_PVPANIC is not set
# CONFIG_EDD is not set
# CONFIG_DELL_RBU is not set
# CONFIG_DCDBAS is not set
# CONFIG_JBD_DEBUG is not set
# CONFIG_FANOTIFY is not set
# CONFIG_JOLIET is not set
# CONFIG_UDF_FS is not set
# CONFIG_CRAMFS is not set
# CONFIG_SQUASHFS is not set
# CONFIG_EFIVAR_FS is not set
# CONFIG_SUNRPC_DEBUG is not set
# CONFIG_NLS_MAC_ROMAN is not set
# CONFIG_NLS_MAC_CELTIC is not set
# CONFIG_NLS_MAC_CENTEURO is not set
# CONFIG_NLS_MAC_CROATIAN is not set
# CONFIG_NLS_MAC_CYRILLIC is not set
# CONFIG_NLS_MAC_GAELIC is not set
# CONFIG_NLS_MAC_GREEK is not set
# CONFIG_NLS_MAC_ICELAND is not set
# CONFIG_NLS_MAC_INUIT is not set
# CONFIG_NLS_MAC_ROMANIAN is not set
# CONFIG_NLS_MAC_TURKISH is not set
# CONFIG_SCHED_TRACER is not set
# CONFIG_TRACER_SNAPSHOT is not set
# CONFIG_PROBE_EVENTS is not set
# CONFIG_KPROBE_EVENTS is not set
# CONFIG_UPROBE_EVENTS is not set
# CONFIG_FUNCTION_PROFILER is not set
# CONFIG_RING_BUFFER_BENCHMARK is not set
# CONFIG_ATOMIC64_SELFTEST is not set
# CONFIG_ASYNC_RAID6_TEST is not set
# CONFIG_KGDB is not set
# CONFIG_TEST_KSTRTOX is not set
# CONFIG_STRICT_DEVMEM is not set
# CONFIG_DEBUG_SET_MODULE_RONX is not set
# CONFIG_DEBUG_NX_TEST is not set
# CONFIG_CRYPTO_BLOWFISH_X86_64 is not set
# CONFIG_CRYPTO_CAMELLIA_X86_64 is not set
# CONFIG_CRYPTO_CAMELLIA_AESNI_AVX_X86_64 is not set
# CONFIG_CRYPTO_CAMELLIA_AESNI_AVX2_X86_64 is not set
# CONFIG_CRYPTO_CAST5_AVX_X86_64 is not set
# CONFIG_CRYPTO_CAST6_AVX_X86_64 is not set
# CONFIG_CRYPTO_SALSA20 is not set
# CONFIG_CRYPTO_SALSA20_X86_64 is not set
# CONFIG_CRYPTO_SERPENT_SSE2_X86_64 is not set
# CONFIG_CRYPTO_SERPENT_AVX_X86_64 is not set
# CONFIG_CRYPTO_SERPENT_AVX2_X86_64 is not set
# CONFIG_CRYPTO_TWOFISH_X86_64 is not set
# CONFIG_CRYPTO_TWOFISH_X86_64_3WAY is not set
# CONFIG_CRYPTO_TWOFISH_AVX_X86_64 is not set
# CONFIG_CRYPTO_USER_API_HASH is not set
# CONFIG_CRYPTO_USER_API_SKCIPHER is not set
# CONFIG_CRYPTO_DEV_PADLOCK is not set
#Disable unused options from rt kernel
# CONFIG_WIRELESS_EXT is not set
# CONFIG_DLCI is not set
# CONFIG_IPPP_FILTER is not set
# CONFIG_HISAX_EURO is not set
# CONFIG_DE_AOC is not set
# CONFIG_HISAX_NO_SENDCOMPLETE is not set
# CONFIG_HISAX_NO_LLC is not set
# CONFIG_HISAX_NO_KEYPAD is not set
# CONFIG_HISAX_1TR6 is not set
# CONFIG_HISAX_NI1 is not set
# CONFIG_HISAX_16_3 is not set
# CONFIG_HISAX_TELESPCI is not set
# CONFIG_HISAX_S0BOX is not set
# CONFIG_HISAX_FRITZPCI is not set
# CONFIG_HISAX_AVM_A1_PCMCIA is not set
# CONFIG_HISAX_ELSA is not set
# CONFIG_HISAX_DIEHLDIVA is not set
# CONFIG_HISAX_SEDLBAUER is not set
# CONFIG_HISAX_NETJET is not set
# CONFIG_HISAX_NETJET_U is not set
# CONFIG_HISAX_NICCY is not set
# CONFIG_HISAX_BKM_A4T is not set
# CONFIG_HISAX_SCT_QUADRO is not set
# CONFIG_HISAX_GAZEL is not set
# CONFIG_HISAX_HFC_PCI is not set
# CONFIG_HISAX_W6692 is not set
# CONFIG_HISAX_HFC_SX is not set
# CONFIG_HISAX_ENTERNOW_PCI is not set
# CONFIG_HISAX_ST5481 is not set
# CONFIG_HISAX_HFC4S8S is not set
# CONFIG_HISAX_FRITZ_PCIPNP is not set
# CONFIG_CAPI_AVM is not set
# CONFIG_GIGASET_CAPI is not set
# CONFIG_GIGASET_BASE is not set
# CONFIG_GIGASET_M105 is not set
# CONFIG_GIGASET_M101 is not set
# CONFIG_HYSDN is not set
# CONFIG_HYSDN_CAPI is not set
# CONFIG_MISDN is not set
# CONFIG_MISDN_DSP is not set
# CONFIG_MISDN_L1OIP is not set
# CONFIG_MISDN_HFCPCI is not set
# CONFIG_MISDN_HFCMULTI is not set
# CONFIG_MISDN_HFCUSB is not set
# CONFIG_MISDN_AVMFRITZ is not set
# CONFIG_MISDN_SPEEDFAX is not set
# CONFIG_MISDN_INFINEON is not set
# CONFIG_MISDN_W6692 is not set
# CONFIG_MISDN_NETJET is not set
# CONFIG_MISDN_IPAC is not set
# CONFIG_MISDN_ISAR is not set
# CONFIG_MEDIA_CAMERA_SUPPORT is not set
# CONFIG_MEDIA_ANALOG_TV_SUPPORT is not set
# CONFIG_MEDIA_DIGITAL_TV_SUPPORT is not set
# CONFIG_MEDIA_RADIO_SUPPORT is not set
# CONFIG_MEDIA_RC_SUPPORT is not set
# CONFIG_VIDEO_DEV is not set
# CONFIG_VIDEO_V4L2 is not set
# CONFIG_VIDEO_TUNER is not set
# CONFIG_VIDEOBUF_GEN is not set
# CONFIG_VIDEOBUF_DMA_SG is not set
# CONFIG_VIDEOBUF_VMALLOC is not set
# CONFIG_VIDEOBUF_DVB is not set
# CONFIG_VIDEOBUF2_CORE is not set
# CONFIG_VIDEOBUF2_MEMOPS is not set
# CONFIG_VIDEOBUF2_VMALLOC is not set
# CONFIG_DVB is not set
# CONFIG_DVB_CORE is not set
# CONFIG_DVB_NET is not set
# CONFIG_TTPCI_EEPROM is not set
# CONFIG_DVB_DYNAMIC_MINORS is not set
# CONFIG_RC_CORE is not set
# CONFIG_RC_MAP is not set
# CONFIG_RC_DECODERS is not set
# CONFIG_LIRC is not set
# CONFIG_IR_LIRC_CODEC is not set
# CONFIG_IR_NEC_DECODER is not set
# CONFIG_IR_RC5_DECODER is not set
# CONFIG_IR_RC6_DECODER is not set
# CONFIG_IR_JVC_DECODER is not set
# CONFIG_IR_SONY_DECODER is not set
# CONFIG_IR_RC5_SZ_DECODER is not set
# CONFIG_IR_SANYO_DECODER is not set
# CONFIG_IR_MCE_KBD_DECODER is not set
# CONFIG_RC_DEVICES is not set
# CONFIG_RC_ATI_REMOTE is not set
# CONFIG_IR_ENE is not set
# CONFIG_IR_IMON is not set
# CONFIG_IR_MCEUSB is not set
# CONFIG_IR_ITE_CIR is not set
# CONFIG_IR_FINTEK is not set
# CONFIG_IR_NUVOTON is not set
# CONFIG_IR_REDRAT3 is not set
# CONFIG_IR_STREAMZAP is not set
# CONFIG_IR_WINBOND_CIR is not set
# CONFIG_IR_IGUANA is not set
# CONFIG_IR_TTUSBIR is not set
# CONFIG_VIDEO_EM28XX is not set
# CONFIG_VIDEO_EM28XX_ALSA is not set
# CONFIG_VIDEO_EM28XX_DVB is not set
# CONFIG_VIDEO_EM28XX_RC is not set
# CONFIG_MEDIA_PCI_SUPPORT is not set
# CONFIG_VIDEO_IVTV is not set
# CONFIG_VIDEO_FB_IVTV is not set
# CONFIG_VIDEO_CX18 is not set
# CONFIG_VIDEO_CX18_ALSA is not set
# CONFIG_VIDEO_CX23885 is not set
# CONFIG_MEDIA_ALTERA_CI is not set
# CONFIG_VIDEO_CX88 is not set
# CONFIG_VIDEO_CX88_ALSA is not set
# CONFIG_VIDEO_CX88_BLACKBIRD is not set
# CONFIG_VIDEO_CX88_DVB is not set
# CONFIG_VIDEO_CX88_VP3054 is not set
# CONFIG_VIDEO_CX88_MPEG is not set
# CONFIG_VIDEO_BT848 is not set
# CONFIG_VIDEO_SAA7134 is not set
# CONFIG_VIDEO_SAA7134_ALSA is not set
# CONFIG_VIDEO_SAA7134_RC is not set
# CONFIG_VIDEO_SAA7134_DVB is not set
# CONFIG_VIDEO_SAA7164 is not set
# CONFIG_MANTIS_CORE is not set
# CONFIG_SMS_SDIO_DRV is not set
# CONFIG_MEDIA_COMMON_OPTIONS is not set
# CONFIG_VIDEO_CX2341X is not set
# CONFIG_VIDEO_BTCX is not set
# CONFIG_VIDEO_TVEEPROM is not set
# CONFIG_CYPRESS_FIRMWARE is not set
# CONFIG_VIDEO_SAA7146 is not set
# CONFIG_VIDEO_SAA7146_VV is not set
# CONFIG_SMS_SIANO_MDTV is not set
# CONFIG_SMS_SIANO_RC is not set
# CONFIG_MEDIA_SUBDRV_AUTOSELECT is not set
# CONFIG_MEDIA_ATTACH is not set
# CONFIG_VIDEO_IR_I2C is not set
# CONFIG_VIDEO_TVAUDIO is not set
# CONFIG_VIDEO_TDA7432 is not set
# CONFIG_VIDEO_MSP3400 is not set
# CONFIG_VIDEO_CS5345 is not set
# CONFIG_VIDEO_CS53L32A is not set
# CONFIG_VIDEO_WM8775 is not set
# CONFIG_VIDEO_WM8739 is not set
# CONFIG_VIDEO_VP27SMPX is not set
# CONFIG_VIDEO_SAA6588 is not set
# CONFIG_VIDEO_SAA711X is not set
# CONFIG_VIDEO_TVP5150 is not set
# CONFIG_VIDEO_SAA717X is not set
# CONFIG_VIDEO_CX25840 is not set
# CONFIG_VIDEO_SAA7127 is not set
# CONFIG_VIDEO_MT9V011 is not set
# CONFIG_VIDEO_UPD64031A is not set
# CONFIG_VIDEO_UPD64083 is not set
# CONFIG_VIDEO_M52790 is not set
# CONFIG_MEDIA_TUNER is not set
# CONFIG_SND is not set
# CONFIG_IR_GPIO_CIR is not set
CONFIG_BLK_DEV_NBD=m
# CONFIG_AIC94XX_DEBUG is not set
# CONFIG_GPIO_BT8XX is not set
# Disable transparent huge pages
# CONFIG_TRANSPARENT_HUGEPAGE is not set
# CONFIG_TRANSPARENT_HUGEPAGE_ALWAYS is not set
# Make performance default governor
# CONFIG_CPU_FREQ_DEFAULT_GOV_ONDEMAND is not set
CONFIG_CPU_FREQ_DEFAULT_GOV_PERFORMANCE=y
# CONFIG_TORTURE_TEST is not set
# CONFIG_RCU_TORTURE_TEST is not set
# CONFIG_LOCK_TORTURE_TEST is not set
# Needed for opae fpga kernel module
# # as it turns on hidden option REGMAP_MMIO
CONFIG_MFD_SYSCON=y
#
# enable e1000 driver as module same as kernel-std
CONFIG_E1000=m

View File

@ -1,96 +0,0 @@
From ea38fcef34645b2220eadad6c862d5884c48026d Mon Sep 17 00:00:00 2001
Message-Id: <ea38fcef34645b2220eadad6c862d5884c48026d.1528226387.git.Jim.Somerville@windriver.com>
In-Reply-To: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
References: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
From: Akinobu Mita <akinobu.mita@gmail.com>
Date: Tue, 31 May 2016 16:07:55 -0400
Subject: [PATCH 10/32] memblock: introduce memblock_alloc_range()
Commit 2bfc2862c4fe38379a2fb2cfba33fad32ccb4ff4 upstream
Backported-by: Nam Ninh <nam.ninh@windriver.com>
This introduces memblock_alloc_range() which allocates memblock from the
specified range of physical address. I would like to use this function
to specify the location of CMA.
Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
Cc: Marek Szyprowski <m.szyprowski@samsung.com>
Cc: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Cc: David Woodhouse <dwmw2@infradead.org>
Cc: Don Dutile <ddutile@redhat.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: Andi Kleen <andi@firstfloor.org>
Cc: Yinghai Lu <yinghai@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
---
include/linux/memblock.h | 2 ++
mm/memblock.c | 22 ++++++++++++++++++----
2 files changed, 20 insertions(+), 4 deletions(-)
diff --git a/include/linux/memblock.h b/include/linux/memblock.h
index 5a439c9..d6bcbef 100644
--- a/include/linux/memblock.h
+++ b/include/linux/memblock.h
@@ -306,6 +306,8 @@ static inline bool memblock_bottom_up(void) { return false; }
#define MEMBLOCK_ALLOC_ANYWHERE (~(phys_addr_t)0)
#define MEMBLOCK_ALLOC_ACCESSIBLE 0
+phys_addr_t __init memblock_alloc_range(phys_addr_t size, phys_addr_t align,
+ phys_addr_t start, phys_addr_t end);
phys_addr_t memblock_alloc_base(phys_addr_t size, phys_addr_t align,
phys_addr_t max_addr);
phys_addr_t __memblock_alloc_base(phys_addr_t size, phys_addr_t align,
diff --git a/mm/memblock.c b/mm/memblock.c
index fbc8071..ff910a4 100644
--- a/mm/memblock.c
+++ b/mm/memblock.c
@@ -1120,9 +1120,9 @@ int __init_memblock memblock_set_node(phys_addr_t base, phys_addr_t size,
}
#endif /* CONFIG_HAVE_MEMBLOCK_NODE_MAP */
-static phys_addr_t __init memblock_alloc_base_nid(phys_addr_t size,
- phys_addr_t align, phys_addr_t max_addr,
- int nid, ulong flags)
+static phys_addr_t __init memblock_alloc_range_nid(phys_addr_t size,
+ phys_addr_t align, phys_addr_t start,
+ phys_addr_t end, int nid, ulong flags)
{
phys_addr_t found;
@@ -1132,7 +1132,7 @@ static phys_addr_t __init memblock_alloc_base_nid(phys_addr_t size,
/* align @size to avoid excessive fragmentation on reserved array */
size = round_up(size, align);
- found = memblock_find_in_range_node(size, align, 0, max_addr, nid,
+ found = memblock_find_in_range_node(size, align, start, end, nid,
flags);
if (found && !memblock_reserve(found, size))
return found;
@@ -1140,6 +1140,20 @@ static phys_addr_t __init memblock_alloc_base_nid(phys_addr_t size,
return 0;
}
+phys_addr_t __init memblock_alloc_range(phys_addr_t size, phys_addr_t align,
+ phys_addr_t start, phys_addr_t end)
+{
+ ulong flags = choose_memblock_flags();
+ return memblock_alloc_range_nid(size, align, start, end, NUMA_NO_NODE, flags);
+}
+
+static phys_addr_t __init memblock_alloc_base_nid(phys_addr_t size,
+ phys_addr_t align, phys_addr_t max_addr,
+ int nid, ulong flags)
+{
+ return memblock_alloc_range_nid(size, align, 0, max_addr, nid, flags);
+}
+
phys_addr_t __init memblock_alloc_nid(phys_addr_t size, phys_addr_t align, int nid)
{
ulong flags = choose_memblock_flags();
--
1.8.3.1

View File

@ -1,25 +1,23 @@
From d692cbb183b38e030c7c1221b67c9389bdeaf7f3 Mon Sep 17 00:00:00 2001 From e2e6b3f625a3a6cc0202c60ce93ca9d300cb6b9b Mon Sep 17 00:00:00 2001
Message-Id: <d692cbb183b38e030c7c1221b67c9389bdeaf7f3.1528226387.git.Jim.Somerville@windriver.com>
In-Reply-To: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
References: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
From: Alex Kozyrev <alex.kozyrev@windriver.com> From: Alex Kozyrev <alex.kozyrev@windriver.com>
Date: Fri, 16 Mar 2018 15:50:57 -0400 Date: Fri, 16 Mar 2018 15:50:57 -0400
Subject: [PATCH 32/32] restrict iSCSI kthreads to CPUs in cpu_kthread_mask Subject: [PATCH 1/2] restrict iSCSI kthreads to CPUs in cpu_kthread_mask
Do not allow them to run on other CPUs to prevent interference with VMs. Do not allow them to run on other CPUs to prevent interference with VMs.
Signed-off-by: Alex Kozyrev <alex.kozyrev@windriver.com> Signed-off-by: Alex Kozyrev <alex.kozyrev@windriver.com>
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com> Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
Signed-off-by: Austin Sun <austin.sun@intel.com>
--- ---
drivers/target/iscsi/iscsi_target.c | 4 ++-- drivers/target/iscsi/iscsi_target.c | 4 ++--
include/linux/cpumask.h | 1 + include/linux/cpumask.h | 1 +
2 files changed, 3 insertions(+), 2 deletions(-) 2 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/target/iscsi/iscsi_target.c b/drivers/target/iscsi/iscsi_target.c diff --git a/drivers/target/iscsi/iscsi_target.c b/drivers/target/iscsi/iscsi_target.c
index d8f587e..17b08b7 100644 index 5ce6e2a40..a38c73525 100644
--- a/drivers/target/iscsi/iscsi_target.c --- a/drivers/target/iscsi/iscsi_target.c
+++ b/drivers/target/iscsi/iscsi_target.c +++ b/drivers/target/iscsi/iscsi_target.c
@@ -3575,8 +3575,8 @@ void iscsit_thread_get_cpumask(struct iscsi_conn *conn) @@ -3543,8 +3543,8 @@ void iscsit_thread_get_cpumask(struct iscsi_conn *conn)
* iSCSI connection's RX/TX threads will be scheduled to * iSCSI connection's RX/TX threads will be scheduled to
* execute upon. * execute upon.
*/ */
@ -31,17 +29,17 @@ index d8f587e..17b08b7 100644
cpumask_set_cpu(cpu, conn->conn_cpumask); cpumask_set_cpu(cpu, conn->conn_cpumask);
return; return;
diff --git a/include/linux/cpumask.h b/include/linux/cpumask.h diff --git a/include/linux/cpumask.h b/include/linux/cpumask.h
index 46ae77a..42b6c63 100644 index 57f20a0a7..7029aeae7 100644
--- a/include/linux/cpumask.h --- a/include/linux/cpumask.h
+++ b/include/linux/cpumask.h +++ b/include/linux/cpumask.h
@@ -754,6 +754,7 @@ extern const DECLARE_BITMAP(cpu_all_bits, NR_CPUS); @@ -770,6 +770,7 @@ extern const DECLARE_BITMAP(cpu_all_bits, NR_CPUS);
#define for_each_possible_cpu(cpu) for_each_cpu((cpu), cpu_possible_mask) #define for_each_possible_cpu(cpu) for_each_cpu((cpu), cpu_possible_mask)
#define for_each_online_cpu(cpu) for_each_cpu((cpu), cpu_online_mask) #define for_each_online_cpu(cpu) for_each_cpu((cpu), cpu_online_mask)
#define for_each_present_cpu(cpu) for_each_cpu((cpu), cpu_present_mask) #define for_each_present_cpu(cpu) for_each_cpu((cpu), cpu_present_mask)
+#define for_each_kthread_cpu(cpu) for_each_cpu((cpu), cpu_kthread_mask) +#define for_each_kthread_cpu(cpu) for_each_cpu((cpu), cpu_kthread_mask)
/* Wrappers for arch boot code to manipulate normally-constant masks */ /* Wrappers for arch boot code to manipulate normally-constant masks */
void set_cpu_possible(unsigned int cpu, bool possible); void init_cpu_present(const struct cpumask *src);
-- --
1.8.3.1 2.19.1

View File

@ -1,67 +0,0 @@
From a16765613c5cb9b6cb86bc92d21030be124b2dde Mon Sep 17 00:00:00 2001
Message-Id: <a16765613c5cb9b6cb86bc92d21030be124b2dde.1566590430.git.Jim.Somerville@windriver.com>
In-Reply-To: <fdb837fb87ff4907436dfab16709b64d6c3488fd.1566590430.git.Jim.Somerville@windriver.com>
References: <fdb837fb87ff4907436dfab16709b64d6c3488fd.1566590430.git.Jim.Somerville@windriver.com>
From: Stanislav Kinsburskiy <skinsbursky@virtuozzo.com>
Date: Fri, 9 Feb 2018 11:52:14 +0300
Subject: [PATCH 2/3] rh/ext4: release leaked posix acl in ext4_acl_chmod
[ commit b85d6be0b743a1768b8456d36b52960858fbaa67 in OpenVZ's vzkernel repo ]
Note: only rh7-3.10.0-693.17.1.el7-based kernels are affected.
I.e. starting from rh7-3.10.0-693.17.1.vz7.43.1.
Posix acl is used to convert of an extended attribute, provided by user to ext4
attributes. In particular to i_mode in case of ACL_TYPE_ACCESS request.
IOW, this object is allocated, used for convertion, not stored anywhere and
must be freed.
However posix_acl_update_mode() can zerofy the pointer to support
ext4_set_acl() logic, but then the object is leaked. So, fix it by releasing
new temporary pointer with the same value instead of acl pointer.
In scope of https://jira.sw.ru/browse/PSBM-81384
RHEL bug URL: https://bugzilla.redhat.com/show_bug.cgi?id=1543020
Signed-off-by: Stanislav Kinsburskiy <skinsbursky@virtuozzo.com>
Acked-by: Dmitry Monakhov <dmonakhov@openvz.org>
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
---
fs/ext4/acl.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/fs/ext4/acl.c b/fs/ext4/acl.c
index 917e819..fce029f 100644
--- a/fs/ext4/acl.c
+++ b/fs/ext4/acl.c
@@ -297,7 +297,7 @@ cleanup:
int
ext4_acl_chmod(struct inode *inode)
{
- struct posix_acl *acl;
+ struct posix_acl *acl, *real_acl;
handle_t *handle;
int retries = 0;
int error;
@@ -315,6 +315,8 @@ ext4_acl_chmod(struct inode *inode)
error = posix_acl_chmod(&acl, GFP_KERNEL, inode->i_mode);
if (error)
return error;
+
+ real_acl = acl;
retry:
handle = ext4_journal_start(inode, EXT4_HT_XATTR,
ext4_jbd2_credits_xattr(inode));
@@ -341,7 +343,7 @@ out_stop:
ext4_should_retry_alloc(inode->i_sb, &retries))
goto retry;
out:
- posix_acl_release(acl);
+ posix_acl_release(real_acl);
return error;
}
--
1.8.3.1

View File

@ -1,79 +0,0 @@
From 916c45d11310d03a4a76bd80a40f0c6a767ba39e Mon Sep 17 00:00:00 2001
Message-Id: <916c45d11310d03a4a76bd80a40f0c6a767ba39e.1566590430.git.Jim.Somerville@windriver.com>
In-Reply-To: <fdb837fb87ff4907436dfab16709b64d6c3488fd.1566590430.git.Jim.Somerville@windriver.com>
References: <fdb837fb87ff4907436dfab16709b64d6c3488fd.1566590430.git.Jim.Somerville@windriver.com>
From: Stanislav Kinsburskiy <skinsbursky@virtuozzo.com>
Date: Fri, 9 Feb 2018 11:52:15 +0300
Subject: [PATCH 3/3] rh/ext4: release leaked posix acl in ext4_xattr_set_acl
[ commit b762d904ada70f239f1c2d2d70c4a64cd04c8ade in OpenVZ's vzkernel repo ]
Note: only rh7-3.10.0-693.17.1.el7-based kernels are affcted.
I.e. starting from rh7-3.10.0-693.17.1.vz7.43.1.
Posix acl is used to convert of an extended attribute, provided by user to ext4
attributes. In particular to i_mode in case of ACL_TYPE_ACCESS request.
IOW, this object is allocated, used for convertion, not stored anywhere and
must be freed.
However posix_acl_update_mode() can zerofy the pointer to support
ext4_set_acl() logic, but then the object is leaked. So, fix it by releasing
new temporary pointer with the same value instead of acl pointer.
https://jira.sw.ru/browse/PSBM-81384
RHEL bug URL: https://bugzilla.redhat.com/show_bug.cgi?id=1543020
v2: Added affected kernel version + RHEL bug URL
Signed-off-by: Stanislav Kinsburskiy <skinsbursky@virtuozzo.com>
Acked-by: Dmitry Monakhov <dmonakhov@openvz.org>
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
---
fs/ext4/acl.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/fs/ext4/acl.c b/fs/ext4/acl.c
index fce029f..046b338 100644
--- a/fs/ext4/acl.c
+++ b/fs/ext4/acl.c
@@ -405,7 +405,7 @@ ext4_xattr_set_acl(struct dentry *dentry, const char *name, const void *value,
{
struct inode *inode = dentry->d_inode;
handle_t *handle;
- struct posix_acl *acl;
+ struct posix_acl *acl, *real_acl;
int error, retries = 0;
int update_mode = 0;
umode_t mode = inode->i_mode;
@@ -418,7 +418,7 @@ ext4_xattr_set_acl(struct dentry *dentry, const char *name, const void *value,
return -EPERM;
if (value) {
- acl = posix_acl_from_xattr(&init_user_ns, value, size);
+ acl = real_acl = posix_acl_from_xattr(&init_user_ns, value, size);
if (IS_ERR(acl))
return PTR_ERR(acl);
else if (acl) {
@@ -427,7 +427,7 @@ ext4_xattr_set_acl(struct dentry *dentry, const char *name, const void *value,
goto release_and_out;
}
} else
- acl = NULL;
+ acl = real_acl = NULL;
retry:
handle = ext4_journal_start(inode, EXT4_HT_XATTR,
@@ -454,7 +454,7 @@ out_stop:
goto retry;
release_and_out:
- posix_acl_release(acl);
+ posix_acl_release(real_acl);
return error;
}
--
1.8.3.1

View File

@ -1,167 +0,0 @@
From c0ad4aa4d8416a39ad262a2bd68b30acd951bf0e Mon Sep 17 00:00:00 2001
From: Peter Zijlstra <peterz@infradead.org>
Date: Mon, 7 Jan 2019 13:52:31 +0100
Subject: sched/fair: Robustify CFS-bandwidth timer locking
Traditionally hrtimer callbacks were run with IRQs disabled, but with
the introduction of HRTIMER_MODE_SOFT it is possible they run from
SoftIRQ context, which does _NOT_ have IRQs disabled.
Allow for the CFS bandwidth timers (period_timer and slack_timer) to
be ran from SoftIRQ context; this entails removing the assumption that
IRQs are already disabled from the locking.
While mainline doesn't strictly need this, -RT forces all timers not
explicitly marked with MODE_HARD into MODE_SOFT and trips over this.
And marking these timers as MODE_HARD doesn't make sense as they're
not required for RT operation and can potentially be quite expensive.
Reported-by: Tom Putzeys <tom.putzeys@be.atlascopco.com>
Tested-by: Mike Galbraith <efault@gmx.de>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Cc: Thomas Gleixner <tglx@linutronix.de>
Link: https://lkml.kernel.org/r/20190107125231.GE14122@hirez.programming.kicks-ass.net
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Signed-off-by: Alex Kozyrev <alex.kozyrev@windriver.com>
---
kernel/sched/fair.c | 33 ++++++++++++++++++---------------
1 file changed, 18 insertions(+), 15 deletions(-)
diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c
index d3d746b..e9a8d95 100644
--- a/kernel/sched/fair.c
+++ b/kernel/sched/fair.c
@@ -3490,13 +3490,14 @@ static u64 distribute_cfs_runtime(struct cfs_bandwidth *cfs_b,
struct cfs_rq *cfs_rq;
u64 runtime;
u64 starting_runtime = remaining;
+ unsigned long flags;
rcu_read_lock();
list_for_each_entry_rcu(cfs_rq, &cfs_b->throttled_cfs_rq,
throttled_list) {
struct rq *rq = rq_of(cfs_rq);
- raw_spin_lock(&rq->lock);
+ raw_spin_lock_irqsave(&rq->lock, flags);
if (!cfs_rq_throttled(cfs_rq))
goto next;
@@ -3513,7 +3514,7 @@ static u64 distribute_cfs_runtime(struct cfs_bandwidth *cfs_b,
unthrottle_cfs_rq(cfs_rq);
next:
- raw_spin_unlock(&rq->lock);
+ raw_spin_unlock_irqrestore(&rq->lock, flags);
if (!remaining)
break;
@@ -3529,7 +3530,7 @@ next:
* period the timer is deactivated until scheduling resumes; cfs_b->idle is
* used to track this state.
*/
-static int do_sched_cfs_period_timer(struct cfs_bandwidth *cfs_b, int overrun)
+static int do_sched_cfs_period_timer(struct cfs_bandwidth *cfs_b, int overrun, unsigned long flags)
{
u64 runtime, runtime_expires;
int throttled;
@@ -3578,11 +3579,11 @@ static int do_sched_cfs_period_timer(struct cfs_bandwidth *cfs_b, int overrun)
while (throttled && cfs_b->runtime > 0 && !cfs_b->distribute_running) {
runtime = cfs_b->runtime;
cfs_b->distribute_running = 1;
- raw_spin_unlock(&cfs_b->lock);
+ raw_spin_unlock_irqrestore(&cfs_b->lock, flags);
/* we can't nest cfs_b->lock while distributing bandwidth */
runtime = distribute_cfs_runtime(cfs_b, runtime,
runtime_expires);
- raw_spin_lock(&cfs_b->lock);
+ raw_spin_lock_irqsave(&cfs_b->lock, flags);
cfs_b->distribute_running = 0;
throttled = !list_empty(&cfs_b->throttled_cfs_rq);
@@ -3691,17 +3692,18 @@ static __always_inline void return_cfs_rq_runtime(struct cfs_rq *cfs_rq)
static void do_sched_cfs_slack_timer(struct cfs_bandwidth *cfs_b)
{
u64 runtime = 0, slice = sched_cfs_bandwidth_slice();
+ unsigned long flags;
u64 expires;
/* confirm we're still not at a refresh boundary */
- raw_spin_lock(&cfs_b->lock);
+ raw_spin_lock_irqsave(&cfs_b->lock, flags);
if (cfs_b->distribute_running) {
- raw_spin_unlock(&cfs_b->lock);
+ raw_spin_unlock_irqrestore(&cfs_b->lock, flags);
return;
}
if (runtime_refresh_within(cfs_b, min_bandwidth_expiration)) {
- raw_spin_unlock(&cfs_b->lock);
+ raw_spin_unlock_irqrestore(&cfs_b->lock, flags);
return;
}
@@ -3712,18 +3714,18 @@ static void do_sched_cfs_slack_timer(struct cfs_bandwidth *cfs_b)
if (runtime)
cfs_b->distribute_running = 1;
- raw_spin_unlock(&cfs_b->lock);
+ raw_spin_unlock_irqrestore(&cfs_b->lock, flags);
if (!runtime)
return;
runtime = distribute_cfs_runtime(cfs_b, runtime, expires);
- raw_spin_lock(&cfs_b->lock);
+ raw_spin_lock_irqsave(&cfs_b->lock, flags);
if (expires == cfs_b->runtime_expires)
cfs_b->runtime -= min(runtime, cfs_b->runtime);
cfs_b->distribute_running = 0;
- raw_spin_unlock(&cfs_b->lock);
+ raw_spin_unlock_irqrestore(&cfs_b->lock, flags);
}
/*
@@ -3787,7 +3789,7 @@ static void check_cfs_rq_runtime(struct cfs_rq *cfs_rq)
}
static inline u64 default_cfs_period(void);
-static int do_sched_cfs_period_timer(struct cfs_bandwidth *cfs_b, int overrun);
+static int do_sched_cfs_period_timer(struct cfs_bandwidth *cfs_b, int overrunn, unsigned long flags);
static void do_sched_cfs_slack_timer(struct cfs_bandwidth *cfs_b);
static enum hrtimer_restart sched_cfs_slack_timer(struct hrtimer *timer)
@@ -3806,11 +3808,12 @@ static enum hrtimer_restart sched_cfs_period_timer(struct hrtimer *timer)
struct cfs_bandwidth *cfs_b =
container_of(timer, struct cfs_bandwidth, period_timer);
ktime_t now;
+ unsigned long flags;
int overrun;
int idle = 0;
int count = 0;
- raw_spin_lock(&cfs_b->lock);
+ raw_spin_lock_irqsave(&cfs_b->lock, flags);
for (;;) {
now = hrtimer_cb_get_time(timer);
overrun = hrtimer_forward(timer, now, cfs_b->period);
@@ -3840,9 +3843,9 @@ static enum hrtimer_restart sched_cfs_period_timer(struct hrtimer *timer)
count = 0;
}
- idle = do_sched_cfs_period_timer(cfs_b, overrun);
+ idle = do_sched_cfs_period_timer(cfs_b, overrun, flags);
}
- raw_spin_unlock(&cfs_b->lock);
+ raw_spin_unlock_irqrestore(&cfs_b->lock, flags);
return idle ? HRTIMER_NORESTART : HRTIMER_RESTART;
}
--
1.8.3.1

View File

@ -1,22 +1,20 @@
From 81371b5453a5a08d8d03d37aa993b41a7169b342 Mon Sep 17 00:00:00 2001 From 188641f520d4c12abc42a7112e75845e94b7993e Mon Sep 17 00:00:00 2001
Message-Id: <81371b5453a5a08d8d03d37aa993b41a7169b342.1528226387.git.Jim.Somerville@windriver.com>
In-Reply-To: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
References: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
From: Jim Somerville <Jim.Somerville@windriver.com> From: Jim Somerville <Jim.Somerville@windriver.com>
Date: Tue, 6 Mar 2018 12:54:40 -0500 Date: Tue, 6 Mar 2018 12:54:40 -0500
Subject: [PATCH 31/32] turn off write same in smartqpi driver Subject: [PATCH 09/10] turn off write same in smartqpi driver
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com> Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
Signed-off-by: Zhang Zhiguo <zhangzhg@neusoft.com>
--- ---
drivers/scsi/smartpqi/smartpqi_init.c | 1 + drivers/scsi/smartpqi/smartpqi_init.c | 1 +
1 file changed, 1 insertion(+) 1 file changed, 1 insertion(+)
diff --git a/drivers/scsi/smartpqi/smartpqi_init.c b/drivers/scsi/smartpqi/smartpqi_init.c diff --git a/drivers/scsi/smartpqi/smartpqi_init.c b/drivers/scsi/smartpqi/smartpqi_init.c
index 2c6b546..6968c48 100644 index 7810cb2..9895f7f 100644
--- a/drivers/scsi/smartpqi/smartpqi_init.c --- a/drivers/scsi/smartpqi/smartpqi_init.c
+++ b/drivers/scsi/smartpqi/smartpqi_init.c +++ b/drivers/scsi/smartpqi/smartpqi_init.c
@@ -5814,6 +5814,7 @@ static struct scsi_host_template pqi_driver_template = { @@ -6413,6 +6413,7 @@ static struct scsi_host_template pqi_driver_template = {
.slave_alloc = pqi_slave_alloc, .map_queues = pqi_map_queues,
.sdev_attrs = pqi_sdev_attrs, .sdev_attrs = pqi_sdev_attrs,
.shost_attrs = pqi_shost_attrs, .shost_attrs = pqi_shost_attrs,
+ .no_write_same = 1, + .no_write_same = 1,
@ -24,5 +22,5 @@ index 2c6b546..6968c48 100644
static int pqi_register_scsi(struct pqi_ctrl_info *ctrl_info) static int pqi_register_scsi(struct pqi_ctrl_info *ctrl_info)
-- --
1.8.3.1 2.7.4

View File

@ -1,156 +0,0 @@
From 37680a25caeba0ee4e5f26cb524ff8b4faa5c0f5 Mon Sep 17 00:00:00 2001
Message-Id: <37680a25caeba0ee4e5f26cb524ff8b4faa5c0f5.1528226387.git.Jim.Somerville@windriver.com>
In-Reply-To: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
References: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
From: Akinobu Mita <akinobu.mita@gmail.com>
Date: Wed, 4 Jun 2014 16:06:50 -0700
Subject: [PATCH 13/32] x86: enable DMA CMA with swiotlb
commit 9c5a3621427da68afe6a078cadf807d2c8cc1d12 upstream.
Ported-by: Nam Ninh <nam.ninh@windriver.com>
The DMA Contiguous Memory Allocator support on x86 is disabled when
swiotlb config option is enabled. So DMA CMA is always disabled on
x86_64 because swiotlb is always enabled. This attempts to support for
DMA CMA with enabling swiotlb config option.
The contiguous memory allocator on x86 is integrated in the function
dma_generic_alloc_coherent() which is .alloc callback in nommu_dma_ops
for dma_alloc_coherent().
x86_swiotlb_alloc_coherent() which is .alloc callback in swiotlb_dma_ops
tries to allocate with dma_generic_alloc_coherent() firstly and then
swiotlb_alloc_coherent() is called as a fallback.
The main part of supporting DMA CMA with swiotlb is that changing
x86_swiotlb_free_coherent() which is .free callback in swiotlb_dma_ops
for dma_free_coherent() so that it can distinguish memory allocated by
dma_generic_alloc_coherent() from one allocated by
swiotlb_alloc_coherent() and release it with dma_generic_free_coherent()
which can handle contiguous memory. This change requires making
is_swiotlb_buffer() global function.
This also needs to change .free callback in the dma_map_ops for amd_gart
and sta2x11, because these dma_ops are also using
dma_generic_alloc_coherent().
Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
Acked-by: Marek Szyprowski <m.szyprowski@samsung.com>
Acked-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Cc: David Woodhouse <dwmw2@infradead.org>
Cc: Don Dutile <ddutile@redhat.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: Andi Kleen <andi@firstfloor.org>
Cc: Yinghai Lu <yinghai@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
---
arch/x86/Kconfig | 2 +-
arch/x86/include/asm/swiotlb.h | 7 +++++++
arch/x86/kernel/amd_gart_64.c | 2 +-
arch/x86/kernel/pci-swiotlb.c | 9 ++++++---
arch/x86/pci/sta2x11-fixup.c | 6 ++----
5 files changed, 17 insertions(+), 9 deletions(-)
diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig
index bdcca71..f67aa39 100644
--- a/arch/x86/Kconfig
+++ b/arch/x86/Kconfig
@@ -47,7 +47,7 @@ config X86
select ARCH_WANT_BATCHED_UNMAP_TLB_FLUSH if SMP
select ARCH_WANT_OPTIONAL_GPIOLIB
select ARCH_WANT_FRAME_POINTERS
- select HAVE_DMA_CONTIGUOUS if !SWIOTLB
+ select HAVE_DMA_CONTIGUOUS
select HAVE_KRETPROBES
select HAVE_OPTPROBES
select HAVE_KPROBES_ON_FTRACE
diff --git a/arch/x86/include/asm/swiotlb.h b/arch/x86/include/asm/swiotlb.h
index 977f176..ab05d73 100644
--- a/arch/x86/include/asm/swiotlb.h
+++ b/arch/x86/include/asm/swiotlb.h
@@ -29,4 +29,11 @@ static inline void pci_swiotlb_late_init(void)
static inline void dma_mark_clean(void *addr, size_t size) {}
+extern void *x86_swiotlb_alloc_coherent(struct device *hwdev, size_t size,
+ dma_addr_t *dma_handle, gfp_t flags,
+ struct dma_attrs *attrs);
+extern void x86_swiotlb_free_coherent(struct device *dev, size_t size,
+ void *vaddr, dma_addr_t dma_addr,
+ struct dma_attrs *attrs);
+
#endif /* _ASM_X86_SWIOTLB_H */
diff --git a/arch/x86/kernel/amd_gart_64.c b/arch/x86/kernel/amd_gart_64.c
index b574b29..8e3842f 100644
--- a/arch/x86/kernel/amd_gart_64.c
+++ b/arch/x86/kernel/amd_gart_64.c
@@ -512,7 +512,7 @@ gart_free_coherent(struct device *dev, size_t size, void *vaddr,
dma_addr_t dma_addr, struct dma_attrs *attrs)
{
gart_unmap_page(dev, dma_addr, size, DMA_BIDIRECTIONAL, NULL);
- free_pages((unsigned long)vaddr, get_order(size));
+ dma_generic_free_coherent(dev, size, vaddr, dma_addr, attrs);
}
static int gart_mapping_error(struct device *dev, dma_addr_t dma_addr)
diff --git a/arch/x86/kernel/pci-swiotlb.c b/arch/x86/kernel/pci-swiotlb.c
index 4853440..284d506 100644
--- a/arch/x86/kernel/pci-swiotlb.c
+++ b/arch/x86/kernel/pci-swiotlb.c
@@ -16,7 +16,7 @@
int swiotlb __read_mostly;
-static void *x86_swiotlb_alloc_coherent(struct device *hwdev, size_t size,
+void *x86_swiotlb_alloc_coherent(struct device *hwdev, size_t size,
dma_addr_t *dma_handle, gfp_t flags,
struct dma_attrs *attrs)
{
@@ -30,11 +30,14 @@ static void *x86_swiotlb_alloc_coherent(struct device *hwdev, size_t size,
return swiotlb_alloc_coherent(hwdev, size, dma_handle, flags);
}
-static void x86_swiotlb_free_coherent(struct device *dev, size_t size,
+void x86_swiotlb_free_coherent(struct device *dev, size_t size,
void *vaddr, dma_addr_t dma_addr,
struct dma_attrs *attrs)
{
- swiotlb_free_coherent(dev, size, vaddr, dma_addr);
+ if (is_swiotlb_buffer(dma_to_phys(dev, dma_addr)))
+ swiotlb_free_coherent(dev, size, vaddr, dma_addr);
+ else
+ dma_generic_free_coherent(dev, size, vaddr, dma_addr, attrs);
}
static struct dma_map_ops swiotlb_dma_ops = {
diff --git a/arch/x86/pci/sta2x11-fixup.c b/arch/x86/pci/sta2x11-fixup.c
index 9d8a509..5ceda85 100644
--- a/arch/x86/pci/sta2x11-fixup.c
+++ b/arch/x86/pci/sta2x11-fixup.c
@@ -173,9 +173,7 @@ static void *sta2x11_swiotlb_alloc_coherent(struct device *dev,
{
void *vaddr;
- vaddr = dma_generic_alloc_coherent(dev, size, dma_handle, flags, attrs);
- if (!vaddr)
- vaddr = swiotlb_alloc_coherent(dev, size, dma_handle, flags);
+ vaddr = x86_swiotlb_alloc_coherent(dev, size, dma_handle, flags, attrs);
*dma_handle = p2a(*dma_handle, to_pci_dev(dev));
return vaddr;
}
@@ -183,7 +181,7 @@ static void *sta2x11_swiotlb_alloc_coherent(struct device *dev,
/* We have our own dma_ops: the same as swiotlb but from alloc (above) */
static struct dma_map_ops sta2x11_dma_ops = {
.alloc = sta2x11_swiotlb_alloc_coherent,
- .free = swiotlb_free_coherent,
+ .free = x86_swiotlb_free_coherent,
.map_page = swiotlb_map_page,
.unmap_page = swiotlb_unmap_page,
.map_sg = swiotlb_map_sg_attrs,
--
1.8.3.1

View File

@ -1,87 +0,0 @@
From 78743472402604dc4fc3304aed9634ae9fe845dd Mon Sep 17 00:00:00 2001
Message-Id: <78743472402604dc4fc3304aed9634ae9fe845dd.1528226387.git.Jim.Somerville@windriver.com>
In-Reply-To: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
References: <c8270e79f6b7008fde44b8d5aa6314d8cf89d3ed.1528226387.git.Jim.Somerville@windriver.com>
From: Akinobu Mita <akinobu.mita@gmail.com>
Date: Wed, 4 Jun 2014 16:06:48 -0700
Subject: [PATCH 17/32] x86: make dma_alloc_coherent() return zeroed memory if
CMA is enabled
This patchset enhances the DMA Contiguous Memory Allocator on x86.
Currently the DMA CMA is only supported with pci-nommu dma_map_ops and
furthermore it can't be enabled on x86_64. But I would like to allocate
big contiguous memory with dma_alloc_coherent() and tell it to the device
that requires it, regardless of which dma mapping implementation is
actually used in the system.
So this makes it work with swiotlb and intel-iommu dma_map_ops, too. And
this also extends "cma=" kernel parameter to specify placement constraint
by the physical address range of memory allocations. For example, CMA
allocates memory below 4GB by "cma=64M@0-4G", it is required for the
devices only supporting 32-bit addressing on 64-bit systems without iommu.
This patch (of 5):
Calling dma_alloc_coherent() with __GFP_ZERO must return zeroed memory.
But when the contiguous memory allocator (CMA) is enabled on x86 and the
memory region is allocated by dma_alloc_from_contiguous(), it doesn't
return zeroed memory. Because dma_generic_alloc_coherent() forgot to fill
the memory region with zero if it was allocated by
dma_alloc_from_contiguous()
Most implementations of dma_alloc_coherent() return zeroed memory
regardless of whether __GFP_ZERO is specified. So this fixes it by
unconditionally zeroing the allocated memory region.
Alternatively, we could fix dma_alloc_from_contiguous() to return zeroed
out memory and remove memset() from all caller of it. But we can't simply
remove the memset on arm because __dma_clear_buffer() is used there for
ensuring cache flushing and it is used in many places. Of course we can
do redundant memset in dma_alloc_from_contiguous(), but I think this patch
is less impact for fixing this problem.
Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
Cc: Marek Szyprowski <m.szyprowski@samsung.com>
Cc: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Cc: David Woodhouse <dwmw2@infradead.org>
Cc: Don Dutile <ddutile@redhat.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: Andi Kleen <andi@firstfloor.org>
Cc: Yinghai Lu <yinghai@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
(cherry picked from commit d92ef66c4f8fdf7a24736b1ab6c48d32de9bfc07)
Signed-off-by: Jim Somerville <Jim.Somerville@windriver.com>
---
arch/x86/kernel/pci-dma.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/x86/kernel/pci-dma.c b/arch/x86/kernel/pci-dma.c
index 77a4e62..c84ffe7 100644
--- a/arch/x86/kernel/pci-dma.c
+++ b/arch/x86/kernel/pci-dma.c
@@ -99,7 +99,7 @@ void *dma_generic_alloc_coherent(struct device *dev, size_t size,
dma_mask = dma_alloc_coherent_mask(dev, flag);
- flag |= __GFP_ZERO;
+ flag &= ~__GFP_ZERO;
again:
page = NULL;
/* CMA can be used only in the context which permits sleeping */
@@ -130,7 +130,7 @@ again:
return NULL;
}
-
+ memset(page_address(page), 0, size);
*dma_addr = addr;
return page_address(page);
}
--
1.8.3.1

View File

@ -1 +1 @@
mirror:Source/kernel-rt-3.10.0-1062.1.2.rt56.1025.el7.src.rpm repo:stx/downloads/kernel-rt-4.18.0-147.3.1.rt24.96.el8_1.src.rpm