aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/acpi
diff options
context:
space:
mode:
authorSunil V L <sunilvl@ventanamicro.com>2023-10-18 18:10:05 +0530
committerPalmer Dabbelt <palmer@rivosinc.com>2023-10-26 09:40:32 -0700
commita06835227280436c1aae021a3f43d3abfcba3835 (patch)
tree1363ddf74903717f4b1244fe0cbf66c5cf3ec337 /drivers/acpi
parente8065df5b0c46086ad539beb7745ea26b26a7623 (diff)
downloadlinux-a06835227280436c1aae021a3f43d3abfcba3835.tar.gz
RISC-V: ACPI: Update the return value of acpi_get_rhct()
acpi_get_rhct() currently returns pointer to acpi_table_header structure. But since this is specific to RHCT, return pointer to acpi_table_rhct structure itself. Suggested-by: Andrew Jones <ajones@ventanamicro.com> Signed-off-by: Sunil V L <sunilvl@ventanamicro.com> Reviewed-by: Andrew Jones <ajones@ventanamicro.com> Link: https://lore.kernel.org/r/20231018124007.1306159-3-sunilvl@ventanamicro.com Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>
Diffstat (limited to 'drivers/acpi')
-rw-r--r--drivers/acpi/riscv/rhct.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/acpi/riscv/rhct.c b/drivers/acpi/riscv/rhct.c
index b280b3e9c7d94..489b0e93b1e5f 100644
--- a/drivers/acpi/riscv/rhct.c
+++ b/drivers/acpi/riscv/rhct.c
@@ -9,7 +9,7 @@
#include <linux/acpi.h>
-static struct acpi_table_header *acpi_get_rhct(void)
+static struct acpi_table_rhct *acpi_get_rhct(void)
{
static struct acpi_table_header *rhct;
acpi_status status;
@@ -26,7 +26,7 @@ static struct acpi_table_header *acpi_get_rhct(void)
}
}
- return rhct;
+ return (struct acpi_table_rhct *)rhct;
}
/*
@@ -48,7 +48,7 @@ int acpi_get_riscv_isa(struct acpi_table_header *table, unsigned int cpu, const
BUG_ON(acpi_disabled);
if (!table) {
- rhct = (struct acpi_table_rhct *)acpi_get_rhct();
+ rhct = acpi_get_rhct();
if (!rhct)
return -ENOENT;
} else {