Blame SOURCES/v0.9.2-backport-MR-1281-create-diff-object-add-suppo.patch

c9a31f
From d98f100dc979f87296ec88b63a0d506aaf4cd2bd Mon Sep 17 00:00:00 2001
c9a31f
From: Joe Lawrence <joe.lawrence@redhat.com>
c9a31f
Date: Thu, 8 Dec 2022 12:31:17 -0500
c9a31f
Subject: [PATCH] v0.9.2 backport: MR!1281 ("create-diff-object: add support
c9a31f
 for .return_sites section (x86)")
c9a31f
Content-type: text/plain
c9a31f
c9a31f
commit 33368a88cdf875b0edd02b0dfd3356a7e93b24db
c9a31f
Author: Jonathan Dobson <jdobson@redhat.com>
c9a31f
Date:   Sat Jul 16 15:46:54 2022 -0600
c9a31f
c9a31f
    create-diff-object: add support for .return_sites section (x86)
c9a31f
c9a31f
    Conflicts:
c9a31f
    	kpatch-build/create-diff-object.c
c9a31f
	- Manually apply patch to avoid diff context, v0.9.2 structure
c9a31f
	  special_section structure doesn't have .arch
c9a31f
c9a31f
Signed-off-by: Joe Lawrence <joe.lawrence@redhat.com>
c9a31f
---
c9a31f
 kpatch-build/create-diff-object.c | 10 ++++++++++
c9a31f
 1 file changed, 10 insertions(+)
c9a31f
c9a31f
diff --git a/kpatch-build/create-diff-object.c b/kpatch-build/create-diff-object.c
c9a31f
index cee8adf333dc..c9afe33bbdae 100644
c9a31f
--- a/kpatch-build/create-diff-object.c
c9a31f
+++ b/kpatch-build/create-diff-object.c
c9a31f
@@ -1991,6 +1991,11 @@ static int altinstructions_group_size(struct kpatch_elf *kelf, int offset)
c9a31f
 	return size;
c9a31f
 }
c9a31f
 
c9a31f
+static int return_sites_group_size(struct kpatch_elf *kelf, int offset)
c9a31f
+{
c9a31f
+	return 4;
c9a31f
+}
c9a31f
+
c9a31f
 static int smp_locks_group_size(struct kpatch_elf *kelf, int offset)
c9a31f
 {
c9a31f
 	return 4;
c9a31f
@@ -2103,6 +2108,11 @@ static struct special_section special_sections[] = {
c9a31f
 		.name		= ".altinstructions",
c9a31f
 		.group_size	= altinstructions_group_size,
c9a31f
 	},
c9a31f
+	{
c9a31f
+		.name		= ".return_sites",
c9a31f
+		.group_size	= return_sites_group_size,
c9a31f
+	},
c9a31f
+
c9a31f
 #endif
c9a31f
 #ifdef __powerpc64__
c9a31f
 	{
c9a31f
-- 
c9a31f
2.38.1
c9a31f