Blob Blame History Raw
# We have to override the new %%install behavior because, well... the kernel is special.
%global __spec_install_pre %{___build_pre}

Summary: The Linux kernel

# % define buildid .local

# For a stable, released kernel, released_kernel should be 1. For rawhide
# and/or a kernel built from an rc or git snapshot, released_kernel should
# be 0.
%global released_kernel 1

%define rpmversion 4.5.0
%define pkgrelease 15.4.2.el7

# allow pkg_release to have configurable %{?dist} tag
%define specrelease %%SPECRELEASE%%

%define pkg_release %{pkgrelease}%{?buildid}

# The kernel tarball/base version
%define rheltarball %{rpmversion}-%{pkgrelease}

# 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.
# All should default to 1 (enabled) and be flipped to 0 (disabled)
# by later arch-specific checks.

# The following build options are enabled by default.
# Use either --without <opt> in your rpmbuild command or force values
# to 0 in here to disable them.
#
# kernel
%define with_default   %{?_without_default:   0} %{?!_without_default:   1}
# kernel-debug
%define with_debug     %{?_without_debug:     0} %{?!_without_debug:     1}
# kernel-doc
%define with_doc       %{?_without_doc:       0} %{?!_without_doc:       1}
# kernel-headers
%define with_headers   %{?_without_headers:   0} %{?!_without_headers:   1}
# perf
%define with_perf      %{?_without_perf:      0} %{?!_without_perf:      1}
# tools
%define with_tools     %{?_without_tools:     0} %{?!_without_tools:     1}
# kernel-debuginfo
%define with_debuginfo %{?_without_debuginfo: 0} %{?!_without_debuginfo: 1}
# kernel-abi-whitelists
%define with_kernel_abi_whitelists %{?_with_kernel_abi_whitelists: 0} %{?!_with_kernel_abi_whitelists: 1}
%define with_kernel_abi_whitelists 0

# Build the kernel-doc package, but don't fail the build if it botches.
# Here "true" means "continue" and "false" means "fail the build".
%if 0%{?released_kernel}
%define doc_build_fail false
%else
%define doc_build_fail true
%endif

%define rawhide_skip_docs 0
%if 0%{?rawhide_skip_docs}
%define with_doc 0
%define doc_build_fail true
%endif

# Additional options for user-friendly one-off kernel building:
#
# Only build the base kernel (--with baseonly):
%define with_baseonly  %{?_with_baseonly:     1} %{?!_with_baseonly:     0}
# Only build the debug kernel (--with dbgonly):
%define with_dbgonly   %{?_with_dbgonly:      1} %{?!_with_dbgonly:      0}

# Control whether we perform a compat. check against published ABI.
# %define with_kabichk   %{?_without_kabichk:   0} %{?!_without_kabichk:   1}
%define with_kabichk   0

# should we do C=1 builds with sparse
%define with_sparse    %{?_with_sparse:       1} %{?!_with_sparse:       0}

# Cross compile requested?
%define with_cross    %{?_with_cross:         1} %{?!_with_cross:        0}

# Set debugbuildsenabled to 1 for production (build separate debug kernels)
#  and 0 for rawhide (all kernels are debug kernels).
# See also 'make debug' and 'make release'.
%define debugbuildsenabled 1

%define signmodules 1

%define make_target bzImage

%define KVERREL %{version}-%{release}.%{_target_cpu}
%define hdrarch %{_target_cpu}
%define asmarch %{_target_cpu}
%define cross_target %{_target_cpu}

%if !%{debugbuildsenabled}
%define with_debug 0
%endif

%if !%{with_debuginfo}
%define _enable_debug_packages 0
%endif
%define debuginfodir /usr/lib/debug

# if requested, only build base kernel
%if %{with_baseonly}
%define with_debug 0
%endif

# if requested, only build debug kernel
%if %{with_dbgonly}
%define with_default 0
%define with_tools 0
%define with_perf 0
%endif

# These arches install vdso/ directories.
# %define vdso_arches %{all_x86} x86_64 ppc ppc64 s390 s390x
%define vdso_arches aarch64

# Overrides for generic default options

# don't build noarch kernels or headers (duh)
%ifarch noarch
%define with_doc 0
%define with_debug 0
%define with_default 0
%define with_headers 0
%define with_tools 0
%define with_perf 0
%define all_arch_configs kernel-%{version}-*.config
%endif

# Per-arch tweaks

%ifarch aarch64
%define asmarch arm64
%define hdrarch arm64
%define all_arch_configs kernel-%{version}-aarch64*.config
%define make_target Image.gz
%define kernel_image arch/arm64/boot/Image.gz
%define image_install_path boot
%define with_doc 0
%endif

# Should make listnewconfig fail if there's config options
# printed out?
%define listnewconfig_fail 1

# To temporarily exclude an architecture from being built, add it to
# %%nobuildarches. Do _NOT_ use the ExclusiveArch: line, because if we
# don't build kernel-headers then the new build system will no longer let
# us use the previous build of that package -- it'll just be completely AWOL.
# Which is a BadThing(tm).

# Architectures we build tools/cpupower on
# %define cpupowerarchs x86_64 ppc64
%define cpupowerarchs aarch64

#
# Three sets of minimum package version requirements in the form of Conflicts:
# to versions below the minimum
#

#
# First the general kernel 2.6 required versions as per
# Documentation/Changes
#
%define kernel_dot_org_conflicts  ppp < 2.4.3-3, isdn4k-utils < 3.2-32, nfs-utils < 1.0.7-12, e2fsprogs < 1.37-4, util-linux < 2.12, jfsutils < 1.1.7-2, reiserfs-utils < 3.6.19-2, xfsprogs < 4.5.0-3, procps < 3.2.5-6.3, oprofile < 0.9.1-2, device-mapper-libs < 1.02.63-2, mdadm < 3.2.1-5

#
# Then a series of requirements that are distribution specific, either
# because we add patches for something, or the older versions have
# problems with the newer kernel or lack certain things that make
# integration in the distro harder than needed.
#
%define package_conflicts initscripts < 7.23, udev < 063-6, iptables < 1.3.2-1, ipw2200-firmware < 2.4, iwl4965-firmware < 228.57.2, selinux-policy-targeted < 1.25.3-14, squashfs-tools < 4.0, wireless-tools < 29-3

# We moved the drm include files into kernel-headers, make sure there's
# a recent enough libdrm-devel on the system that doesn't have those.
%define kernel_headers_conflicts libdrm-devel < 2.4.0-0.15

#
# Packages that need to be installed before the kernel is, because the %%post
# scripts use them.
#
%define kernel_prereq  fileutils, module-init-tools >= 3.16-2, initscripts >= 8.11.1-1, grubby >= 8.28-2
%define initrd_prereq  dracut >= 001-7

#
# This macro does requires, provides, conflicts, obsoletes for a kernel package.
#	%%kernel_reqprovconf <subpackage>
# It uses any kernel_<subpackage>_conflicts and kernel_<subpackage>_obsoletes
# macros defined above.
#
%define kernel_reqprovconf \
Provides: kernel = %{rpmversion}-%{pkg_release}\
Provides: kernel-%{_target_cpu} = %{rpmversion}-%{pkg_release}%{?1:.%{1}}\
Provides: kernel-drm = 4.3.0\
Provides: kernel-drm-nouveau = 16\
Provides: kernel-modeset = 1\
Provides: kernel-uname-r = %{KVERREL}%{?1:.%{1}}\
Requires(pre): %{kernel_prereq}\
Requires(pre): %{initrd_prereq}\
Requires(pre): linux-firmware >= 20100806-2\
Requires(post): %{_sbindir}/new-kernel-pkg\
Requires(preun): %{_sbindir}/new-kernel-pkg\
Conflicts: %{kernel_dot_org_conflicts}\
Conflicts: %{package_conflicts}\
%{expand:%%{?kernel%{?1:_%{1}}_conflicts:Conflicts: %%{kernel%{?1:_%{1}}_conflicts}}}\
%{expand:%%{?kernel%{?1:_%{1}}_obsoletes:Obsoletes: %%{kernel%{?1:_%{1}}_obsoletes}}}\
%{expand:%%{?kernel%{?1:_%{1}}_provides:Provides: %%{kernel%{?1:_%{1}}_provides}}}\
# We can't let RPM do the dependencies automatic because it'll then pick up\
# a correct but undesirable perl dependency from the module headers which\
# isn't required for the kernel proper to function\
AutoReq: no\
AutoProv: yes\
%{nil}

Name: kernel-aarch64%{?variant}
Group: System Environment/Kernel
License: GPLv2
URL: http://www.kernel.org/
Version: %{rpmversion}
Release: %{pkg_release}
# DO NOT CHANGE THE 'ExclusiveArch' LINE TO TEMPORARILY EXCLUDE AN ARCHITECTURE BUILD.
# SET %%nobuildarches (ABOVE) INSTEAD
ExclusiveArch: aarch64
ExclusiveOS: Linux

%kernel_reqprovconf

#
# List the packages used during the kernel build
#
BuildRequires: module-init-tools, patch >= 2.5.4, bash >= 2.03, sh-utils, tar
BuildRequires: xz, findutils, gzip, m4, perl, make >= 3.78, diffutils, gawk
BuildRequires: gcc >= 3.4.2, binutils >= 2.12, redhat-rpm-config >= 9.1.0-55
BuildRequires: hostname, net-tools, bc
BuildRequires: xmlto, asciidoc
BuildRequires: openssl openssl-devel
BuildRequires: hmaccalc
%ifarch x86_64
BuildRequires: pesign >= 0.109-4
%endif
%if %{with_sparse}
BuildRequires: sparse >= 0.4.1
%endif
%if %{with_perf}
BuildRequires: elfutils-devel zlib-devel binutils-devel newt-devel python-devel perl(ExtUtils::Embed) bison
BuildRequires: audit-libs-devel
%endif
%if %{with_tools}
BuildRequires: pciutils-devel gettext
%endif
%if %{with_debuginfo}
BuildRequires: rpm-build, elfutils
%define debuginfo_args --strict-build-id -r
%endif
%ifarch s390x
# required for zfcpdump
BuildRequires: glibc-static
%endif

#cross compile make
%if %{with_cross}
%define cross_opts CROSS_COMPILE=%{cross_target}-linux-gnu-
%endif

Source0: linux-%{rpmversion}-%{pkgrelease}.tar.xz

Source1: Makefile.common

Source10: sign-modules
%define modsign_cmd %{SOURCE10}
Source11: x509.genkey
Source12: extra_certificates
# Source13: redhatsecurebootca2.cer
# Source14: redhatsecureboot003.cer

Source15: merge.pl

# %if %{with_kabichk}
# Source18: check-kabi

# Source20: Module.kabi_x86_64
# Source21: Module.kabi_ppc64
# Source22: Module.kabi_s390x

# Source23: kabi_whitelist_ppc64
# Source24: kabi_whitelist_s390x
# Source25: kabi_whitelist_x86_64
# %endif

Source30: Makefile.config

# Source50: kernel-%{version}-x86_64.config
# Source51: kernel-%{version}-x86_64-debug.config

# Source60: kernel-%{version}-ppc64.config
# Source61: kernel-%{version}-ppc64-debug.config

# Source70: kernel-%{version}-s390x.config
# Source71: kernel-%{version}-s390x-debug.config
# Source72: kernel-%{version}-s390x-kdump.config

# Source80: kernel-%{version}-arm64.config
# Source81: kernel-%{version}-arm64-debug.config

# Sources for kernel-tools
Source2000: cpupower.service
Source2001: cpupower.config
Source50: config-debug-redhat
Source51: config-arm-generic
Source52: config-generic-redhat
Source53: config-local
Source54: config-arm64
Source55: config-nodebug
Source56: config-arm64-redhat
Source57: config-nodebug-redhat
Source58: config-generic
Source59: config-debug

# empty final patch to facilitate testing of kernel patches
Patch999999: linux-kernel-test.patch

BuildRoot: %{_tmppath}/kernel-%{KVERREL}-root

%description
The kernel package contains the Linux kernel (vmlinuz), the core of any
Linux operating system.  The kernel handles the basic functions
of the operating system: memory allocation, process allocation, device
input and output, etc.


%package -n kernel-doc
Summary: Various documentation bits found in the kernel source
Group: Documentation
%description -n kernel-doc
This package contains documentation files from the kernel
source. Various bits of information about the Linux kernel and the
device drivers shipped with it are documented in these files.

You'll want to install this package if you need a reference to the
options that can be passed to Linux kernel modules at load time.


%package -n kernel-headers
Summary: Header files for the Linux kernel for use by glibc
Group: Development/System
Obsoletes: glibc-kernheaders < 3.0-46
Provides: glibc-kernheaders = 3.0-46
Provides: kernel-headers
%description -n kernel-headers
Kernel-headers includes the C header files that specify the interface
between the Linux kernel and userspace libraries and programs.  The
header files define structures and constants that are needed for
building most standard programs and are also needed for rebuilding the
glibc package.

%package -n kernel-bootwrapper
Summary: Boot wrapper files for generating combined kernel + initrd images
Group: Development/System
Requires: gzip binutils
%description -n kernel-bootwrapper
Kernel-bootwrapper contains the wrapper code which makes bootable "zImage"
files combining both kernel and initial ramdisk.

%package -n kernel-debuginfo-common-%{_target_cpu}
Summary: Kernel source files used by kernel-debuginfo packages
Group: Development/Debug
%description -n kernel-debuginfo-common-%{_target_cpu}
This package is required by kernel-debuginfo subpackages.
It provides the kernel source files common to all builds.

%if %{with_perf}
%package -n perf
Summary: Performance monitoring for the Linux kernel
Group: Development/System
License: GPLv2
%description -n perf
This package contains the perf tool, which enables performance monitoring
of the Linux kernel.

%package -n perf-debuginfo
Summary: Debug information for package perf
Group: Development/Debug
Requires: kernel-debuginfo-common-%{_target_cpu} = %{version}-%{release}
AutoReqProv: no
%description -n perf-debuginfo
This package provides debug information for the perf package.

# Note that this pattern only works right to match the .build-id
# symlinks because of the trailing nonmatching alternation and
# the leading .*, because of find-debuginfo.sh's buggy handling
# of matching the pattern against the symlinks file.
%{expand:%%global debuginfo_args %{?debuginfo_args} -p '.*%%{_bindir}/perf(\.debug)?|.*%%{_libexecdir}/perf-core/.*|XXX' -o perf-debuginfo.list}

%package -n python-perf
Summary: Python bindings for apps which will manipulate perf events
Group: Development/Libraries
%description -n python-perf
The python-perf package contains a module that permits applications
written in the Python programming language to use the interface
to manipulate perf events.

%{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}

%package -n python-perf-debuginfo
Summary: Debug information for package perf python bindings
Group: Development/Debug
Requires: kernel-debuginfo-common-%{_target_cpu} = %{version}-%{release}
AutoReqProv: no
%description -n python-perf-debuginfo
This package provides debug information for the perf python bindings.

# the python_sitearch macro should already be defined from above
%{expand:%%global debuginfo_args %{?debuginfo_args} -p '.*%%{python_sitearch}/perf.so(\.debug)?|XXX' -o python-perf-debuginfo.list}


%endif # with_perf

%if %{with_tools}

%package -n kernel-tools
Summary: Assortment of tools for the Linux kernel
Group: Development/System
License: GPLv2
# Provides:  cpupowerutils = 1:009-0.6.p1
# Obsoletes: cpupowerutils < 1:009-0.6.p1
# Provides:  cpufreq-utils = 1:009-0.6.p1
# Provides:  cpufrequtils = 1:009-0.6.p1
# Obsoletes: cpufreq-utils < 1:009-0.6.p1
# Obsoletes: cpufrequtils < 1:009-0.6.p1
# Obsoletes: cpuspeed < 1:1.5-16
Requires: kernel-tools-libs = %{version}-%{release}
Provides: kernel-tools
%description -n kernel-tools
This package contains the tools/ directory from the kernel source
and the supporting documentation.

