Thread (3 messages) flat view 3 messages, 2 authors, 2025-10-29

Re: [PATCH v3] powerpc/kdump: Add support for crashkernel CMA reservation

From: Jiri Bohac <hidden>
Date: 2025-10-29 14:03:20

On Fri, Oct 24, 2025 at 10:31:18PM +0530, Sourabh Jain wrote:
+static int crash_exclude_mem_range_guarded(struct crash_mem **mem_ranges,
+					   unsigned long long mstart,
+					   unsigned long long mend)
+{
+	struct crash_mem *tmem = *mem_ranges;
+
+	/* Reallocate memory ranges if there is no space to split ranges */
+	tmem = *mem_ranges;
repeated initialization
+	if (tmem && (tmem->nr_ranges == tmem->max_nr_ranges)) {
+		tmem = realloc_mem_ranges(mem_ranges);
+		if (!tmem)
+			return -ENOMEM;
+	}
+
+	return crash_exclude_mem_range(tmem, crashk_res.start, crashk_res.end);
mstart and mend, not crashk_res.start and crashk_res.end

-- 
Jiri Bohac [off-list ref]
SUSE Labs, Prague, Czechia

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help