linux-acpi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ACPI / DPTF: Use ACPI_FREE() for ACPI buffer deallocation
@ 2025-10-06  4:53 Kaushlendra Kumar
  2025-10-22 19:01 ` Rafael J. Wysocki
  0 siblings, 1 reply; 3+ messages in thread
From: Kaushlendra Kumar @ 2025-10-06  4:53 UTC (permalink / raw)
  To: rafael, rui.zhang, srinivas.pandruvada, lenb
  Cc: linux-acpi, Kaushlendra Kumar

Replace kfree() with ACPI_FREE() in pch_fivr_read() for deallocating
ACPI buffer objects. The buffer.pointer contains an ACPI object allocated
through ACPI subsystem functions and should be freed using ACPI_FREE()
to ensure proper cleanup and maintain consistency with ACPI memory
management conventions.

Signed-off-by: Kaushlendra Kumar <kaushlendra.kumar@intel.com>
---
 drivers/acpi/dptf/dptf_pch_fivr.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/acpi/dptf/dptf_pch_fivr.c b/drivers/acpi/dptf/dptf_pch_fivr.c
index 952216c67d58..8d7e555929d3 100644
--- a/drivers/acpi/dptf/dptf_pch_fivr.c
+++ b/drivers/acpi/dptf/dptf_pch_fivr.c
@@ -41,7 +41,7 @@ static int pch_fivr_read(acpi_handle handle, char *method, struct pch_fivr_resp
 	ret = 0;
 
 release_buffer:
-	kfree(buffer.pointer);
+	ACPI_FREE(buffer.pointer);
 	return ret;
 }
 
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2025-10-28  5:20 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-10-06  4:53 [PATCH] ACPI / DPTF: Use ACPI_FREE() for ACPI buffer deallocation Kaushlendra Kumar
2025-10-22 19:01 ` Rafael J. Wysocki
2025-10-28  5:20   ` Kumar, Kaushlendra

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).