%package -n kernel-tools-libs
Summary: Libraries for the kernels-tools
Group: Development/System
License: GPLv2
Provides: kernel-tools-lib
%description -n kernel-tools-libs
This package contains the libraries built from the tools/ directory
from the kernel source.

%package -n kernel-tools-libs-devel
Summary: Assortment of tools for the Linux kernel
Group: Development/System
License: GPLv2
Requires: kernel-tools = %{version}-%{release}
# Provides:  cpupowerutils-devel = 1:009-0.6.p1
# Obsoletes: cpupowerutils-devel < 1:009-0.6.p1
Requires: kernel-tools-libs = %{version}-%{release}
Provides: kernel-tools-devel
%description -n kernel-tools-libs-devel
This package contains the development files for the tools/ directory from
the kernel source.

%package -n kernel-tools-debuginfo
Summary: Debug information for package kernel-tools
Group: Development/Debug
Requires: kernel-debuginfo-common-%{_target_cpu} = %{version}-%{release}
Provides: kernel-tools-debuginfo
AutoReqProv: no
%description -n kernel-tools-debuginfo
This package provides debug information for package kernel-tools.

# Note that this pattern only works right to match the .build-id
# symlinks because of the trailing nonmatching alternation and
# the leading .*, because of find-debuginfo.sh's buggy handling
# of matching the pattern against the symlinks file.
%{expand:%%global debuginfo_args %{?debuginfo_args} -p '.*%%{_bindir}/centrino-decode(\.debug)?|.*%%{_bindir}/powernow-k8-decode(\.debug)?|.*%%{_bindir}/cpupower(\.debug)?|.*%%{_libdir}/libcpupower.*|.*%%{_libdir}/libcpupower.*|.*%%{_bindir}/turbostat(\.debug)?|.*%%{_bindir}/x86_energy_perf_policy(\.debug)?|XXX' -o kernel-tools-debuginfo.list}

%endif # with_tools

#
# This macro creates a kernel-<subpackage>-debuginfo package.
#	%%kernel_debuginfo_package <subpackage>
#
%define kernel_debuginfo_package() \
%package -n kernel-%{?1:%{1}-}debuginfo\
Summary: Debug information for package kernel%{?1:-%{1}}\
Group: Development/Debug\
Requires: kernel-debuginfo-common-%{_target_cpu} = %{version}-%{release}\
Provides: kernel%{?1:-%{1}}-debuginfo-%{_target_cpu} = %{version}-%{release}\
AutoReqProv: no\
%description -n kernel-%{?1:%{1}-}debuginfo\
This package provides debug information for package kernel%{?1:-%{1}}.\
This is required to use SystemTap with kernel%{?1:-%{1}}-%{KVERREL}.\
%{expand:%%global debuginfo_args %{?debuginfo_args} -p '/.*/%%{KVERREL}%{?1:\.%{1}}/.*|/.*%%{KVERREL}%{?1:\.%{1}}(\.debug)?' -o debuginfo%{?1}.list}\
%{nil}

#
# This macro creates a kernel-<subpackage>-devel package.
#	%%kernel_devel_package <subpackage> <pretty-name>
#
%define kernel_devel_package() \
%package -n kernel%{?1:-%{1}}-devel\
Summary: Development package for building kernel modules to match the %{?2:%{2} }kernel\
Group: System Environment/Kernel\
Provides: kernel%{?1:-%{1}}-devel-%{_target_cpu} = %{version}-%{release}\
Provides: kernel-devel-%{_target_cpu} = %{version}-%{release}%{?1:.%{1}}\
Provides: kernel-devel = %{version}-%{release}%{?1:.%{1}}\
Provides: kernel-devel-uname-r = %{KVERREL}%{?1:.%{1}}\
AutoReqProv: no\
Requires(pre): /usr/bin/find\
Requires: perl\
%description -n kernel%{?1:-%{1}}-devel\
This package provides kernel headers and makefiles sufficient to build modules\
against the %{?2:%{2} }kernel package.\
%{nil}

#
# This macro creates a kernel-<subpackage> and its -devel and -debuginfo too.
#	%%define variant_summary The Linux kernel compiled for <configuration>
#	%%kernel_variant_package [-n <pretty-name>] <subpackage>
#
%define kernel_variant_package(n:) \
%package -n kernel-%1\
Summary: %{variant_summary}\
Group: System Environment/Kernel\
%kernel_reqprovconf\
%{expand:%%kernel_devel_package %1 %{!?-n:%1}%{?-n:%{-n*}}}\
%{expand:%%kernel_debuginfo_package %1}\
%{nil}

%package -n kernel
Summary: The Linux Kernel
Group: System Environment/Kernel
%kernel_reqprovconf
%description -n kernel
The kernel package contains the Linux kernel (vmlinuz), the core of any
Linux operating system.  The kernel handles the basic functions
of the operating system: memory allocation, process allocation, device
input and output, etc.

# First the auxiliary packages of the main kernel package.
%kernel_devel_package
%kernel_debuginfo_package


# Now, each variant package.

%define variant_summary The Linux kernel compiled with extra debugging enabled
%kernel_variant_package debug
%description -n kernel-debug
The kernel package contains the Linux kernel (vmlinuz), the core of any
Linux operating system.  The kernel handles the basic functions
of the operating system:  memory allocation, process allocation, device
input and output, etc.

This variant of the kernel has numerous debugging options enabled.
It should only be installed when trying to gather additional information
on kernel bugs, as some of these options impact performance noticably.

%prep
# do a few sanity-checks for --with *only builds
%if %{with_baseonly}
%if !%{with_default}
echo "Cannot build --with baseonly, default kernel build is disabled"
exit 1
%endif
%endif

# more sanity checking; do it quietly
if [ "%{patches}" != "%%{patches}" ] ; then
  for patch in %{patches} ; do
    if [ ! -f $patch ] ; then
      echo "ERROR: Patch  ${patch##/*/}  listed in specfile but is missing"
      exit 1
    fi
  done
fi 2>/dev/null

patch_command='patch -p1 -F1 -s'
ApplyPatch()
{
  local patch=$1
  shift
  if [ ! -f $RPM_SOURCE_DIR/$patch ]; then
    exit 1
  fi
  if ! grep -E "^Patch[0-9]+: $patch\$" %{_specdir}/${RPM_PACKAGE_NAME%%%%%{?variant}}.spec ; then
    if [ "${patch:0:8}" != "patch-3." ] ; then
      echo "ERROR: Patch  $patch  not listed as a source patch in specfile"
      exit 1
    fi
  fi 2>/dev/null
  case "$patch" in
  *.bz2) bunzip2 < "$RPM_SOURCE_DIR/$patch" | $patch_command ${1+"$@"} ;;
  *.gz) gunzip < "$RPM_SOURCE_DIR/$patch" | $patch_command ${1+"$@"} ;;
  *) $patch_command ${1+"$@"} < "$RPM_SOURCE_DIR/$patch" ;;
  esac
}

# don't apply patch if it's empty
ApplyOptionalPatch()
{
  local patch=$1
  shift
  if [ ! -f $RPM_SOURCE_DIR/$patch ]; then
    exit 1
  fi
  local C=$(wc -l $RPM_SOURCE_DIR/$patch | awk '{print $1}')
  if [ "$C" -gt 9 ]; then
    ApplyPatch $patch ${1+"$@"}
  fi
}

if [ ! -d kernel-%{rheltarball}/vanilla-%{rheltarball}/ ]; then
	rm -f pax_global_header;
%setup -q -n kernel-%{rheltarball} -c
	mv linux-%{rheltarball} vanilla-%{rheltarball};
else
	cd kernel-%{rheltarball}/;
fi

if [ -d linux-%{KVERREL} ]; then
	# Just in case we ctrl-c'd a prep already
	rm -rf deleteme.%{_target_cpu}
	# Move away the stale away, and delete in background.
	mv linux-%{KVERREL} deleteme.%{_target_cpu}
	rm -rf deleteme.%{_target_cpu} &
fi

cp -rl vanilla-%{rheltarball} linux-%{KVERREL}
cd linux-%{KVERREL}

# Drop some necessary files from the source dir into the buildroot
cp $RPM_SOURCE_DIR/config-* .
cp %{SOURCE15} .

# Dynamically generate kernel .config files from config-* files
make -f %{SOURCE30} VERSION=%{version} configs

ApplyOptionalPatch linux-kernel-test.patch

# Any further pre-build tree manipulations happen here.

chmod +x scripts/checkpatch.pl

# This Prevents scripts/setlocalversion from mucking with our version numbers.
touch .scmversion

# only deal with configs if we are going to build for the arch
%ifnarch %nobuildarches

mkdir configs

# Remove configs not for the buildarch
for cfg in kernel-%{version}-*.config; do
  if [ `echo %{all_arch_configs} | grep -c $cfg` -eq 0 ]; then
    rm -f $cfg
  fi
done

%if !%{debugbuildsenabled}
rm -f kernel-%{version}-*debug.config
%endif

%define make make %{?cross_opts}

# now run oldconfig over all the config files
for i in *.config
do
  mv $i .config
  Arch=`head -1 .config | cut -b 3-`
  %{make} ARCH=$Arch listnewconfig | grep -E '^CONFIG_' >.newoptions || true
%if %{listnewconfig_fail}
  if [ -s .newoptions ]; then
    cat .newoptions
    exit 1
  fi
%endif
  rm -f .newoptions
  %{make} ARCH=$Arch oldnoconfig
  echo "# $Arch" > configs/$i
  cat .config >> configs/$i
done
# end of kernel config
%endif

# get rid of unwanted files resulting from patch fuzz
find . \( -name "*.orig" -o -name "*~" \) -exec rm -f {} \; >/dev/null

# remove unnecessary SCM files
find . -name .gitignore -exec rm -f {} \; >/dev/null

cd ..

###
### build
###
%build

%if %{with_sparse}
%define sparse_mflags	C=1
%endif

%if %{with_debuginfo}
# This override tweaks the kernel makefiles so that we run debugedit on an
# object before embedding it.  When we later run find-debuginfo.sh, it will
# run debugedit again.  The edits it does change the build ID bits embedded
# in the stripped object, but repeating debugedit is a no-op.  We do it
# beforehand to get the proper final build ID bits into the embedded image.
# This affects the vDSO images in vmlinux, and the vmlinux image in bzImage.
export AFTER_LINK=\
'sh -xc "/usr/lib/rpm/debugedit -b $$RPM_BUILD_DIR -d /usr/src/debug \
    				-i $@ > $@.id"'
%endif

cp_vmlinux()
{
  eu-strip --remove-comment -o "$2" "$1"
}

