* [PATCH] ACPI: arm64: Calculate size from pointer instead of struct
@ 2024-08-30 7:11 Riyan Dhiman
0 siblings, 0 replies; only message in thread
From: Riyan Dhiman @ 2024-08-30 7:11 UTC (permalink / raw)
To: lpieralisi, guohanjun, sudeep.holla
Cc: linux-acpi, linux-arm-kernel, linux-kernel, Riyan Dhiman
Calculate the size from pointer instead of struct to adhere to
kernel coding style.
Issue reported in checkpatch
This commit has no functional changes.
Signed-off-by: Riyan Dhiman <riyandhiman14@gmail.com>
---
drivers/acpi/arm64/iort.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/acpi/arm64/iort.c b/drivers/acpi/arm64/iort.c
index 1b39e9ae7ac1..6a87ec243c56 100644
--- a/drivers/acpi/arm64/iort.c
+++ b/drivers/acpi/arm64/iort.c
@@ -56,7 +56,7 @@ static inline int iort_set_fwnode(struct acpi_iort_node *iort_node,
{
struct iort_fwnode *np;
- np = kzalloc(sizeof(struct iort_fwnode), GFP_ATOMIC);
+ np = kzalloc(sizeof(*np), GFP_ATOMIC);
if (WARN_ON(!np))
return -ENOMEM;
--
2.46.0
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2024-08-30 7:11 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-08-30 7:11 [PATCH] ACPI: arm64: Calculate size from pointer instead of struct Riyan Dhiman
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®