diff mbox series

acpi: pptt: constify read-only function arguments

Message ID 20210529005745.1800793-1-alex.hung@canonical.com
State Accepted
Headers show
Series acpi: pptt: constify read-only function arguments | expand

Commit Message

Alex Hung May 29, 2021, 12:57 a.m. UTC
Also breaks functions to multiple lines.

Signed-off-by: Alex Hung <alex.hung@canonical.com>
---
 src/acpi/pptt/pptt.c | 17 ++++++++++++++---
 1 file changed, 14 insertions(+), 3 deletions(-)

Comments

ivanhu May 31, 2021, 7:08 a.m. UTC | #1
On 5/29/21 8:57 AM, Alex Hung wrote:
> Also breaks functions to multiple lines.
> 
> Signed-off-by: Alex Hung <alex.hung@canonical.com>
> ---
>  src/acpi/pptt/pptt.c | 17 ++++++++++++++---
>  1 file changed, 14 insertions(+), 3 deletions(-)
> 
> diff --git a/src/acpi/pptt/pptt.c b/src/acpi/pptt/pptt.c
> index 8a126ff9..56394660 100644
> --- a/src/acpi/pptt/pptt.c
> +++ b/src/acpi/pptt/pptt.c
> @@ -26,7 +26,11 @@
>  static fwts_acpi_table_info *table;
>  acpi_table_init(PPTT, &table)
>  
> -static void pptt_processor_test(fwts_framework *fw, const fwts_acpi_table_pptt_processor *entry, uint8_t rev, bool *passed)
> +static void pptt_processor_test(
> +	fwts_framework *fw,
> +	const fwts_acpi_table_pptt_processor *entry,
> +	const uint8_t rev,
> +	bool *passed)
>  {
>  	fwts_log_info_verbatim(fw, "  Processor hierarchy node structure (Type 0):");
>  	fwts_log_info_simp_int(fw, "    Type:                           ", entry->header.type);
> @@ -60,7 +64,11 @@ static void pptt_processor_test(fwts_framework *fw, const fwts_acpi_table_pptt_p
>  
>  }
>  
> -static void pptt_cache_test(fwts_framework *fw, const fwts_acpi_table_pptt_cache *entry, uint8_t rev, bool *passed)
> +static void pptt_cache_test(
> +	fwts_framework *fw,
> +	const fwts_acpi_table_pptt_cache *entry,
> +	const uint8_t rev,
> +	bool *passed)
>  {
>  
>  	fwts_log_info_verbatim(fw, "  Cache Type Structure (Type 1):");
> @@ -87,7 +95,10 @@ static void pptt_cache_test(fwts_framework *fw, const fwts_acpi_table_pptt_cache
>  	fwts_acpi_reserved_bits("PPTT", "Attributes", entry->attributes, 5, 7, passed);
>  }
>  
> -static void pptt_id_test(fwts_framework *fw, const fwts_acpi_table_pptt_id *entry, bool *passed)
> +static void pptt_id_test(
> +	fwts_framework *fw,
> +	const fwts_acpi_table_pptt_id *entry,
> +	bool *passed)
>  {
>  	char vendor_id[5];
>  
> 


Acked-by: Ivan Hu <ivan.hu@canonical.com>
Colin Ian King June 1, 2021, 9:40 a.m. UTC | #2
On 29/05/2021 01:57, Alex Hung wrote:
> Also breaks functions to multiple lines.
> 
> Signed-off-by: Alex Hung <alex.hung@canonical.com>
> ---
>  src/acpi/pptt/pptt.c | 17 ++++++++++++++---
>  1 file changed, 14 insertions(+), 3 deletions(-)
> 
> diff --git a/src/acpi/pptt/pptt.c b/src/acpi/pptt/pptt.c
> index 8a126ff9..56394660 100644
> --- a/src/acpi/pptt/pptt.c
> +++ b/src/acpi/pptt/pptt.c
> @@ -26,7 +26,11 @@
>  static fwts_acpi_table_info *table;
>  acpi_table_init(PPTT, &table)
>  
> -static void pptt_processor_test(fwts_framework *fw, const fwts_acpi_table_pptt_processor *entry, uint8_t rev, bool *passed)
> +static void pptt_processor_test(
> +	fwts_framework *fw,
> +	const fwts_acpi_table_pptt_processor *entry,
> +	const uint8_t rev,
> +	bool *passed)
>  {
>  	fwts_log_info_verbatim(fw, "  Processor hierarchy node structure (Type 0):");
>  	fwts_log_info_simp_int(fw, "    Type:                           ", entry->header.type);
> @@ -60,7 +64,11 @@ static void pptt_processor_test(fwts_framework *fw, const fwts_acpi_table_pptt_p
>  
>  }
>  
> -static void pptt_cache_test(fwts_framework *fw, const fwts_acpi_table_pptt_cache *entry, uint8_t rev, bool *passed)
> +static void pptt_cache_test(
> +	fwts_framework *fw,
> +	const fwts_acpi_table_pptt_cache *entry,
> +	const uint8_t rev,
> +	bool *passed)
>  {
>  
>  	fwts_log_info_verbatim(fw, "  Cache Type Structure (Type 1):");
> @@ -87,7 +95,10 @@ static void pptt_cache_test(fwts_framework *fw, const fwts_acpi_table_pptt_cache
>  	fwts_acpi_reserved_bits("PPTT", "Attributes", entry->attributes, 5, 7, passed);
>  }
>  
> -static void pptt_id_test(fwts_framework *fw, const fwts_acpi_table_pptt_id *entry, bool *passed)
> +static void pptt_id_test(
> +	fwts_framework *fw,
> +	const fwts_acpi_table_pptt_id *entry,
> +	bool *passed)
>  {
>  	char vendor_id[5];
>  
> 
Acked-by: Colin Ian King <colin.king@canonical.com>
diff mbox series

Patch

diff --git a/src/acpi/pptt/pptt.c b/src/acpi/pptt/pptt.c
index 8a126ff9..56394660 100644
--- a/src/acpi/pptt/pptt.c
+++ b/src/acpi/pptt/pptt.c
@@ -26,7 +26,11 @@ 
 static fwts_acpi_table_info *table;
 acpi_table_init(PPTT, &table)
 
-static void pptt_processor_test(fwts_framework *fw, const fwts_acpi_table_pptt_processor *entry, uint8_t rev, bool *passed)
+static void pptt_processor_test(
+	fwts_framework *fw,
+	const fwts_acpi_table_pptt_processor *entry,
+	const uint8_t rev,
+	bool *passed)
 {
 	fwts_log_info_verbatim(fw, "  Processor hierarchy node structure (Type 0):");
 	fwts_log_info_simp_int(fw, "    Type:                           ", entry->header.type);
@@ -60,7 +64,11 @@  static void pptt_processor_test(fwts_framework *fw, const fwts_acpi_table_pptt_p
 
 }
 
-static void pptt_cache_test(fwts_framework *fw, const fwts_acpi_table_pptt_cache *entry, uint8_t rev, bool *passed)
+static void pptt_cache_test(
+	fwts_framework *fw,
+	const fwts_acpi_table_pptt_cache *entry,
+	const uint8_t rev,
+	bool *passed)
 {
 
 	fwts_log_info_verbatim(fw, "  Cache Type Structure (Type 1):");
@@ -87,7 +95,10 @@  static void pptt_cache_test(fwts_framework *fw, const fwts_acpi_table_pptt_cache
 	fwts_acpi_reserved_bits("PPTT", "Attributes", entry->attributes, 5, 7, passed);
 }
 
-static void pptt_id_test(fwts_framework *fw, const fwts_acpi_table_pptt_id *entry, bool *passed)
+static void pptt_id_test(
+	fwts_framework *fw,
+	const fwts_acpi_table_pptt_id *entry,
+	bool *passed)
 {
 	char vendor_id[5];