lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Wed, 18 Oct 2023 15:05:29 +0200
From:   Andrew Jones <ajones@...tanamicro.com>
To:     Sunil V L <sunilvl@...tanamicro.com>
Cc:     linux-riscv@...ts.infradead.org, linux-kernel@...r.kernel.org,
        linux-acpi@...r.kernel.org,
        Paul Walmsley <paul.walmsley@...ive.com>,
        Palmer Dabbelt <palmer@...belt.com>,
        Albert Ou <aou@...s.berkeley.edu>,
        "Rafael J . Wysocki" <rafael@...nel.org>,
        Len Brown <lenb@...nel.org>,
        Conor Dooley <conor.dooley@...rochip.com>,
        Anup Patel <apatel@...tanamicro.com>
Subject: Re: [PATCH v4 -next 2/4] RISC-V: ACPI: Update the return value of
 acpi_get_rhct()

On Wed, Oct 18, 2023 at 06:10:05PM +0530, Sunil V L wrote:
> 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@...tanamicro.com>
> Signed-off-by: Sunil V L <sunilvl@...tanamicro.com>
> ---
>  drivers/acpi/riscv/rhct.c | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/acpi/riscv/rhct.c b/drivers/acpi/riscv/rhct.c
> index b280b3e9c7d9..489b0e93b1e5 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 {
> -- 
> 2.39.2
>

Reviewed-by: Andrew Jones <ajones@...tanamicro.com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