mirror of
https://github.com/SCST-project/scst.git
synced 2026-05-14 09:11:27 +00:00
Merge branch 'svn-trunk'
This commit is contained in:
@@ -113,13 +113,21 @@ function specialize_patch {
|
||||
set -- ${release//./ }
|
||||
local releasevermajor="$1"
|
||||
local releaseverminor="$2"
|
||||
if [ -n "$releasevermajor" ]; then
|
||||
ao=(
|
||||
-v "RHEL_MAJOR=$releasevermajor"
|
||||
-v "RHEL_MINOR=$releaseverminor"
|
||||
-v "RHEL_RELEASE_CODE=$((releasevermajor * 256 + releaseverminor))"
|
||||
)
|
||||
fi
|
||||
case "$distro" in
|
||||
CentOS)
|
||||
if [ -n "$releasevermajor" ]; then
|
||||
ao=(
|
||||
-v "RHEL_MAJOR=$releasevermajor"
|
||||
-v "RHEL_MINOR=$releaseverminor"
|
||||
-v "RHEL_RELEASE_CODE=$((releasevermajor * 256 +
|
||||
releaseverminor))"
|
||||
)
|
||||
fi
|
||||
;;
|
||||
UEK)
|
||||
ao=(-v UEK_KABI_RENAME=1)
|
||||
;;
|
||||
esac
|
||||
local kver3
|
||||
set -- ${kver//[.-]/ }
|
||||
if [ -n "$3" ]; then
|
||||
|
||||
@@ -620,6 +620,29 @@ index 8fa38d3e7538..f5bc4c046461 100644
|
||||
|
||||
EOF
|
||||
;;
|
||||
4.1.12-*uek)
|
||||
echo "Patching init.h ..."
|
||||
patch -f -s -p1 <<'EOF'
|
||||
--- linux-4.1.12-124.45.6.el7uek/include/linux/init.h.orig
|
||||
+++ linux-4.1.12-124.45.6.el7uek/include/linux/init.h
|
||||
@@ -347,13 +347,13 @@
|
||||
#define module_init(initfn) \
|
||||
static inline initcall_t __inittest(void) \
|
||||
{ return initfn; } \
|
||||
- int init_module(void) __attribute__((alias(#initfn)));
|
||||
+ int init_module(void) __attribute__((__copy__(initfn)));
|
||||
|
||||
/* This is only required if you want to be unloadable. */
|
||||
#define module_exit(exitfn) \
|
||||
static inline exitcall_t __exittest(void) \
|
||||
{ return exitfn; } \
|
||||
- void cleanup_module(void) __attribute__((alias(#exitfn)));
|
||||
+ void cleanup_module(void) __attribute__((__copy__(exitfn)));
|
||||
|
||||
#define __setup_param(str, unique_id, fn) /* nothing */
|
||||
#define __setup(str, func) /* nothing */
|
||||
EOF
|
||||
;;
|
||||
2.*|3.*)
|
||||
patch -f -s -p1 <<'EOF'
|
||||
--- linux-3.10.0-1127.el7/include/linux/init.h.orig 2020-05-09 20:55:48.638956513 -0700
|
||||
|
||||
@@ -268,8 +268,11 @@ CONFIG_BINARY_PRINTF \
|
||||
CONFIG_BLK_DEV_IO_TRACE \
|
||||
CONFIG_BRANCH_PROFILE_NONE \
|
||||
CONFIG_CONTEXT_SWITCH_TRACER \
|
||||
CONFIG_CTF \
|
||||
CONFIG_DEBUG_SECTION_MISMATCH \
|
||||
CONFIG_DEBUG_STRICT_USER_COPY_CHECKS \
|
||||
CONFIG_DTRACE \
|
||||
CONFIG_DT_CORE \
|
||||
CONFIG_DYNAMIC_FTRACE \
|
||||
CONFIG_EVENT_TRACE_TEST_SYSCALLS \
|
||||
CONFIG_FTRACE \
|
||||
@@ -287,6 +290,7 @@ CONFIG_HEADERS_CHECK \
|
||||
CONFIG_IRQSOFF_TRACER \
|
||||
CONFIG_IWLWIFI_DEVICE_TRACING \
|
||||
CONFIG_IWM_TRACING \
|
||||
CONFIG_KALLMODSYMS \
|
||||
CONFIG_KVM_MMU_AUDIT \
|
||||
CONFIG_MAC80211_DRIVER_API_TRACER \
|
||||
CONFIG_MMIOTRACE \
|
||||
|
||||
@@ -69,7 +69,8 @@ function evaluate(stmnt, pattern, arg, op, result) {
|
||||
"RHEL_RELEASE_CODE -0 >= 6 * 256 + 9)", stmnt)
|
||||
|
||||
gsub("SOCK_RECVMSG_HAS_FOUR_ARGS",
|
||||
"(LINUX_VERSION_CODE < KERNEL_VERSION(4, 7, 0))", stmnt)
|
||||
"(LINUX_VERSION_CODE < KERNEL_VERSION(4, 7, 0) \\&\\& " \
|
||||
"!defined(UEK_KABI_RENAME))", stmnt)
|
||||
|
||||
gsub("defined\\(USE_PRE_440_WR_STRUCTURE\\)",
|
||||
"(LINUX_VERSION_CODE < KERNEL_VERSION(4, 4, 0) \\&\\& " \
|
||||
@@ -236,7 +237,7 @@ function evaluate(stmnt, pattern, arg, op, result) {
|
||||
}
|
||||
|
||||
gsub("defined\\(_COMPAT_LINUX_MM_H\\)", "0", stmnt)
|
||||
gsub("defined\\(UEK_KABI_RENAME\\)", "0", stmnt)
|
||||
gsub("defined\\(UEK_KABI_RENAME\\)", UEK_KABI_RENAME ? "1" : "0", stmnt)
|
||||
|
||||
if (SCST_IO_CONTEXT != "")
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user