]> git.ipfire.org Git - thirdparty/linux.git/commit
powerpc: fadump: pair alloc_pages_exact() with free_pages_exact()
authorMike Rapoport (Microsoft) <rppt@kernel.org>
Mon, 23 Mar 2026 07:48:29 +0000 (09:48 +0200)
committerMike Rapoport (Microsoft) <rppt@kernel.org>
Wed, 1 Apr 2026 08:19:45 +0000 (11:19 +0300)
commit25ee3aff9996f22e1b8b27fb284efb285e2fb025
treee242b6ee01af0c12fea6310a961c1fd79831c01e
parentc12c3e1507809ad1fc0448f51c933f52e17d13cd
powerpc: fadump: pair alloc_pages_exact() with free_pages_exact()

fadump allocates buffers with alloc_pages_exact(), but then marks them
as reserved and frees using free_reserved_area().

This is completely unnecessary and the pages allocated with
alloc_pages_exact() can be naturally freed with free_pages_exact().

Replace freeing of memory in fadump_free_buffer() with
free_pages_exact() and simplify allocation code so that it won't mark
allocated pages as reserved.

Link: https://patch.msgid.link/20260323074836.3653702-3-rppt@kernel.org
Signed-off-by: Mike Rapoport (Microsoft) <rppt@kernel.org>
arch/powerpc/kernel/fadump.c