BuildKernel() {
    MakeTarget=$1
    KernelImage=$2
    Flavour=$3
    InstallName=${4:-vmlinuz}

    # Pick the right config file for the kernel we're building
    Config=kernel-%{version}-%{_target_cpu}${Flavour:+-${Flavour}}.config
    DevelDir=/usr/src/kernels/%{KVERREL}${Flavour:+.${Flavour}}

    # When the bootable image is just the ELF kernel, strip it.
    # We already copy the unstripped file into the debuginfo package.
    if [ "$KernelImage" = vmlinux ]; then
      CopyKernel=cp_vmlinux
    else
      CopyKernel=cp
    fi

    KernelVer=%{version}-%{release}.%{_target_cpu}${Flavour:+.${Flavour}}
    echo BUILDING A KERNEL FOR ${Flavour} %{_target_cpu}...

    %if 0%{?stable_update}
    # make sure SUBLEVEL is incremented on a stable release.  Sigh 3.x.
    perl -p -i -e "s/^SUBLEVEL.*/SUBLEVEL = %{?stablerev}/" Makefile
    %endif

    # make sure EXTRAVERSION says what we want it to say
    perl -p -i -e "s/^EXTRAVERSION.*/EXTRAVERSION = -%{release}.%{_target_cpu}${Flavour:+.${Flavour}}/" Makefile

    # if pre-rc1 devel kernel, must fix up PATCHLEVEL for our versioning scheme
    %if !0%{?rcrev}
    %if 0%{?gitrev}
    perl -p -i -e 's/^PATCHLEVEL.*/PATCHLEVEL = %{upstream_sublevel}/' Makefile
    %endif
    %endif

    # and now to start the build process

    %{make} -s mrproper

    cp %{SOURCE11} certs/	# x509.genkey
    cp %{SOURCE12} certs/	# extra_certificates

    cp configs/$Config .config

    Arch=`head -1 .config | cut -b 3-`
    echo USING ARCH=$Arch

    %{make} -s ARCH=$Arch oldnoconfig >/dev/null
    %{make} -s ARCH=$Arch V=1 %{?_smp_mflags} $MakeTarget %{?sparse_mflags}
    %{make} -s ARCH=$Arch V=1 %{?_smp_mflags} modules %{?sparse_mflags} || exit 1

    # from f20 kernel.spec for aarch64; build dtb for now...
%ifarch aarch64
    %{make} -s ARCH=$Arch V=1 dtbs
    mkdir -p $RPM_BUILD_ROOT/%{image_install_path}/dtb-$KernelVer
    install -m 644 arch/$Arch/boot/dts/*/*.dtb $RPM_BUILD_ROOT/%{image_install_path}/dtb-$KernelVer/
    rm -f arch/$Arch/boot/dts/*/*.dtb
%endif

    # Start installing the results
%if %{with_debuginfo}
    mkdir -p $RPM_BUILD_ROOT%{debuginfodir}/boot
    mkdir -p $RPM_BUILD_ROOT%{debuginfodir}/%{image_install_path}
%endif
    mkdir -p $RPM_BUILD_ROOT/%{image_install_path}
    install -m 644 .config $RPM_BUILD_ROOT/boot/config-$KernelVer
    install -m 644 System.map $RPM_BUILD_ROOT/boot/System.map-$KernelVer

    # We estimate the size of the initramfs because rpm needs to take this size
    # into consideration when performing disk space calculations. (See bz #530778)
    dd if=/dev/zero of=$RPM_BUILD_ROOT/boot/initramfs-$KernelVer.img bs=1M count=20

    if [ -f arch/$Arch/boot/zImage.stub ]; then
      cp arch/$Arch/boot/zImage.stub $RPM_BUILD_ROOT/%{image_install_path}/zImage.stub-$KernelVer || :
    fi
# EFI SecureBoot signing, x86_64-only
%ifarch x86_64
    %pesign -s -i $KernelImage -o $KernelImage.signed -a %{SOURCE13} -c %{SOURCE14} -n redhatsecureboot003
    mv $KernelImage.signed $KernelImage
%endif
    $CopyKernel $KernelImage \
    		$RPM_BUILD_ROOT/%{image_install_path}/$InstallName-$KernelVer
    chmod 755 $RPM_BUILD_ROOT/%{image_install_path}/$InstallName-$KernelVer

    # hmac sign the kernel for FIPS
    echo "Creating hmac file: $RPM_BUILD_ROOT/%{image_install_path}/.vmlinuz-$KernelVer.hmac"
    ls -l $RPM_BUILD_ROOT/%{image_install_path}/$InstallName-$KernelVer
    sha512hmac $RPM_BUILD_ROOT/%{image_install_path}/$InstallName-$KernelVer | sed -e "s,$RPM_BUILD_ROOT,," > $RPM_BUILD_ROOT/%{image_install_path}/.vmlinuz-$KernelVer.hmac;

    mkdir -p $RPM_BUILD_ROOT/lib/modules/$KernelVer
    mkdir -p $RPM_BUILD_ROOT/lib/modules/$KernelVer/kernel
        # Override $(mod-fw) because we don't want it to install any firmware
        # we'll get it from the linux-firmware package and we don't want conflicts
        %{make} -s ARCH=$Arch INSTALL_MOD_PATH=$RPM_BUILD_ROOT modules_install KERNELRELEASE=$KernelVer mod-fw=
%ifarch %{vdso_arches}
    %{make} -s ARCH=$Arch INSTALL_MOD_PATH=$RPM_BUILD_ROOT vdso_install KERNELRELEASE=$KernelVer
    if [ ! -s ldconfig-kernel.conf ]; then
      echo > ldconfig-kernel.conf "\
# Placeholder file, no vDSO hwcap entries used in this kernel."
    fi
    %{__install} -D -m 444 ldconfig-kernel.conf \
        $RPM_BUILD_ROOT/etc/ld.so.conf.d/kernel-$KernelVer.conf
%endif

    # And save the headers/makefiles etc for building modules against
    #
    # This all looks scary, but the end result is supposed to be:
    # * all arch relevant include/ files
    # * all Makefile/Kconfig files
    # * all script/ files

    rm -f $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
    rm -f $RPM_BUILD_ROOT/lib/modules/$KernelVer/source
    mkdir -p $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
    (cd $RPM_BUILD_ROOT/lib/modules/$KernelVer ; ln -s build source)
    # dirs for additional modules per module-init-tools, kbuild/modules.txt
    mkdir -p $RPM_BUILD_ROOT/lib/modules/$KernelVer/extra
    mkdir -p $RPM_BUILD_ROOT/lib/modules/$KernelVer/updates
    # first copy everything
    cp --parents `find  -type f -name "Makefile*" -o -name "Kconfig*"` $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
    cp Module.symvers $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
    cp System.map $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
    if [ -s Module.markers ]; then
      cp Module.markers $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
    fi

%if %{with_kabichk}
    # 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

    echo "**** kABI checking is enabled in kernel SPEC file. ****"
    chmod 0755 $RPM_SOURCE_DIR/check-kabi
    if [ -e $RPM_SOURCE_DIR/Module.kabi_%{_target_cpu}$Flavour ]; then
        cp $RPM_SOURCE_DIR/Module.kabi_%{_target_cpu}$Flavour $RPM_BUILD_ROOT/Module.kabi
        $RPM_SOURCE_DIR/check-kabi -k $RPM_BUILD_ROOT/Module.kabi -s Module.symvers || exit 1
        rm $RPM_BUILD_ROOT/Module.kabi # for now, don't keep it around.
    else
        echo "**** NOTE: Cannot find reference Module.kabi file. ****"
    fi
%endif %{with_kabichk}

    # then drop all but the needed Makefiles/Kconfig files
    rm -rf $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/Documentation
    rm -rf $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/scripts
    rm -rf $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/include
    cp .config $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
    cp -a scripts $RPM_BUILD_ROOT/lib/modules/$KernelVer/build
    if [ -d arch/$Arch/scripts ]; then
      cp -a arch/$Arch/scripts $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/arch/%{_arch} || :
    fi
    if [ -f arch/$Arch/*lds ]; then
      cp -a arch/$Arch/*lds $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/arch/%{_arch}/ || :
    fi
    rm -f $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/scripts/*.o
    rm -f $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/scripts/*/*.o
%ifarch ppc64
    cp -a --parents arch/powerpc/lib/crtsavres.[So] $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/
%endif
    if [ -d arch/%{asmarch}/include ]; then
      cp -a --parents arch/%{asmarch}/include $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/
    fi
%ifarch aarch64
    # some arch/arm64 header files refer to arch/arm, so include them too
    cp -a --parents arch/arm/include $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/
%endif
    cp -a include $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/include

    # Make sure the Makefile and version.h have a matching timestamp so that
    # external modules can be built
    touch -r $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/Makefile $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/include/generated/uapi/linux/version.h
    touch -r $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/.config $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/include/generated/autoconf.h
    # Copy .config to include/config/auto.conf so "make prepare" is unnecessary.
    cp $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/.config $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/include/config/auto.conf

%if %{with_debuginfo}
    if test -s vmlinux.id; then
      cp vmlinux.id $RPM_BUILD_ROOT/lib/modules/$KernelVer/build/vmlinux.id
    else
      echo >&2 "*** ERROR *** no vmlinux build ID! ***"
      exit 1
    fi

    #
    # save the vmlinux file for kernel debugging into the kernel-debuginfo rpm
    #
    mkdir -p $RPM_BUILD_ROOT%{debuginfodir}/lib/modules/$KernelVer
    cp vmlinux $RPM_BUILD_ROOT%{debuginfodir}/lib/modules/$KernelVer
%endif

    find $RPM_BUILD_ROOT/lib/modules/$KernelVer -name "*.ko" -type f >modnames

    # mark modules executable so that strip-to-file can strip them
    xargs --no-run-if-empty chmod u+x < modnames

    # Generate a list of modules for block and networking.

    grep -F /drivers/ modnames | xargs --no-run-if-empty nm -upA |
    sed -n 's,^.*/\([^/]*\.ko\):  *U \(.*\)$,\1 \2,p' > drivers.undef

    collect_modules_list()
    {
      sed -r -n -e "s/^([^ ]+) \\.?($2)\$/\\1/p" drivers.undef |
      LC_ALL=C sort -u > $RPM_BUILD_ROOT/lib/modules/$KernelVer/modules.$1
      if [ ! -z "$3" ]; then
        sed -r -e "/^($3)\$/d" -i $RPM_BUILD_ROOT/lib/modules/$KernelVer/modules.$1
      fi
    }

    collect_modules_list networking \
    			 'register_netdev|ieee80211_register_hw|usbnet_probe|phy_driver_register|rt2x00(pci|usb)_probe|register_netdevice'
    collect_modules_list block \
			 'ata_scsi_ioctl|scsi_add_host|scsi_add_host_with_dma|blk_alloc_queue|blk_init_queue|register_mtd_blktrans|scsi_esp_register|scsi_register_device_handler|blk_queue_physical_block_size|ahci_platform_get_resources' 'pktcdvd.ko|dm-mod.ko|ahci_platform.ko|ahci_xgene.ko'
    collect_modules_list drm \
    			 'drm_open|drm_init'
    collect_modules_list modesetting \
    			 'drm_crtc_init'

    # detect missing or incorrect license tags
    rm -f modinfo
    while read i
    do
      echo -n "${i#$RPM_BUILD_ROOT/lib/modules/$KernelVer/} " >> modinfo
      /sbin/modinfo -l $i >> modinfo
    done < modnames

    grep -E -v \
    	  'GPL( v2)?$|Dual BSD/GPL$|Dual MPL/GPL$|GPL and additional rights$' \
	  modinfo && exit 1

    rm -f modinfo modnames

    # Save off the .tmp_versions/ directory.  We'll use it in the
    # __debug_install_post macro below to sign the right things
    # Also save the signing keys so we actually sign the modules with the
    # right key.
%if %{signmodules}
    cp -r .tmp_versions .tmp_versions.sign${Flavour:+.${Flavour}}
    cp certs/signing_key.pem signing_key.priv.sign${Flavour:+.${Flavour}}
    cp certs/signing_key.x509 signing_key.x509.sign${Flavour:+.${Flavour}}
%endif

    # remove files that will be auto generated by depmod at rpm -i time
    for i in alias alias.bin builtin.bin ccwmap dep dep.bin ieee1394map inputmap isapnpmap ofmap pcimap seriomap symbols symbols.bin usbmap
    do
      rm -f $RPM_BUILD_ROOT/lib/modules/$KernelVer/modules.$i
    done

    # Move the devel headers out of the root file system
    mkdir -p $RPM_BUILD_ROOT/usr/src/kernels
    mv $RPM_BUILD_ROOT/lib/modules/$KernelVer/build $RPM_BUILD_ROOT/$DevelDir
    ln -sf $DevelDir $RPM_BUILD_ROOT/lib/modules/$KernelVer/build

    # prune junk from kernel-devel
    find $RPM_BUILD_ROOT/usr/src/kernels -name ".*.cmd" -exec rm -f {} \;
}

###
# DO it...
###

# prepare directories
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT/boot
mkdir -p $RPM_BUILD_ROOT%{_libexecdir}

cd linux-%{KVERREL}

%if %{with_default}
BuildKernel %make_target %kernel_image
%endif

%if %{with_debug}
BuildKernel %make_target %kernel_image debug
%endif

%global perf_make \
  make %{?_smp_mflags} -C tools/perf -s V=1 WERROR=0 NO_LIBUNWIND=1 HAVE_CPLUS_DEMANGLE=1 NO_GTK2=1 NO_LIBNUMA=1 NO_STRLCPY=1 prefix=%{_prefix}
%if %{with_perf}
# perf
%{perf_make} all
%{perf_make} man || %{doc_build_fail}
%endif

%if %{with_tools}
%ifarch %{cpupowerarchs}
# cpupower
# make sure version-gen.sh is executable.
chmod +x tools/power/cpupower/utils/version-gen.sh
%{make} %{?_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
%endif

%if %{with_doc}
# Make the HTML and man pages.
make htmldocs mandocs || %{doc_build_fail}

# sometimes non-world-readable files sneak into the kernel source tree
chmod -R a=rX Documentation
find Documentation -type d | xargs chmod u+w
%endif

# In the modsign case, we do 3 things.  1) We check the "flavour" and hard
# code the value in the following invocations.  This is somewhat sub-optimal
# but we're doing this inside of an RPM macro and it isn't as easy as it
# could be because of that.  2) We restore the .tmp_versions/ directory from
# the one we saved off in BuildKernel above.  This is to make sure we're
# signing the modules we actually built/installed in that flavour.  3) We
# grab the arch and invoke 'make modules_sign' and the mod-extra-sign.sh
# commands to actually sign the modules.
#
# We have to do all of those things _after_ find-debuginfo runs, otherwise
# that will strip the signature off of the modules.
#
# Finally, pick a module at random and check that it's signed and fail the build
# if it isn't.

%define __modsign_install_post \
  if [ "%{signmodules}" -eq "1" ]; then \
  if [ "%{with_debug}" -ne "0" ]; then \
    Arch=`head -1 configs/kernel-%{version}-%{_target_cpu}-debug.config | cut -b 3-` \
    rm -rf .tmp_versions $RPM_BUILD_ROOT/usr/share/perf-core/strace/groups/file \
    mv .tmp_versions.sign.debug .tmp_versions \
    mv signing_key.priv.sign.debug signing_key.priv \
    mv signing_key.x509.sign.debug signing_key.x509 \
    %{modsign_cmd} $RPM_BUILD_ROOT/lib/modules/%{KVERREL}.debug || exit 1 \
  fi \
    if [ "%{with_default}" -ne "0" ]; then \
    Arch=`head -1 configs/kernel-%{version}-%{_target_cpu}.config | cut -b 3-` \
    rm -rf .tmp_versions $RPM_BUILD_ROOT/usr/share/perf-core/strace/groups/file \
    mv .tmp_versions.sign .tmp_versions \
    mv signing_key.priv.sign signing_key.priv \
    mv signing_key.x509.sign signing_key.x509 \
    %{modsign_cmd} $RPM_BUILD_ROOT/lib/modules/%{KVERREL} || exit 1 \
  fi \
  fi \
%{nil}

###
### Special hacks for debuginfo subpackages.
###

# This macro is used by %%install, so we must redefine it before that.
%define debug_package %{nil}

%if %{with_debuginfo}

%define __debug_install_post \
  /usr/lib/rpm/find-debuginfo.sh %{debuginfo_args} %{_builddir}/%{?buildsubdir}\
%{nil}

%ifnarch noarch
%global __debug_package 1
%files -f debugfiles.list -n kernel-debuginfo-common-%{_target_cpu}
%defattr(-,root,root)
%endif

%endif

#
# Disgusting hack alert! We need to ensure we sign modules *after* all
# invocations of strip occur, which is in __debug_install_post if
# find-debuginfo.sh runs, and __os_install_post if not.
#
%define __spec_install_post \
  %{?__debug_package:%{__debug_install_post}}\
  %{__arch_install_post}\
  %{__os_install_post}\
  %{__modsign_install_post}

###
### install
###

# pull in some annoying files
#%files /usr/share/perf-core/strace/groups/file

%install

cd linux-%{KVERREL}

%if %{with_doc}
docdir=$RPM_BUILD_ROOT%{_datadir}/doc/kernel-doc-%{rpmversion}
man9dir=$RPM_BUILD_ROOT%{_datadir}/man/man9

# copy the source over
mkdir -p $docdir
tar -f - --exclude=man --exclude='.*' -c Documentation | tar xf - -C $docdir

# Install man pages for the kernel API.
mkdir -p $man9dir
find Documentation/DocBook/man -name '*.9.gz' -print0 |
xargs -0 --no-run-if-empty %{__install} -m 444 -t $man9dir $m
ls $man9dir | grep -q '' || > $man9dir/BROKEN
%endif # with_doc

# We have to do the headers install before the tools install because the
# kernel headers_install will remove any header files in /usr/include that
# it doesn't install itself.

%if %{with_headers}
# Install kernel headers
%{make} ARCH=%{hdrarch} INSTALL_HDR_PATH=$RPM_BUILD_ROOT/usr headers_install

# Do headers_check but don't die if it fails.
%{make} ARCH=%{hdrarch} INSTALL_HDR_PATH=$RPM_BUILD_ROOT/usr headers_check \
     > hdrwarnings.txt || :
if grep -q exist hdrwarnings.txt; then
   sed s:^$RPM_BUILD_ROOT/usr/include/:: hdrwarnings.txt
   # Temporarily cause a build failure if header inconsistencies.
   # exit 1
fi

find $RPM_BUILD_ROOT/usr/include \
     \( -name .install -o -name .check -o \
     	-name ..install.cmd -o -name ..check.cmd \) | xargs rm -f

%endif

%if %{with_kernel_abi_whitelists}
# kabi directory
INSTALL_KABI_PATH=$RPM_BUILD_ROOT/lib/modules/kabi-rhel70
mkdir -p $INSTALL_KABI_PATH

# install kabi whitelists
cp %{SOURCE23} %{SOURCE24} %{SOURCE25} $INSTALL_KABI_PATH
%endif  # with_kernel_abi_whitelists

%if %{with_perf}
# perf tool binary and supporting scripts/binaries
%{perf_make} DESTDIR=$RPM_BUILD_ROOT install-bin try-install-man
#remove the 'trace' symlink
rm -f %{buildroot}%{_bindir}/trace
# remove the perf-tips
rm -rf %{buildroot}%{_docdir}/perf-tip


# perf-python extension
%{perf_make} DESTDIR=$RPM_BUILD_ROOT install-python_ext

# perf man pages (note: implicit rpm magic compresses them later)
%{perf_make} DESTDIR=$RPM_BUILD_ROOT install-man || %{doc_build_fail}
%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
%endif

%endif

###
### clean
###

%clean
rm -rf $RPM_BUILD_ROOT

###
### scripts
###

%if %{with_tools}
%post -n kernel-tools
/sbin/ldconfig

%postun -n kernel-tools
/sbin/ldconfig
%endif

# This macro defines a %%posttrans script for a kernel package.
#	%%kernel_variant_posttrans [<subpackage>]
# More text can follow to go at the end of this variant's %%post.
#
%define kernel_variant_posttrans() \
%{expand:%%posttrans -n kernel%{?1:-%{1}}}\
%{_sbindir}/new-kernel-pkg --package kernel%{?-v:-%{-v*}} --mkinitrd --dracut --depmod --update %{KVERREL}%{?-v:.%{-v*}} || exit $?\
%{_sbindir}/new-kernel-pkg --package kernel%{?1:-%{1}} --rpmposttrans %{KVERREL}%{?1:.%{1}} || exit $?\
%{nil}

#
# This macro defines a %%post script for a kernel package and its devel package.
#	%%kernel_variant_post [-v <subpackage>]
# More text can follow to go at the end of this variant's %%post.
#
%define kernel_variant_post(v:) \
%{expand:%%kernel_variant_posttrans %{?-v*}}\
%{expand:%%post -n kernel%{?-v:-%{-v*}}}\
%{expand:\
%{_sbindir}/new-kernel-pkg --package kernel%{?-v:-%{-v*}} --install %{KVERREL}%{?-v:.%{-v*}} || exit $?\
}\
%{nil}

#
# This macro defines a %%preun script for a kernel package.
#	%%kernel_variant_preun <subpackage>
#
%define kernel_variant_preun() \
%{expand:%%preun -n kernel%{?1:-%{1}}}\
%{_sbindir}/new-kernel-pkg --rminitrd --rmmoddep --remove %{KVERREL}%{?1:.%{1}} || exit $?\
%{nil}

%kernel_variant_preun
%kernel_variant_post 

%kernel_variant_preun debug
%kernel_variant_post -v debug

if [ -x /sbin/ldconfig ]
then
    /sbin/ldconfig -X || exit $?
fi

###
### file lists
###

%if %{with_headers}
%files -n kernel-headers
%defattr(-,root,root)
/usr/include/*
%endif

# only some architecture builds need kernel-doc
%if %{with_doc}
%files -n kernel-doc
%defattr(-,root,root)
%{_datadir}/doc/kernel-doc-%{rpmversion}/Documentation/*
%dir %{_datadir}/doc/kernel-doc-%{rpmversion}/Documentation
%dir %{_datadir}/doc/kernel-doc-%{rpmversion}
%{_datadir}/man/man9/*
%endif

%if %{with_kernel_abi_whitelists}
%files -n kernel-abi-whitelists
%defattr(-,root,root,-)
/lib/modules/kabi-*
%endif

%if %{with_perf}
%files -n perf
%defattr(-,root,root)
%{_bindir}/perf
%dir %{_libexecdir}/perf-core
%{_libexecdir}/perf-core/*
%{_datadir}/perf-core/*
%{_mandir}/man[1-8]/perf*
%{_sysconfdir}/bash_completion.d/perf

%files -n python-perf
%defattr(-,root,root)
%{python_sitearch}

%if %{with_debuginfo}
%files -f perf-debuginfo.list -n perf-debuginfo
%defattr(-,root,root)

%files -f python-perf-debuginfo.list -n python-perf-debuginfo
%defattr(-,root,root)
%endif
%endif # with_perf

%if %{with_tools}
%files -n kernel-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

%if %{with_debuginfo}
%files -f kernel-tools-debuginfo.list -n kernel-tools-debuginfo
%defattr(-,root,root)
%endif

%ifarch %{cpupowerarchs}
%files -n kernel-tools-libs
%defattr(-,root,root)
%{_libdir}/libcpupower.so.0
%{_libdir}/libcpupower.so.0.0.0

%files -n kernel-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.
%define elf_image_install_path %{?kernel_image_elf:%{image_install_path}}

#
# This macro defines the %%files sections for a kernel package
# and its devel and debuginfo packages.
#	%%kernel_variant_files [-k vmlinux] <condition> <subpackage>
#
%define kernel_variant_files(k:) \
%if %{1}\
%{expand:%%files -n %{2}}\
%defattr(-,root,root)\
/%{image_install_path}/%{?-k:%{-k*}}%{!?-k:vmlinuz}-%{KVERREL}%{?3:.%{3}}\
/%{image_install_path}/.vmlinuz-%{KVERREL}%{?3:.%{3}}.hmac \
%ifarch aarch64\
/%{image_install_path}/dtb-%{KVERREL}%{?3:.%{3}} \
%endif\
%attr(600,root,root) /boot/System.map-%{KVERREL}%{?3:.%{3}}\
%if %{with_kabichk}\
/boot/symvers-%{KVERREL}%{?3:.%{3}}.gz\
%endif\
/boot/config-%{KVERREL}%{?3:.%{3}}\
%dir /lib/modules/%{KVERREL}%{?3:.%{3}}\
/lib/modules/%{KVERREL}%{?3:.%{3}}/kernel\
/lib/modules/%{KVERREL}%{?3:.%{3}}/build\
/lib/modules/%{KVERREL}%{?3:.%{3}}/source\
/lib/modules/%{KVERREL}%{?3:.%{3}}/extra\
/lib/modules/%{KVERREL}%{?3:.%{3}}/updates\
%ifarch %{vdso_arches}\
/lib/modules/%{KVERREL}%{?3:.%{3}}/vdso\
/etc/ld.so.conf.d/kernel-%{KVERREL}%{?3:.%{3}}.conf\
%endif\
/lib/modules/%{KVERREL}%{?3:.%{3}}/modules.*\
%ghost /boot/initramfs-%{KVERREL}%{?3:.%{3}}.img\
%{expand:%%files -n %{?2:%{2}-}devel}\
%defattr(-,root,root)\
/usr/src/kernels/%{KVERREL}%{?3:.%{3}}\
%if %{with_debuginfo}\
%ifnarch noarch\
%{expand:%%files -f debuginfo%{?3}.list -n %{?2:%{2}-}debuginfo}\
%defattr(-,root,root)\
%endif\
%endif\
%endif\
%{nil}

%kernel_variant_files %{with_default} kernel
%kernel_variant_files %{with_debug} kernel-debug debug

%changelog
* Wed Mar 22 2017 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-15.4.2.el7]
- [redhat] Release 7.3.4 z-stream (Mark Langsdorf)
- arm64: KVM: pmu: Fix AArch32 cycle counter access (Wei Huang) [1432549]
- tty: n_hdlc: get rid of racy n_hdlc.tbuf (Mark Langsdorf) [1431127]
- TTY: n_hdlc, fix lockdep false positive (Mark Langsdorf) [1431127]

* Thu Feb 16 2017 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-15.2.1.el7]
- [redhat] Shift numbering to -15.2.X for RHELSA 7.3.2 z-stream (Mark Langsdorf)
- redhat: config: arm64: Configure mlx5 for Ethernet (Christopher Covington) [1413108]
- arm64: Workaround Falkor erratum E1009 (Christopher Covington) [1421765]
- arm64: Workaround Falkor erratum E1003 (Christopher Covington) [1421765]
- arm64: Define Qualcomm Technologies ARMv8 CPU (Christopher Covington) [1421765]
- net: add recursion limit to GRO (Torez Smith) [1422645]
- mm: remove gup_flags FOLL_WRITE games from __get_user_pages() (Torez Smith) [1422636]

* Wed Oct 12 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-15.el7]
- [redhat] configs: disable CPPC (Mark Langsdorf) [1382023]

* Thu Sep 29 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-14.el7]
- DO NOT UPSTREAM: cputopo: support multiple sockets (Andrew Jones) [1378244]
- xfs: quiesce the filesystem after recovery on readonly mount (Eric Sandeen) [1365979]
- xfs: log recovery tracepoints to track current lsn and buffer submission (Jeffrey Bastian) [1379821]
- xfs: update metadata LSN in buffers during log recovery (Jeffrey Bastian) [1379821]
- xfs: don't warn on buffers not being recovered due to LSN (Jeffrey Bastian) [1379821]
- xfs: pass current lsn to log recovery buffer validation (Jeffrey Bastian) [1379821]
- xfs: rework log recovery to submit buffers on LSN boundaries (Jeffrey Bastian) [1379821]

* Thu Sep 22 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-13.el7]
- dm mpath: delay the requeue of blk-mq requests while all paths down (Mike Snitzer) [1376926]
- dm mpath: use dm_mq_kick_requeue_list() (Mike Snitzer) [1376926]
- dm rq: introduce dm_mq_kick_requeue_list() (Mike Snitzer) [1376926]
- dm rq: reduce arguments passed to map_request() and dm_requeue_original_request() (Mike Snitzer) [1376926]
- dm rq: add DM_MAPIO_DELAY_REQUEUE to delay requeue of blk-mq requests (Mike Snitzer) [1376926]
- blk-mq: introduce blk_mq_delay_kick_requeue_list() (Mike Snitzer) [1376926]
- dm: convert wait loops to use autoremove_wake_function() (Mike Snitzer) [1376926]
- dm: use signal_pending_state() in dm_wait_for_completion() (Mike Snitzer) [1376926]
- dm: rename task state function arguments (Mike Snitzer) [1376926]
- dm: add two lockdep_assert_held() statements (Mike Snitzer) [1376926]
- dm rq: simplify dm_old_stop_queue() (Mike Snitzer) [1376926]
- dm mpath: check if path's request_queue is dying in activate_path() (Mike Snitzer) [1376926]
- dm rq: take request_queue lock while clearing QUEUE_FLAG_STOPPED (Mike Snitzer) [1376926]
- dm rq: factor out dm_mq_stop_queue() (Mike Snitzer) [1376926]
- dm: mark request_queue dead before destroying the DM device (Mike Snitzer) [1376926]
- dm: return correct error code in dm_resume()'s retry loop (Mike Snitzer) [1376926]
- dm flakey: fix reads to be issued if drop_writes configured (Mike Snitzer) [1376926]
- dm crypt: increase mempool reserve to better support swappin (Mike Snitzer) [1376926]
- dm round robin: do not use this_cpu_ptr() without having preemption disabled (Mike Snitzer) [1376926]
- dm: set DMF_SUSPENDED* _before_ clearing DMF_NOFLUSH_SUSPENDING (Mike Snitzer) [1376926]
- dm rq: fix the starting and stopping of blk-mq queues (Mike Snitzer) [1376926]
- dm mpath: add locking to multipath_resume and must_push_back (Mike Snitzer) [1376926]
- dm flakey: error READ bios during the down_interval (Mike Snitzer) [1376926]
- dm btree: fix a bug in dm_btree_find_next_single() (Mike Snitzer) [1376926]
- dm: call PR reserve_unreserve on each underlying device (Mike Snitzer) [1376926]
- dm: fix second blk_delay_queue() parameter to be in msec units not jiffies (Mike Snitzer) [1376926]
- dm rq: check kthread_run return for .request_fn request-based DM (Mike Snitzer) [1376926]
- dm verity fec: fix block calculation (Mike Snitzer) [1376926]
- dm ioctl: Simplify parameter buffer management code (Mike Snitzer) [1376926]
- dm crypt: Fix sparse complaints (Mike Snitzer) [1376926]
- dm mpath: add optional "queue_mode" feature (Mike Snitzer) [1376926]
- dm mpath: remove bio-based bloat from struct dm_mpath_io (Mike Snitzer) [1376926]
- dm mpath: reinstate bio-based support (Mike Snitzer) [1376926]
- dm: move request-based code out to dm-rq.[hc] (Mike Snitzer) [1376926]
- dm raid: make sure no feature flags are set in metadata (Mike Snitzer) [1376926]
- dm ioctl: drop use of __GFP_REPEAT in copy_params()'s __vmalloc() call (Mike Snitzer) [1376926]
- dm stats: fix spelling mistake in Documentation (Mike Snitzer) [1376926]
- dm cache: update cache-policies.txt now that mq is an alias for smq (Mike Snitzer) [1376926]
- dm mpath: eliminate use of spinlock in IO fast-paths (Mike Snitzer) [1376926]
- dm mpath: move trigger_event member to the end of 'struct multipath' (Mike Snitzer) [1376926]
- dm mpath: use atomic_t for counting members of 'struct multipath' (Mike Snitzer) [1376926]
- dm mpath: switch to using bitops for state flags (Mike Snitzer) [1376926]
- dm thin: Remove return statement from void function (Mike Snitzer) [1376926]
- dm: remove unused mapped_device argument from free_tio() (Mike Snitzer) [1376926]
- dm cache metadata: fix cmd_read_lock() acquiring write lock (Mike Snitzer) [1376926]
- dm cache metadata: fix READ_LOCK macros and cleanup WRITE_LOCK macros (Mike Snitzer) [1376926]
- dm: fix dm_target_io leak if clone_bio() returns an error (Mike Snitzer) [1376926]
- dm: fix rq_end_stats() NULL pointer in dm_requeue_original_request() (Mike Snitzer) [1376926]
- dm thin: consistently return -ENOSPC if pool has run out of data space (Mike Snitzer) [1376926]
- dm cache: bump the target version (Mike Snitzer) [1376926]
- dm cache: make sure every metadata function checks fail_io (Mike Snitzer) [1376926]
- dm: add missing newline between DM_DEBUG_BLOCK_STACK_TRACING and DM_BUFIO (Mike Snitzer) [1376926]
- dm cache policy smq: clarify that mq registration failure was for 'mq' (Mike Snitzer) [1376926]
- dm: return error if bio_integrity_clone() fails in clone_bio() (Mike Snitzer) [1376926]
- dm thin metadata: don't issue prefetches if a transaction abort has failed (Mike Snitzer) [1376926]
- dm snapshot: disallow the COW and origin devices from being identical (Mike Snitzer) [1376926]
- dm cache: make the 'mq' policy an alias for 'smq' (Mike Snitzer) [1376926]
- dm: drop unnecessary assignment of md->queue (Mike Snitzer) [1376926]
- dm: reorder 'struct mapped_device' members to fix alignment and holes (Mike Snitzer) [1376926]
- dm: remove dummy definition of 'struct dm_table' (Mike Snitzer) [1376926]
- dm: add 'dm_numa_node' module parameter (Mike Snitzer) [1376926]
- dm thin metadata: remove needless newline from subtree_dec() DMERR message (Mike Snitzer) [1376926]
- dm mpath: cleanup reinstate_path() et al based on code review (Mike Snitzer) [1376926]
- dm mpath: remove __pgpath_busy forward declaration, rename to pgpath_busy (Mike Snitzer) [1376926]
- dm mpath: switch from 'unsigned' to 'bool' for flags where appropriate (Mike Snitzer) [1376926]
- dm round robin: use percpu 'repeat_count' and 'current_path' (Mike Snitzer) [1376926]
- dm path selector: remove 'repeat_count' return from .select_path hook (Mike Snitzer) [1376926]
- dm mpath: push path selector locking down to path selectors (Mike Snitzer) [1376926]
- dm mpath: remove repeat_count support from multipath core (Mike Snitzer) [1376926]
- dm mpath: remove unnecessary casts in front of ti->private (Mike Snitzer) [1376926]
- dm mpath: use blk_mq_alloc_request() and blk_mq_free_request() directly (Mike Snitzer) [1376926]
- dm mpath: cleanup 'struct dm_mpath_io' management code (Mike Snitzer) [1376926]
- dm mpath: use blk-mq pdu for per-request 'struct dm_mpath_io' (Mike Snitzer) [1376926]
- dm: allow immutable request-based targets to use blk-mq pdu (Mike Snitzer) [1376926]
- dm: rename target's per_bio_data_size to per_io_data_size (Mike Snitzer) [1376926]
- dm: distinquish old .request_fn (dm-old) vs dm-mq request-based DM (Mike Snitzer) [1376926]
- dm: remove support for stacking dm-mq on .request_fn device(s) (Mike Snitzer) [1376926]
- dm: fix a couple locking issues with use of block interfaces (Mike Snitzer) [1376926]
- dm: allocate blk_mq_tag_set rather than embed in mapped_device (Mike Snitzer) [1376926]
- dm: add 'dm_mq_nr_hw_queues' and 'dm_mq_queue_depth' module params (Mike Snitzer) [1376926]
- dm: optimize dm_request_fn() (Mike Snitzer) [1376926]
- dm: optimize dm_mq_queue_rq() (Mike Snitzer) [1376926]
- dm: set DM_TARGET_WILDCARD feature on "error" target (Mike Snitzer) [1376926]
- dm: cleanup dm_any_congested() (Mike Snitzer) [1376926]
- dm: remove unused dm_get_rq_mapinfo() (Mike Snitzer) [1376926]
- dm: fix excessive dm-mq context switching (Mike Snitzer) [1376926]
- dm: fix sparse "unexpected unlock" warnings in ioctl code (Mike Snitzer) [1376926]
- dm: do not return target from dm_get_live_table_for_ioctl() (Mike Snitzer) [1376926]

* Wed Sep 21 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-12.el7]
- arm64: Call numa_store_cpu_info() earlier. (David Daney) [1377488]
- redhat: config: arm64: Turn off DMA driver (Iyappan Subramanian) [1376872]
- copy x509.genkey to certs/ directory (Jeffrey Bastian) [1377468]
- PCI: Vulcan: AHCI PCI bar fix for Broadcom Vulcan early silicon (Ashok Kumar Sekar) [1376499]

* Thu Sep 15 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-11.el7]
- tcp: enable per-socket rate limiting of all 'challenge acks' (Mark Langsdorf) [1355620]

* Tue Sep 13 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-10.el7]
- CVE-2016-6480 aacraid: Check size values after double-fetch from user (Mark Salter) [1369775]
- xfs: revert "xfs: Don't wrap growfs AGFL indexes" (Eric Sandeen) [1373963]
- xfs: revert "libxfs: pack the agfl header structure so XFS_AGFL_SIZE is correct" (Eric Sandeen) [1373963]
- xfs: track and serialize in-flight async buffers against unmount (Eric Sandeen) [1373963]
- xfs: exclude never-released buffers from buftarg I/O accounting (Eric Sandeen) [1373963]
- xfs: don't reset b_retries to 0 on every failure (Eric Sandeen) [1373963]
- xfs: remove extraneous buffer flag changes (Eric Sandeen) [1373963]
- xfs: fix xfs_error_get_cfg for negative errnos (Eric Sandeen) [1373963]
- xfs: cancel eofblocks background trimming on remount read-only (Eric Sandeen) [1373963]
- xfs: add "fail at unmount" error handling configuration (Eric Sandeen) [1373963]
- xfs: add configuration handlers for specific errors (Eric Sandeen) [1373963]
- xfs: add configuration of error failure speed (Eric Sandeen) [1373963]
- xfs: introduce table-based init for error behaviors (Eric Sandeen) [1373963]
- xfs: add configurable error support to metadata buffers (Eric Sandeen) [1373963]
- xfs: introduce metadata IO error class (Eric Sandeen) [1373963]
- xfs: configurable error behavior via sysfs (Eric Sandeen) [1373963]
- xfs: disallow rw remount on fs with unknown ro-compat features (Eric Sandeen) [1373963]
- xfs: fix xfs_log_ticket leak in xfs_end_io() after fs shutdown (Eric Sandeen) [1373963]
- xfs: clean up unwritten buffers on write failure (Eric Sandeen) [1373963]
- xfs: Split default quota limits by quota type (Eric Sandeen) [1373963]
- quota: Fixup comments about return value of Q_[X]GETNEXTQUOTA (Eric Sandeen) [1373963]
- xfs: wire up Q_XGETNEXTQUOTA / get_nextdqblk (Eric Sandeen) [1373963]
- xfs: Factor xfs_seek_hole_data into helper (Eric Sandeen) [1373963]
- xfs: get quota inode from mp & flags rather than dqp (Eric Sandeen) [1373963]
- xfs: don't overflow quota ID when initializing dqblk (Eric Sandeen) [1373963]
- quota: add new quotactl Q_GETNEXTQUOTA (Eric Sandeen) [1373963]
- quota: add new quotactl Q_XGETNEXTQUOTA (Eric Sandeen) [1373963]
- quota: remove unused cmd argument from quota_quotaon() (Eric Sandeen) [1373963]

* Fri Sep 09 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-9.el7]
- sd: Fix rw_max for devices that report an optimal xfer size (Ewan Milne) [1314801]
- bridge: re-introduce 'fix parsing of MLDv2 reports' (Davide Caratti) [1371357]
- nfsd: use short read as well as i_size to set eof (Jon Masters) [1368928]
- NOT UPSTREAM: kvm: perf: Replace sizeof in tracept with hard-coded size (Jeremy Linton) [1373657]
- sunrpc: fix UDP memory accounting (Dean Nelson) [1362276]
- net/mlx4: Avoid wrong virtual mappings (Christopher Covington) [1268465]
- ACPI: CPPC: Support PCC with interrupt flag (Al Stone)
- mailbox: pcc: Support HW-Reduced Communication Subspace type 2 (Al Stone)

* Tue Sep 06 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-8.el7]
- arm64: kexec: use phys_to_virt() in stead of kmap() (Pratyush Anand) [1372252]
- [redhat] Disable ATL2 to work-around CVE-201602117 (Mark Langsdorf) [1320109]

* Thu Sep 01 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-7.el7]
- tools lib traceevent: Add '~' operation within arg_num_eval() (Jeremy Linton) [1298229]
- redhat/config, arm64: Enable CONFIG_ARM64_LSE_ATOMICS in redhat config (Ashok Kumar Sekar) [1260093]
- Redhat/Configs : Enabling Chelsio cxgb4 driver in RHELSA (Sai Vemuri) [1356989]
- Redhat/Configs: Enabling cxgb4i driver in RHELSA (Sai Vemuri) [1356988]
- ACPI/CPPC: set a non-zero value for transition_latency (Mark Langsdorf)
- ACPI/CPPC: support for batching CPPC requests (Al Stone)
- ACPI/CPPC: acquire pcc_lock only while accessing PCC subspace (Al Stone)
- ACPI/CPPC: restructure read/writes for efficient sys mapped reg ops (Al Stone)

* Thu Aug 25 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-6.el7]
- irqchip/gicv3-its: Disable the ITS before initializing it. (David Daney) [1342672]
- net: thunderx: Fix OOPs with ethtool --register-dump (David Daney) [1367556]
- kexec: export OFFSET(page.compound_head) to find out compound tail page (Pratyush Anand) [1369808]
- kexec: update VMCOREINFO for compound_order/dtor (Pratyush Anand) [1369808]

* Tue Aug 23 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-5.el7]
- redhat: config: arm64: Modularize ethernet driver (Iyappan Subramanian) [1264538]
- dtb: xgene: Fix backward compatibility (Iyappan Subramanian) [1367761]
- drivers: net: xgene: Fix backward compatibility (Iyappan Subramanian) [1367761]
- Documentation: dtb: xgene: Add rxlos GPIO mapping (Iyappan Subramanian) [1267764]
- dtb: xgene: Add rxlos-gpios property (Iyappan Subramanian) [1267764]
- drivers: net: xgene: Poll link status via GPIO (Iyappan Subramanian) [1267764]
- drivers: net: xgene: XFI PCS reset when link is down (Iyappan Subramanian) [1267764]
- drivers: net: xgene: Change port init sequence (Iyappan Subramanian) [1367761]
- drivers: net: xgene: Fix RSS indirection table fields (Iyappan Subramanian) [1367761]
- drivers: net: xgene: Fix error deconstruction path (Iyappan Subramanian) [1367761]
- drivers: net: xgene: fix: Delete descriptor rings and buffer pools (Iyappan Subramanian) [1367761]
- drivers: net: xgene: fix: Add dma_unmap_single (Iyappan Subramanian) [1367761]
- drivers: net: xgene: Fix compiler warnings (Iyappan Subramanian) [1367761]
- ethernet: apm: xgene: add missing of_node_put after calling of_parse_phandle (Iyappan Subramanian) [1367761]
- MAINTAINERS: xgene: Add driver and documentation path (Iyappan Subramanian) [1234597]
- Documentation: dtb: xgene: Add MDIO node (Iyappan Subramanian) [1234597]
- dtb: xgene: Add MDIO node (Iyappan Subramanian) [1234597]
- drivers: net: xgene: ethtool: Use phy_ethtool_gset and sset (Iyappan Subramanian) [1234597]
- drivers: net: xgene: Use exported functions (Iyappan Subramanian) [1234597]
- drivers: net: xgene: Enable MDIO driver (Iyappan Subramanian) [1234597]
- drivers: net: xgene: Add backward compatibility (Iyappan Subramanian) [1234597]
- drivers: net: phy: xgene: Add MDIO driver (Iyappan Subramanian) [1234597]
- drivers: net: xgene: Fix module unload crash - clkrst sequence (Iyappan Subramanian) [1264538]
- drivers: net: xgene: Fix module unload crash - change sw sequence (Iyappan Subramanian) [1264538 1264547 1266384 1288050]
- drivers: net: xgene: Fix module unload crash - hw resource cleanup (Iyappan Subramanian) [1264538 1264547 1266384 1288050]
- drivers: net: xgene: Separate set_speed from mac_init (Iyappan Subramanian) [1264538]
- drivers: net: xgene: Fix error handling (Iyappan Subramanian) [1234597]
- drivers: net: xgene: constify xgene_cle_ops structure (Iyappan Subramanian) [1234597]
- arm64: dts: apm: Update GPIO standby controller DT node for X-Gene v2 platforms (Iyappan Subramanian) [1234597]
- xgene: get_phy_device() doesn't return NULL anymore (Iyappan Subramanian) [1234597]
- drivers: net: xgene: revert rhelsa commit (Iyappan Subramanian) [1264538]

* Fri Aug 19 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-4.el7]
- arm64: KVM: Set cpsr before spsr on fault injection (Andrew Jones) [1169787]
- arm64: KVM: unregister notifiers in hyp mode teardown path (Wei Huang) [1361731]
- arm64: clean up kvm initialization code (Wei Huang) [1361731]
- ACPI / bus: Support for platform initiated graceful shutdown (Al Stone) [1268472]

* Fri Aug 05 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-3.el7]
- ACPI: IORT: de-escalate error message (Al Stone) [1340191]
- ipv4/fib: don't warn when primary address is missing if in_dev is dead (Dean Nelson) [1318272]
- ipv4: Don't do expensive useless work during inetdev destroy. (Dean Nelson) [1318272]
- audit: fix a double fetch in audit_log_single_execve_arg() (Mark Langsdorf) [1359037]
- platform/chrome: cros_ec_dev - double fetch bug in ioctl (Mark Langsdorf) [1362384]

* Tue Aug 02 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-2.el7]
- ecryptfs: don't allow mmap when the lower fs doesn't support it (Mark Langsdorf) [1351951]
- ovl: verify upper dentry before unlink and rename (Mark Langsdorf) [1359025]
- xfs: fix broken multi-fsb buffer logging (Mark Langsdorf) [1356009]
- tcp: make challenge acks less predictable (Mark Langsdorf) [1355620]
- nfsd: check permissions when setting ACLs (Mark Langsdorf) [1353091]
- posix_acl: Add set_posix_acl (Mark Langsdorf) [1353091]
- misc: mic: Fix for double fetch security bug in VOP driver (Mark Langsdorf) [1352820]
- sched: panic on corrupted stack end (Mark Langsdorf) [1351951]
- proc: prevent stacking filesystems on top (Mark Langsdorf) [1351951]
- HID: hiddev: validate num_values for HIDIOCGUSAGES, HIDIOCSUSAGES commands (Mark Langsdorf) [1357433]
- netfilter: x_tables: check for bogus target offset (Mark Langsdorf) [1351037]
- netfilter: x_tables: add compat version of xt_check_entry_offsets (Mark Langsdorf) [1351037]
- netfilter: x_tables: kill check_entry helper (Mark Langsdorf) [1351037]
- netfilter: x_tables: add and use xt_check_entry_offsets (Mark Langsdorf) [1351037]
- netfilter: x_tables: make sure e->next_offset covers remaining blob size (Mark Langsdorf) [1351037]
- netfilter: x_tables: validate e->target_offset early (Mark Langsdorf) [1351037]
- rds: fix an infoleak in rds_inc_info_copy (Mark Langsdorf) [1348021]
- tipc: fix nl compat regression for link statistics (Mark Langsdorf) [1348017]
- tipc: fix an infoleak in tipc_nl_compat_link_dump (Mark Langsdorf) [1348017]
- tipc: check nl sock before parsing nested attributes (Mark Langsdorf) [1346815]
- bpf: fix double-fdput in replace_map_fd_with_map_ptr() (Mark Langsdorf) [1346578]
- KEYS: potential uninitialized variable (Mark Langsdorf) [1345941]
- percpu: fix synchronization between chunk->map_extend_work and chunk destruction (Mark Langsdorf) [1344572]
- percpu: fix synchronization between chunk->map_extend_work and chunk destruction (Mark Langsdorf) [1344572]
- get_rock_ridge_filename(): handle malformed NM entries (Mark Langsdorf) [1340781]
- propogate_mnt: Handle the first propogated copy being a slave (Mark Langsdorf) [1335979]
- bpf: fix refcnt overflow (Mark Langsdorf) [1335701]
- KEYS: Fix ASN.1 indefinite length object parsing (Mark Langsdorf) [1325960]
- netfilter: x_tables: introduce and use xt_copy_counters_from_user (Mark Langsdorf)
- arm64: KVM: VHE: Context switch MDSCR_EL1 (Andrew Jones) [1357848]
- [redhat] Remove the pre-build numbering scheme (Mark Langsdorf)

* Tue Aug 02 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-1.el7.test]
- ecryptfs: don't allow mmap when the lower fs doesn't support it (Mark Langsdorf) [1351951]
- ovl: verify upper dentry before unlink and rename (Mark Langsdorf) [1359025]
- xfs: fix broken multi-fsb buffer logging (Mark Langsdorf) [1356009]
- tcp: make challenge acks less predictable (Mark Langsdorf) [1355620]
- nfsd: check permissions when setting ACLs (Mark Langsdorf) [1353091]
- posix_acl: Add set_posix_acl (Mark Langsdorf) [1353091]
- misc: mic: Fix for double fetch security bug in VOP driver (Mark Langsdorf) [1352820]
- sched: panic on corrupted stack end (Mark Langsdorf) [1351951]
- proc: prevent stacking filesystems on top (Mark Langsdorf) [1351951]
- HID: hiddev: validate num_values for HIDIOCGUSAGES, HIDIOCSUSAGES commands (Mark Langsdorf) [1357433]
- netfilter: x_tables: check for bogus target offset (Mark Langsdorf) [1351037]
- netfilter: x_tables: add compat version of xt_check_entry_offsets (Mark Langsdorf) [1351037]
- netfilter: x_tables: kill check_entry helper (Mark Langsdorf) [1351037]
- netfilter: x_tables: add and use xt_check_entry_offsets (Mark Langsdorf) [1351037]
- netfilter: x_tables: make sure e->next_offset covers remaining blob size (Mark Langsdorf) [1351037]
- netfilter: x_tables: validate e->target_offset early (Mark Langsdorf) [1351037]
- rds: fix an infoleak in rds_inc_info_copy (Mark Langsdorf) [1348021]
- tipc: fix nl compat regression for link statistics (Mark Langsdorf) [1348017]
- tipc: fix an infoleak in tipc_nl_compat_link_dump (Mark Langsdorf) [1348017]
- tipc: check nl sock before parsing nested attributes (Mark Langsdorf) [1346815]
- bpf: fix double-fdput in replace_map_fd_with_map_ptr() (Mark Langsdorf) [1346578]
- KEYS: potential uninitialized variable (Mark Langsdorf) [1345941]
- percpu: fix synchronization between chunk->map_extend_work and chunk destruction (Mark Langsdorf) [1344572]
- percpu: fix synchronization between chunk->map_extend_work and chunk destruction (Mark Langsdorf) [1344572]
- get_rock_ridge_filename(): handle malformed NM entries (Mark Langsdorf) [1340781]
- propogate_mnt: Handle the first propogated copy being a slave (Mark Langsdorf) [1335979]
- bpf: fix refcnt overflow (Mark Langsdorf) [1335701]
- KEYS: Fix ASN.1 indefinite length object parsing (Mark Langsdorf) [1325960]
- netfilter: x_tables: introduce and use xt_copy_counters_from_user (Mark Langsdorf)
- arm64: KVM: VHE: Context switch MDSCR_EL1 (Andrew Jones) [1357848]
- [redhat] Remove the pre-build numbering scheme (Mark Langsdorf)

* Wed Jul 27 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-0.48.el7]
- PCI: thunder: Add ThunderX PEM MCFG quirk to the list (Robert Richter) [1351508]
- PCI: Check platform specific ECAM quirks (Robert Richter) [1351508]
- PCI: Workaround for Broadcom Vulcan DMA alias calculation (Ashok Kumar Sekar) [1341255]
- cpufreq: pcc-cpufreq: Fix doorbell.access_width (Al Stone) [1273604]
- ACPI: CPPC: Return error if _CPC is invalid on a CPU (Al Stone) [1273604 1351826]
- ACPI / CPPC: Prevent cpc_desc_ptr points to the invalid (Al Stone) [1273604 1351826]
- mailbox: pcc: Add PCC request and free channel declarations (Al Stone) [1273604]
- mailbox: pcc: Don't access an unmapped memory address space (Al Stone) [1273604]
- ACPICA: ACPI 6.1: Support for new PCCT subtable (Al Stone) [1273604]

* Mon Jul 25 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-0.47.el7]
- Red Hat: config-arm64-redhat: ensure that /dev/port is disabled (Al Stone) [1261659 1290605]
- Red Hat: config-arm64-redhat: ensure /dev/mem is disabled (Al Stone) [1261659 1290605]
- Force cppc_cpufreq to report values in KHz to fix user space reporting (Al Stone) [1323315]
- mm: introduce dedicated WQ_MEM_RECLAIM workqueue to do lru_add_drain_all (Jeremy Linton) [1268422]

* Tue Jul 19 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-0.46.el7]
- [redhat/config]: Enable pinctrl for QDF243 (Mark Langsdorf)
- net: thunderx: Fix TL4 configuration for secondary Qsets (Robert Richter)
- net: thunderx: Fix link status reporting (Robert Richter)
- KVM: arm/arm64: Stop leaking vcpu pid references (Andrew Jones) [1348557]
- kvm: Fix irq route entries exceeding KVM_MAX_IRQ_ROUTES (Andrew Jones) [1348557]
- KVM: irqfd: fix NULL pointer dereference in kvm_irq_map_gsi (Andrew Jones) [1348557]
- KVM: arm/arm64: vgic-v3: Clear all dirty LRs (Andrew Jones) [1348557]
- KVM: arm/arm64: vgic-v2: Clear all dirty LRs (Andrew Jones) [1348557]
- kvm: arm64: Fix EC field in inject_abt64 (Andrew Jones) [1348557]
- arm/arm64: KVM: Enforce Break-Before-Make on Stage-2 page tables (Andrew Jones) [1348557]
- arm64: KVM: Move vgic-v2 and timer save/restore to virt/kvm/arm/hyp (Andrew Jones) [1348557]
- arm64: KVM: Move kvm/hyp/hyp.h to include/asm/kvm_hyp.h (Andrew Jones) [1348557]
- [redhat/config]: Add Vulcan GPIO driver in arm64 config (Ashok Kumar Sekar) [1344229]
- arm64: vulcan: enable GPIOLIB in Kconfig (Ashok Kumar Sekar) [1344229]
- gpio: Add ACPI support for XLP GPIO controller (Ashok Kumar Sekar) [1344229]
- gpio: xlp: Fix vulcan IRQ descriptor allocation (Ashok Kumar Sekar) [1344229]
- gpio: xlp: Add GPIO driver support for Broadcom Vulcan ARM64 (Ashok Kumar Sekar) [1344229]
- arm64: skip VHE on affected arm64 CPUs (Wei Huang) [1341746]

* Wed Jul 13 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-0.45.el7]
- smsc911x: Fix bug where PHY interrupts are overwritten by 0 (Jeremy Linton) [1348306]
- arm64: mm: always take dirty state from new pte in ptep_set_access_flags (Mark Langsdorf) [1351249]
- pci: xgene: Match ECAM quirk using OEM ID and OEM Table ID (Iyappan Subramanian) [1337351]
- pci: xgene: Enable fix-up for all PCIe domains (Iyappan Subramanian) [1337351]

* Thu Jun 30 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-0.44.el7]
- arm64: kvm: Fix initialization of vgic (Robert Richter) [1335071]
- tty: vt: Fix soft lockup in fbcon cursor blink timer. (Robert Richter) [1350778]
- irqchip/gic-v3: Fix ICC_SGI1R_EL1.INTID decoding mask (Andrew Jones) [1348485]
- irqchip/gic-v3: Configure all interrupts as non-secure Group-1 (Andrew Jones) [1348485]
- irqchip/gic: Ensure ordering between read of INTACK and shared data (Andrew Jones) [1348485]
- crypto: ccp - Fix AES XTS error for request sizes above 4096 (Jeffrey Bastian) [1256466]
- ipmi: remove legacy port io and trydefaults parameter (Tony Camuso)
- virtio_net: fix virtnet_open and virtnet_probe competing for try_fill_recv (Andrew Jones) [1348551]
- virtio: virtio 1.0 cs04 spec compliance for reset (Andrew Jones) [1348551]

* Mon Jun 27 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-0.43.el7]
- update rpm conflict for old xfsprogs versions (Jeffrey Bastian) [1306029, 1340553]
- drivers: net: xgene: fix register offset (Iyappan Subramanian) [1336525]
- drivers: net: xgene: fix statistics counters race condition (Iyappan Subramanian) [1336524]
- drivers: net: xgene: fix ununiform latency across queues (Iyappan Subramanian) [1336520]
- drivers: net: xgene: fix sharing of irqs (Iyappan Subramanian) [1336519]
- drivers: net: xgene: fix IPv4 forward crash (Iyappan Subramanian) [1336518]
- dtb: xgene: Add channel property (Iyappan Subramanian) [1346129]
- Documentation: dtb: xgene: Add channel property (Iyappan Subramanian) [1346129]
- drivers: net: xgene: Get channel number from device binding (Iyappan Subramanian) [1346129]
- dtb: xgene: Add irqs to support multi queue (Iyappan Subramanian) [1346128]
- drivers: net: xgene: Add support for multiple queues (Iyappan Subramanian) [1346128]
- drivers: net: xgene: Add support for RSS (Iyappan Subramanian) [1346128]
- drivers: net: xgene: Add support for Classifier engine (Iyappan Subramanian) [1346128]
- redhat/configs: comment merge override hierarchy (Andrew Jones) [1346128]

* Fri Jun 24 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-0.42.el7]
- raid5: delete unnecessary warnning (Jes Sorensen) [1343679]
- MD: make bio mergeable (Jes Sorensen) [1343679]
- md/raid0: fix uninitialized variable bug (Jes Sorensen) [1343679]
- md/bitmap: clear bitmap if bitmap_create failed (Jes Sorensen) [1343679]
- MD: add rdev reference for super write (Jes Sorensen) [1343679]
- md: fix a trivial typo in comments (Jes Sorensen) [1343679]
- md:raid1: fix a dead loop when read from a WriteMostly disk (Jes Sorensen) [1343679]
- md/raid5: Cleanup cpu hotplug notifier (Jes Sorensen) [1343679]
- raid10: include bio_end_io_list in nr_queued to prevent freeze_array hang (Jes Sorensen) [1343679]
- raid1: include bio_end_io_list in nr_queued to prevent freeze_array hang (Jes Sorensen) [1343679]
- md: fix typos for stipe (Jes Sorensen) [1343679]
- md/bitmap: remove redundant return in bitmap_checkpage (Jes Sorensen) [1343679]
- md/raid1: remove unnecessary BUG_ON (Jes Sorensen) [1343679]
- md: multipath: don't hardcopy bio in .make_request path (Jes Sorensen) [1343679]
- md/raid5: output stripe state for debug (Jes Sorensen) [1343679]
- md/raid5: preserve STRIPE_PREREAD_ACTIVE in break_stripe_batch_list (Jes Sorensen) [1343679]
- md/bitmap: remove redundant check (Jes Sorensen) [1343679]
- md: Drop sending a change uevent when stopping (Jes Sorensen) [1343679]
- RAID5: revert e9e4c377e2f563 to fix a livelock (Jes Sorensen) [1343679]
- RAID5: check_reshape() shouldn't call mddev_suspend (Jes Sorensen) [1343679]
- md/raid5: Compare apples to apples (or sectors to sectors) (Jes Sorensen) [1268121 1343679]
- Disable MD_CLUSTER on aarch64 (Jes Sorensen) [1342643]

* Thu Jun 23 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-0.41.el7]
- irqchip, gicv3-its, numa: Enable Cavium ThunderX #23144 workaround for ACPI (Al Stone) [1243014]
- irqchip/gicv3-its: numa: Enable workaround for Cavium thunderx erratum 23144 (Al Stone) [1243014]
- irqchip/gicv3-its: Don't allow devices whose ID is outside range (Al Stone) [1243014]
- [redhat] Enable NUMA support for ARM64 (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- arm64: Update PTE_RDONLY in set_pte_at() for PROT_NONE permission (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- ACPI / NUMA: Enable ACPI based NUMA on ARM64 (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- arm64, ACPI, NUMA: NUMA support based on SRAT and SLIT (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- ACPI / processor: Add acpi_map_madt_entry() (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- ACPI / NUMA: Improve SRAT error detection and add messages (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- ACPI / NUMA: Move acpi_numa_memory_affinity_init() to drivers/acpi/numa.c (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- ACPI / NUMA: remove unneeded acpi_numa=1 (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- ACPI / NUMA: move bad_srat() and srat_disabled() to drivers/acpi/numa.c (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- x86 / ACPI / NUMA: cleanup acpi_numa_processor_affinity_init() (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- arm64, NUMA: Cleanup NUMA disabled messages (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- arm64, NUMA: rework numa_add_memblk() (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- ACPI / NUMA: move acpi_numa_slit_init() to drivers/acpi/numa.c (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- ACPI / NUMA: Move acpi_numa_arch_fixup() to ia64 only (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- ACPI / NUMA: remove duplicate NULL check (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- ACPI / NUMA: Replace ACPI_DEBUG_PRINT() with pr_debug() (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- ACPI / NUMA: Use pr_fmt() instead of printk (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- efi: ARM: avoid warning about phys_addr_t cast (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- arm64: Implement ptep_set_access_flags() for hardware AF/DBM (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- arm64, mm, numa: Add NUMA balancing support for arm64. (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- arm64, numa: Add NUMA support for arm64 platforms. (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- arm64: Move unflatten_device_tree() call earlier. (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- of, numa: Add NUMA of binding implementation. (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- Documentation, dt, numa: dt bindings for NUMA. (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- efi: ARM/arm64: ignore DT memory nodes instead of removing them (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]
- ACPI / SRAT: fix SRAT parsing order with both LAPIC and X2APIC present (Mark Langsdorf) [1243014 1260043 1260049 1265384 1266463 1270944]

* Fri Jun 10 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-0.40.el7]
- Go to back to 42 bit VA (Mark Langsdorf) [1325446]
- Revert "KVM: arm/arm64: timer: Switch to CLOCK_MONOTONIC_RAW" (Andrew Jones) [1342927]

* Fri Jun 03 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-0.39.el7]
- arm64: perf: Enable PMCR long cycle counter bit (Robert Richter) [1268503]
- Eliminate minor memory leak in acpi_spcr_device_scan() (Al Stone) [1233403]
- arm64: prefetch: add missing #include for spin_lock_prefetch (Robert Richter) [1242991]
- arm64: lib: patch in prfm for copy_page if requested (Robert Richter) [1242991]
- arm64: lib: improve copy_page to deal with 128 bytes at a time (Robert Richter) [1242991]
- arm64: prefetch: add alternative pattern for CPUs without a prefetcher (Mark Langsdorf)
- arm64: prefetch: don't provide spin_lock_prefetch with LSE (Robert Richter) [1242991]

* Thu May 19 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-0.38.el7]
- xfs: Don't wrap growfs AGFL indexes ("Richard W.M. Jones") [1315895]
- KVM: arm/arm64: Handle forward time correction gracefully (Wei Huang) [1326928]
- arm/arm64: KVM: Handle out-of-RAM cache maintenance as a NOP (Wei Huang) [1326928]
- arm64: kvm: Enable ACPI support for KVM GIC v4 (Wei Huang) [1326874]
- ACPI: implement Generic Event Device (Al Stone) [1310815]

* Thu May 19 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-0.37.el7]
- redhat/config, arm64: Enable i2c for Cavium ThunderX (Robert Richter) [1268504]
- i2c: octeon: Add workaround for broken irqs on CN3860 (Robert Richter) [1268504]
- i2c: octeon: Improve performance if interrupt is early (Robert Richter) [1268504]
- i2c: octeon: Remove zero-length message support (Robert Richter) [1268504]
- i2c: octeon: Add support for cn78xx chips (Robert Richter) [1268504]
- i2c: octeon: Enable High-Level Controller (Robert Richter) [1268504]
- i2c: octeon: Add flush writeq helper function (Robert Richter) [1268504]
- i2c: octeon: Use i2c recovery framework (Robert Richter) [1268504]
- i2c: octeon: Improve error status checking (Robert Richter) [1268504]
- i2c: octeon: Remove superfluous check in octeon_i2c_test_iflg (Robert Richter) [1268504]
- i2c: octeon: Introduce helper functions for register access (Robert Richter) [1268504]
- i2c: octeon: Rename [read|write]_sw to reg_[read|write] (Robert Richter) [1268504]
- i2c: octeon: Move set-clock and init-lowlevel upward (Robert Richter) [1268504]
- i2c: octeon: Increase retry default and use fixed timeout value (Robert Richter) [1268504]
- i2c: octeon: Support I2C_M_RECV_LEN (Robert Richter) [1268504]
- i2c: octeon: Cleanup resource allocation code (Robert Richter) [1268504]
- i2c: octeon: Cleanup i2c-octeon driver (Robert Richter) [1268504]
- i2c: octeon: Cleanup kerneldoc comments (Robert Richter) [1268504]
- net: thunderx: Improvement for MBX interface debug messages (Robert Richter) [1268502]
- net: thunderx: add sysfs attribute for SQS/SVF assigments (Robert Richter) [1268502]
- net: thunderx: Add multiqset support for dataplane apps (Robert Richter) [1268502]
- net: thunderx: Introduce a mailbox message to reset VF counters (Robert Richter) [1268502]
- net: thunderx: Fix broken of_node_put() code. (Robert Richter) [1268502]
- net: thunderx: Don't leak phy device references on -EPROBE_DEFER condition. (Robert Richter) [1268502]
- net: cavium: For Kconfig THUNDER_NIC_BGX, select MDIO_THUNDER. (Robert Richter) [1268502]
- net: thunderx: Cleanup PHY probing code. (Robert Richter) [1268502]
- net: thunderx: Adjust nicvf structure to reduce cache misses (Robert Richter) [1268502]
- net: thunderx: Set recevie buffer page usage count in bulk (Robert Richter) [1268502]
- net: thunderx: Alloc higher order pages when pagesize is small (Robert Richter) [1268502]
- net: thunderx: bgx: Add log message when setting mac address (Robert Richter) [1268502]
- net: thunderx: bgx: Use standard firmware node infrastructure. (Robert Richter) [1268502]
- net: thunderx: Assign affinity hints to vf's interrupts (Robert Richter) [1268502]
- net: thunderx: Use napi_schedule_irqoff() (Robert Richter) [1268502]
- net, thunderx: Add TX timeout and RX buffer alloc failure stats. (Robert Richter) [1268502]
- IPMI: reserve memio regions separately (Mark Salter) [1323185]
- PCI: ACPI: IA64: fix IO port generic range check (Robert Richter) [1242962]

* Thu May 19 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-0.36.el7.test]
- redhat/config, arm64: Enable i2c for Cavium ThunderX (Robert Richter) [1268504]
- i2c: octeon: Add workaround for broken irqs on CN3860 (Robert Richter) [1268504]
- i2c: octeon: Improve performance if interrupt is early (Robert Richter) [1268504]
- i2c: octeon: Remove zero-length message support (Robert Richter) [1268504]
- i2c: octeon: Add support for cn78xx chips (Robert Richter) [1268504]
- i2c: octeon: Enable High-Level Controller (Robert Richter) [1268504]
- i2c: octeon: Add flush writeq helper function (Robert Richter) [1268504]
- i2c: octeon: Use i2c recovery framework (Robert Richter) [1268504]
- i2c: octeon: Improve error status checking (Robert Richter) [1268504]
- i2c: octeon: Remove superfluous check in octeon_i2c_test_iflg (Robert Richter) [1268504]
- i2c: octeon: Introduce helper functions for register access (Robert Richter) [1268504]
- i2c: octeon: Rename [read|write]_sw to reg_[read|write] (Robert Richter) [1268504]
- i2c: octeon: Move set-clock and init-lowlevel upward (Robert Richter) [1268504]
- i2c: octeon: Increase retry default and use fixed timeout value (Robert Richter) [1268504]
- i2c: octeon: Support I2C_M_RECV_LEN (Robert Richter) [1268504]
- i2c: octeon: Cleanup resource allocation code (Robert Richter) [1268504]
- i2c: octeon: Cleanup i2c-octeon driver (Robert Richter) [1268504]
- i2c: octeon: Cleanup kerneldoc comments (Robert Richter) [1268504]
- net: thunderx: Improvement for MBX interface debug messages (Robert Richter) [1268502]
- net: thunderx: add sysfs attribute for SQS/SVF assigments (Robert Richter) [1268502]
- net: thunderx: Add multiqset support for dataplane apps (Robert Richter) [1268502]
- net: thunderx: Introduce a mailbox message to reset VF counters (Robert Richter) [1268502]
- net: thunderx: Fix broken of_node_put() code. (Robert Richter) [1268502]
- net: thunderx: Don't leak phy device references on -EPROBE_DEFER condition. (Robert Richter) [1268502]
- net: cavium: For Kconfig THUNDER_NIC_BGX, select MDIO_THUNDER. (Robert Richter) [1268502]
- net: thunderx: Cleanup PHY probing code. (Robert Richter) [1268502]
- net: thunderx: Adjust nicvf structure to reduce cache misses (Robert Richter) [1268502]
- net: thunderx: Set recevie buffer page usage count in bulk (Robert Richter) [1268502]
- net: thunderx: Alloc higher order pages when pagesize is small (Robert Richter) [1268502]
- net: thunderx: bgx: Add log message when setting mac address (Robert Richter) [1268502]
- net: thunderx: bgx: Use standard firmware node infrastructure. (Robert Richter) [1268502]
- net: thunderx: Assign affinity hints to vf's interrupts (Robert Richter) [1268502]
- net: thunderx: Use napi_schedule_irqoff() (Robert Richter) [1268502]
- net, thunderx: Add TX timeout and RX buffer alloc failure stats. (Robert Richter) [1268502]
- IPMI: reserve memio regions separately (Mark Salter) [1323185]
- PCI: ACPI: IA64: fix IO port generic range check (Robert Richter) [1242962]

* Thu May 05 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-0.35.el7]
- acpi: pci: QDF2432 32 bit config space accessors (Mark Langsdorf) [1242962 1260044 1268428]
- PCI/XGene: Provide v6 quirk handling for ACPI support (Mark Langsdorf) [1242962 1260044 1268428]
- pci, pci-thunder-pem: Add ACPI support for ThunderX PEM. (Mark Langsdorf) [1242962 1260044 1268428]
- pci, pci-thunder-ecam: Add ACPI support for ThunderX ECAM. (Mark Langsdorf) [1242962 1260044 1268428]
- pci, acpi: Match PCI config space accessors against platfrom specific quirks. (Mark Langsdorf) [1242962 1260044 1268428]
- arm64, pci, acpi: Start using ACPI based PCI host controller driver for ARM64. (Mark Langsdorf) [1242962 1260044 1268428]
- pci, acpi: Support for ACPI based generic PCI host controller (Mark Langsdorf) [1242962 1260044 1268428]
- PCI: generic, thunder: update to use generic ECAM API (Mark Langsdorf) [1242962 1260044 1268428]
- PCI: Provide common functions for ECAM mapping (Mark Langsdorf) [1242962 1260044 1268428]
- arm64, pci, acpi: ACPI support for legacy IRQs parsing and consolidation with DT code. (Mark Langsdorf) [1242962 1260044 1268428]
- acpi, pci: Support IO resources when parsing PCI host bridge resources. (Mark Langsdorf) [1242962 1260044 1268428]
- pci, of: Move the PCI I/O space management to PCI core code. (Mark Langsdorf) [1242962 1260044 1268428]
- x86, ia64: Include acpi_pci_{add|remove}_bus to the default pcibios_{add|remove}_bus implementation. (Mark Langsdorf) [1242962 1260044 1268428]
- pci, acpi: Provide generic way to assign bus domain number. (Mark Langsdorf) [1242962 1260044 1268428]
- pci, acpi, x86, ia64: Move ACPI host bridge device companion assignment to core code. (Mark Langsdorf) [1242962 1260044 1268428]
- Revert "x86, pci: Reorder logic of pci_mmconfig_insert() function" (Mark Langsdorf) [1242962 1260044 1268428]
- Revert "x86, pci, acpi: Move arch-agnostic MMCONFIG (aka ECAM) and ACPI code out of arch/x86/ directory" (Mark Langsdorf) [1242962 1260044 1268428]
- Revert "pci, acpi, mcfg: Provide generic implementation of MCFG code initialization." (Mark Langsdorf) [1242962 1260044 1268428]
- Revert "x86, pci: mmconfig_{32, 64}.c code refactoring - remove code duplication." (Mark Langsdorf) [1242962 1260044 1268428]
- Revert "x86, pci, ecam: mmconfig_64.c becomes default implementation for ECAM driver." (Mark Langsdorf) [1242962 1260044 1268428]
- Revert "pci, acpi, mcfg: Provide default RAW ACPI PCI config space accessors." (Mark Langsdorf) [1242962 1260044 1268428]
- Revert "XEN / PCI: Remove the dependence on arch x86 when PCI_MMCONFIG=y" (Mark Langsdorf) [1242962 1260044 1268428]
- Revert "pci, acpi, ecam: Add flag to indicate whether ECAM region was hot added or not." (Mark Langsdorf) [1242962 1260044 1268428]
- Revert "x86, pci: Use previously added ECAM hot_added flag to remove ECAM regions." (Mark Langsdorf) [1242962 1260044 1268428]
- Revert "pci, acpi: Provide generic way to assign bus domain number." (Mark Langsdorf) [1242962 1260044 1268428]
- Revert "arm64, pci, acpi: Support for ACPI based PCI hostbridge init" (Mark Langsdorf) [1242962 1260044 1268428]
- Revert "DO NOT UPSTREAM - pci/xgene: fixups for ACPI support" (Mark Langsdorf) [1242962 1260044 1268428]
- Revert "DO NOT UPSTREAM - provide hook for MCFG fixups" (Mark Langsdorf) [1242962 1260044 1268428]
- redhat/config, arm64: Enable PCI for Cavium ThunderX (Robert Richter)
- redhat/config, arm64: Enable errata workarounds for Cavium ThunderX (Robert Richter)
- arm64: Add workaround for Cavium erratum 27456 (Mark Langsdorf)
- PCI: thunder: Add driver for ThunderX-pass{1, 2} on-chip devices (Robert Richter) [1242962]
- PCI: thunder: Add PCIe host driver for ThunderX processors (Robert Richter) [1242962]
- PCI: generic: Expose pci_host_common_probe() for use by other drivers (Robert Richter) [1242962]
- PCI: generic: Add pci_host_common_probe(), based on gen_pci_probe() (Robert Richter) [1242962]
- PCI: generic: Move structure definitions to separate header file (Robert Richter) [1242962]
- redhat: configs: Enable 48 bit VA, and RODATA (Jeremy Linton) [1325446]
- kernel: Call mark_tech_preview() for user namespace (Adrian Reber) [1271051]
- kernel: rh_taint: Remove taint and update unsupported hardware message (Adrian Reber) [1330743]
- kernel: Backport RH specific TAINT flags (Adrian Reber) [1271051 1330743]
- redhat/config: Enable user namespaces in arm64 config (Adrian Reber) [1271051]
- userns: Allow creation of user namespaces if user_namespace.enable=1 (Adrian Reber) [1271051]
- userns: Only allow privileged creation of the mount namespace. (Adrian Reber) [1271051]
- ACPI / CPPC: Add module support for cppc_cpufreq driver (Al Stone) [1268470 1288439]
- ACPI / CPPC: use MRTT/MPAR to decide if/when a req can be sent (Al Stone) [1268470 1288439]
- ACPI / CPPC: replace writeX/readX to PCC with relaxed version (Al Stone) [1268470 1288439]
- mailbox: pcc: optimized pcc_send_data (Al Stone) [1268470 1288439]
- ACPI / CPPC: optimized cpc_read and cpc_write (Al Stone) [1268470 1288439]
- ACPI / CPPC: Optimize PCC Read Write operations (Al Stone) [1268470 1288439]
- ACPI,GICv3 Update "Basic GICv3 ACPI enablement" (Jeremy Linton) [1328546]

* Tue Apr 26 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-0.34.el7]
- arm64: perf: fixup for "Move PMU register related defines to asm/perf_event.h" (Mark Langsdorf)
- arm64: kvm: 4.6-rc1: Fix VTCR_EL2 VS setting (Wei Huang) [1326928]
- kvm: arm64: Disable compiler instrumentation for hypervisor code (Wei Huang) [1326928]
- KVM: arm/arm64: disable preemption when calling smp_call_function_many (Wei Huang) [1326928]
- KVM: arm/arm64: timer: Switch to CLOCK_MONOTONIC_RAW (Wei Huang) [1326928]
- arm64: KVM: vgic-v3: Only wipe LRs on vcpu exit (Wei Huang) [1326920]
- arm64: KVM: vgic-v3: Reset LRs at boot time (Wei Huang) [1326920]
- arm64: KVM: vgic-v3: Do not save an LR known to be empty (Wei Huang) [1326920]
- arm64: KVM: vgic-v3: Save maintenance interrupt state only if required (Wei Huang) [1326920]
- arm64: KVM: vgic-v3: Avoid accessing ICH registers (Wei Huang) [1326920]
- KVM: arm/arm64: vgic-v2: Make GICD_SGIR quicker to hit (Wei Huang) [1326920]
- KVM: arm/arm64: vgic-v2: Only wipe LRs on vcpu exit (Wei Huang) [1326920]
- KVM: arm/arm64: vgic-v2: Reset LRs at boot time (Wei Huang) [1326920]
- KVM: arm/arm64: vgic-v2: Do not save an LR known to be empty (Wei Huang) [1326920]
- KVM: arm/arm64: vgic-v2: Move GICH_ELRSR saving to its own function (Wei Huang) [1326920]
- KVM: arm/arm64: vgic-v2: Save maintenance interrupt state only if required (Wei Huang) [1326920]
- KVM: arm/arm64: vgic-v2: Avoid accessing GICH registers (Wei Huang) [1326920]
- KVM: arm/arm64: timer: Add active state caching (Wei Huang) [1326893]
- arm64: KVM: Switch the sys_reg search to be a binary search (Wei Huang) [1326893]
- arm64: KVM: Fix KVM_CAP index values (Wei Huang) [1290593]
- arm64: KVM: Add braces to multi-line if statement in virtual PMU code (Wei Huang) [1290593]
- arm64: perf: Move PMU register related defines to asm/perf_event.h (Mark Langsdorf)
- arm64: KVM: Add a new vcpu device control group for PMUv3 (Wei Huang) [1290593]
- arm64: KVM: Introduce per-vcpu kvm device controls (Wei Huang) [1290593]
- arm64: KVM: Add a new feature bit for PMUv3 (Wei Huang) [1290593]
- arm64: KVM: Free perf event of PMU when destroying vcpu (Wei Huang) [1290593]
- arm64: KVM: Reset PMU state when resetting vcpu (Wei Huang) [1290593]
- arm64: KVM: Add PMU overflow interrupt routing (Wei Huang) [1290593]
- arm64: KVM: Add access handler for PMUSERENR register (Wei Huang) [1290593]
- arm64: KVM: Add helper to handle PMCR register bits (Wei Huang) [1290593]
- arm64: KVM: Add access handler for PMSWINC register (Wei Huang) [1290593]
- arm64: KVM: Add access handler for PMOVSSET and PMOVSCLR register (Wei Huang) [1290593]
- arm64: KVM: Add access handler for PMINTENSET and PMINTENCLR register (Wei Huang) [1290593]
- arm64: KVM: Add access handler for event type register (Wei Huang) [1290593]
- arm64: KVM: PMU: Add perf event map and introduce perf event creating function (Wei Huang) [1290593]
- arm64: KVM: Add access handler for PMCNTENSET and PMCNTENCLR register (Wei Huang) [1290593]
- arm64: KVM: Add access handler for event counter register (Wei Huang) [1290593]
- arm64: KVM: Add access handler for PMCEID0 and PMCEID1 register (Wei Huang) [1290593]
- arm64: KVM: Add access handler for PMSELR register (Wei Huang) [1290593]
- arm64: KVM: Add access handler for PMCR register (Wei Huang) [1290593]
- arm64: KVM: Define PMU data structure for each vcpu (Wei Huang) [1290593]
- arm64: KVM: Add temporary kvm_perf_event.h (Wei Huang) [1290593]
- redhat/config: add CONFIG_ARM64_VHE=y to redhat config (Wei Huang) [1260100]
- arm64: Fix EL1/EL2 early init inconsistencies with VHE (Wei Huang) [1260100]
- arm64: VHE: Add support for running Linux in EL2 mode (Wei Huang) [1260100]
- arm64: hw_breakpoint: Allow EL2 breakpoints if running in HYP (Wei Huang) [1260100]
- arm64: perf: Count EL2 events if the kernel is running in HYP (Wei Huang) [1260100]
- arm64: KVM: Move most of the fault decoding to C (Wei Huang) [1260100]
- arm64: KVM: VHE: Add alternative panic handling (Wei Huang) [1260100]
- arm64: KVM: VHE: Add fpsimd enabling on guest access (Wei Huang) [1260100]
- arm64: KVM: VHE: Use unified sysreg accessors for timer (Wei Huang) [1260100]
- arm64: KVM: VHE: Implement VHE activate/deactivate_traps (Wei Huang) [1260100]
- arm64: KVM: VHE: Make __fpsimd_enabled VHE aware (Wei Huang) [1260100]
- arm64: KVM: VHE: Enable minimal sysreg save/restore (Wei Huang) [1260100]
- arm64: KVM: VHE: Use unified system register accessors (Wei Huang) [1260100]
- arm64: KVM: VHE: Split save/restore of registers shared between guest and host (Wei Huang) [1260100]
- arm64: KVM: VHE: Differenciate host/guest sysreg save/restore (Wei Huang) [1260100]
- arm64: KVM: VHE: Introduce unified system register accessors (Wei Huang) [1260100]
- arm64: KVM: VHE: Patch out kern_hyp_va (Wei Huang) [1260100]
- arm64: KVM: VHE: Patch out use of HVC (Wei Huang) [1260100]
- arm64: KVM: Skip HYP setup when already running in HYP (Wei Huang) [1260100]
- arm64: Add ARM64_HAS_VIRT_HOST_EXTN feature (Wei Huang) [1260100]
- arm64: Allow the arch timer to use the HYP timer (Wei Huang) [1260100]
- arm/arm64: Add new is_kernel_in_hyp_mode predicate (Wei Huang) [1260100]
- arm64: KVM: Switch to C-based stage2 init (Wei Huang) [1260100]
- arm/arm64: KVM: Add hook for C-based stage2 init (Wei Huang) [1260100]
- crypto: ccp - Prevent information leakage on export (Jeffrey Bastian) [1292492]
- crypto: ccp - memset request context to zero during import (Jeffrey Bastian) [1292492]
- crypto: ccp - Don't assume export/import areas are aligned (Jeffrey Bastian) [1292492]
- crypto: ccp - Limit the amount of information exported (Jeffrey Bastian) [1292492]
- crypto: ccp - Add hash state import and export support (Jeffrey Bastian) [1292492]
- arm64: pmu: Detect multiple PMU types in an ACPI system (Jeremy Linton) [10847943]
- arm64: pmu: Add ACPI support for A72 and ThunderX (Jeremy Linton) [10847943]
- arm64/perf: Add Cavium ThunderX PMU support (Jeremy Linton) [10847943]
- arm: arm64: Add routine to determine cpuid of other cpus (Jeremy Linton) [10847943]
- arm64: pmu: Add support for probing with ACPI (Jeremy Linton) [10847943]
- arm64: pmu: add fallback probe table (Jeremy Linton) [10847943]
- arm: pmu: Fix non-devicetree probing (Jeremy Linton) [10847943]
- redhat: Add msalter to ARM64 maintainers (Mark Salter)
- Remove patch .rej files from redhat configs (Wei Huang)

* Tue Apr 05 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-0.33.el7]
- irqchip/GICv3/ITS: Fix ACPI build breakage (Robert Richter) [1240860]
- Add ARM64 architecture maintainers (Mark Langsdorf)
- redhat/config: Add Broadcom Vulcan in arm64 config (Ashok Kumar Sekar) [1321063]
- MAINTAINERS: Add entry for Broadcom Vulcan SoC (Ashok Kumar Sekar) [1321063]
- dt-bindings: Add documentation for Broadcom Vulcan (Ashok Kumar Sekar) [1321063]
- arm64: cputype info for Broadcom Vulcan (Ashok Kumar Sekar) [1321063]
- arm64: Broadcom Vulcan support (Ashok Kumar Sekar) [1321063]
- arm64: defconfig: Add Broadcom Vulcan to defconfig (Ashok Kumar Sekar) [1321063]
- Disable use of /dev/mem completely (Al Stone)

* Mon Mar 21 2016 Mark Langsdorf <mlangsdo@redhat.com> [4.5.0-0.32.el7]
- [redhat] Rebase to 4.5.0 (Mark Langsdorf)
- tty: amba-pl011: Use 32-bit accesses for SBSA UART (Mark Langsdorf)
- perf tools: Fix python extension build (Mark Langsdorf)
- redhat: Add Broadcom Vulcan maintainers to RHMAINTAINERS (Ashok Kumar Sekar) [1312468]
- drivers: net: xgene: fix: Oops in linkwatch_fire_event (Dean Nelson) [1240785]
- drivers: net: xgene: Add shutdown function (Mark Salter) [1203109]
- sata/xgene: support acpi probing (Mark Salter) [1144036, 1243551]
- ahci_xgene: set ATA_HORKAGE_NOLPM for all attached disks (Kyle McMartin) [1229454]
- arm64: Add uprobe support (Pratyush Anand) [1284437]
- arm64: Handle TRAP_BRKPT for user mode as well (Pratyush Anand) [1284437]
- arm64: Handle TRAP_HWBRKPT for user mode as well (Pratyush Anand) [1284437]
- arm64: Add helper for link pointer (Pratyush Anand) [1284437]
- arm64: include asm-generic/ptrace.h in asm/ptrace.h (Pratyush Anand) [1284437]
- arm64: fix kgdb_step_brk_fn to ignore other's exception (Pratyush Anand) [1284437]
- arm64: kprobe: Make arm_probe_decode_insn() global (Pratyush Anand) [1284437]
- uprobe: Add uprobe_pre/post_sstep_notifier to NOKPROBE_SYMBOL (Pratyush Anand) [1284437]
- arm64: Make all entry code as non-kprobe-able (Pratyush Anand) [1284437]
- arm64: Blacklist non-kprobe-able symbols (Pratyush Anand) [1284437]
- kprobes: Add arm64 case in kprobe example module (Pratyush Anand) [1284437]
- arm64: Add kernel return probes support (kretprobes) (Pratyush Anand) [1284437]
- arm64: Add trampoline code for kretprobes (Pratyush Anand) [1284437]
- arm64: kprobes instruction simulation support (Pratyush Anand) [1284437]
- arm64: Kprobes with single stepping support (Pratyush Anand) [1284437]
- arm64: Add more test functions to insn.c (Pratyush Anand) [1284437]
- arm64: Add HAVE_REGS_AND_STACK_ACCESS_API feature (Pratyush Anand) [1284437]
- Consolidate redundant register/stack access code (Pratyush Anand) [1284437]
- Move the pt_regs_offset struct definition from arch to common include file (Pratyush Anand) [1284437]
- DO NOT UPSTREAM: arm64 support Mustang boot protocol (Pratyush Anand) [1282863 1304510]
- ARM64: Add cpu hotplug for ACPI parking method (Pratyush Anand) [1282863 1304510]
- ARM64: kernel: implement ACPI parking protocol (Pratyush Anand) [1282863]
- ARM64: Add cpu hotplug for spin table method (Pratyush Anand) [1282863]
- crashkernel auto reservation code for ARM64 (Pratyush Anand) [1282863]
- arm64: kdump: relax BUG_ON() if more than one cpus are still active (Pratyush Anand) [1282863]
- arm64: kdump: update a kernel doc (Pratyush Anand) [1282863]
- arm64: kdump: enable kdump in the arm64 defconfig (Pratyush Anand) [1282863]
- arm64: kdump: add kdump support (Pratyush Anand) [1282863]
- arm64: kdump: implement machine_crash_shutdown() (Pratyush Anand) [1282863]
- arm64: kdump: reserve memory for crash dump kernel (Pratyush Anand) [1282863]
- arm64/kexec: Add pr_debug output (Pratyush Anand) [1282863]
- arm64/kexec: Enable kexec in the arm64 defconfig (Pratyush Anand) [1282863]
- arm64/kexec: Add core kexec support (Pratyush Anand) [1282863]
- arm64: kvm: allows kvm cpu hotplug (Pratyush Anand) [1282863]
- arm64: add function to install the idmap (Pratyush Anand) [1282863]
- arm64: Add back cpu_reset routines (Pratyush Anand) [1282863]
- arm64: Add new hcall HVC_CALL_FUNC (Pratyush Anand) [1282863]
- arm64: Convert hcalls to use HVC immediate value (Pratyush Anand) [1282863]
- arm64: Cleanup SCTLR flags (Pratyush Anand) [1282863]
- arm64: Add new asm macro copy_page (Pratyush Anand) [1282863]
- arm64: kernel: Include _AC definition in page.h (Pratyush Anand) [1282863]
- arm64: Fold proc-macros.S into assembler.h (Pratyush Anand) [1282863]
- ACPI: scan add call to probe amba devices (Wei Huang) [1290661]
- ACPI: amba bus probing support (Wei Huang) [1290661]
- DOWNSTREAM ONLY: KVM/ACPI: Enable ACPI support for KVM GIC v3 (Wei Huang) [1269594]
- tty: Retry failed reopen if tty teardown in-progress (Pratyush Anand) [1289062]
- kvm, gicv3, acpi: Keep KVM from crashing if gicv3 is present. (Jeremy Linton) [1268423]
- acpi, gicv3, its: Use MADT ITS subtable to do PCI/MSI domain initialization. (Jeremy Linton) [1268423]
- acpi, gicv3, msi: Factor out code that might be reused for ACPI equivalent. (Jeremy Linton) [1268423]
- irqchip, gicv3, its: Probe ITS in the ACPI way. (Jeremy Linton) [1268423]
- ARM64, ACPI, PCI: I/O Remapping Table (IORT) initial support. (Jeremy Linton) [1268423]
- irqchip/GICv3/ITS: Refator ITS dt init code to prepare for ACPI. (Mark Langsdorf)
- irqchip, gicv3, its: Mark its_init() and its children as __init (Jeremy Linton) [1268423]
- irqchip / GICv3: remove gic root node in ITS (Jeremy Linton) [1268423]
- irqchip, GICv3, ACPI: Add redistributor support via GICC structures. (Jeremy Linton) [1268423]
- irqchip / GICv3: Add ACPI support for GICv3+ initialization (Jeremy Linton) [1268423]
- irqchip / GICv3: Refactor gic_of_init() for GICv3 driver (Jeremy Linton) [1268423]
- Update the maintainers file for Huawei company. (Jun Ma) [1289183]
- DO NOT UPSTREAM - pci/xgene: fixups for ACPI support (Mark Salter) [1288635]
- DO NOT UPSTREAM - provide hook for MCFG fixups (Mark Salter) [1288635]
- irqdomain: Introduce irq_domain_get_irqchip_fwnode_name helper function (Mark Salter) [1288635]
- DO NOT UPSTREAM PCI: X-Gene1: Add ACPI MSI support (Mark Salter) [1288635]
- arm64, pci, acpi: Support for ACPI based PCI hostbridge init (Mark Salter) [1288635]
- pci, acpi: Provide generic way to assign bus domain number. (Mark Salter) [1288635]
- x86, pci: Use previously added ECAM hot_added flag to remove ECAM regions. (Mark Salter) [1288635]
- pci, acpi, ecam: Add flag to indicate whether ECAM region was hot added or not. (Mark Salter) [1288635]
- XEN / PCI: Remove the dependence on arch x86 when PCI_MMCONFIG=y (Mark Salter) [1288635]
- pci, acpi, mcfg: Provide default RAW ACPI PCI config space accessors. (Mark Salter) [1288635]
- x86, pci, ecam: mmconfig_64.c becomes default implementation for ECAM driver. (Mark Salter) [1288635]
- x86, pci: mmconfig_{32, 64}.c code refactoring - remove code duplication. (Mark Salter) [1288635]
- pci, acpi, mcfg: Provide generic implementation of MCFG code initialization. (Mark Salter) [1288635]
- x86, pci, acpi: Move arch-agnostic MMCONFIG (aka ECAM) and ACPI code out of arch/x86/ directory (Mark Salter) [1288635]
- x86, pci: Reorder logic of pci_mmconfig_insert() function (Mark Salter) [1288635]
- [redhat] forward port crashkernel auto reservation code (Pratyush Anand) [1282863]
- arm64: KVM: add kvm_register_device_ops() in acpi probing code (Wei Huang) [1259615]
- arm64: perf fixes for 4.1 and 4.2 kernels (Mark Salter) [1243583]
- KVM: fix vgic_v2_acpi_probe (Andrew Jones) [1226348]
- DONOTUPSTREAM: arm64: smp_send_stop: increase CPU stop IPI timeout to 60 seconds (Jon Masters) [1218374]
- arm64: support ACPI tables outside of kernel RAM (Mark Langsdorf) [1219838]
- DO NOT UPSTREAM: move PL011 SBSA init later (Mark Salter)
- acpi: spcr: fix SPCR device address matching (Mark Salter) [1268193]
- tty/console: use SPCR table to define console (Mark Langsdorf)
- arm64: topology: Correct core_id calculation (Don Dutile)
- arm64: don't state topo is unsupported if !acpi (Don Dutile) [1186788]
- ARM64: gic: Do not allow bypass FIQ signals to reach to processor (Pratyush Anand) [1179954]
- DO NOT UPSTREAM: redhat: arm64: topology: Adjust sysfs topology (Don Dutile) [1056268 1127292]
- KVM/ACPI: Enable ACPI support for virt arch timer (Wei Huang) [1144036]
- DO NOT UPSTREAM - Fix xgene gic acpi init (Mark Salter)
- arm/arm64: DT: Fix GICv2 CPU interface size (Don Dutile)
- arm64/perf: add ACPI support (Mark Salter) [1152120]
- crash: enable /dev/crash driver (Mark Langsdorf) [1077329]
- [redhat] Enable MPT3SAS driver (Mark Langsdorf) [1264612]
- redhat: Add Cavium maintainers to RHMAINTAINERS file (Vadim Lomovtsev) [1306420]
- redhat/config, arm64: Enable EHCI controllers that aren't PCIe attached (Jeremy Linton) [1268416]
- arm64: default CPUMASK_OFFSTACK for SMP (Don Dutile)
- [redhat] disable 842 crypto accellerator emulation for ARM64 (Mark Langsdorf) [1254782]
- redhat/config: remove KVM_ARM_MAX_VCPUS (Andrew Jones)
- [redhat] build the ahci_xgene (SATA) driver as a module (Mark Langsdorf) [1264540]
- [redhat] build the amd_xgbe (10Gb Ethernet) driver as a module (Mark Langsdorf) [1264543]
- [redhat] build the ahci-platform (SATA) driver as a module (Mark Langsdorf) [1264544]
- [redhat] config: Enable ACPI parking protocol support (Pratyush Anand) [1282863]
- Add CONFIG_KEXEC_AUTO_RESERVE into generic config (Pratyush Anand) [https://bugzilla.redhat.com/show_bug.cgi?id=1216287]
- config: increase CONFIG_CMA_SIZE_MBYTES from 16 to 64MB (Jon Masters) [1201885]
- Add CRASH_DUMP into generic config (Pratyush Anand)
- arm64/acpi: DO NOT UPSTREAM set ACPI enabled by default (Mark Langsdorf)
- acpi/arm64: remove EXPERT dependency (Mark Salter) [1163947]
- [redhat] Set branches to RHELSA 7.3 and set BUILD_SCRATCH_TARGET (Mark Langsdorf)
- [debuginfo] enable generation (Donald Dutile)
- arm64: remove the now unneeded relocate_initrd() (Mark Langsdorf)
- arm64: add the initrd region to the linear mapping explicitly (Mark Langsdorf)
- memblock: add routine to clear the MEMBLOCK_NOMAP flag for a region (Mark Langsdorf)
- [redhat] Import redhat/ subdirectory (Mark Langsdorf)
- Linux 4.5 (Linus Torvalds)
- mm/mempool: avoid KASAN marking mempool poison checks as use-after-free (Matthew Dawson)
- Revert "drm/radeon: call hpd_irq_event on resume" (Linus Torvalds)