diff mbox series

lib: fix offset error for GPIO connection descriptor

Message ID 1508366643-1475-1-git-send-email-alex.hung@canonical.com
State Accepted
Headers show
Series lib: fix offset error for GPIO connection descriptor | expand

Commit Message

Alex Hung Oct. 18, 2017, 10:44 p.m. UTC
Table reference is also removed because it changes very frequently when
ACPI spec updates

Signed-off-by: Alex Hung <alex.hung@canonical.com>
---
 src/lib/src/fwts_acpi_object_eval.c | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

Comments

Colin Ian King Oct. 20, 2017, 4:35 p.m. UTC | #1
On 19/10/17 00:44, Alex Hung wrote:
> Table reference is also removed because it changes very frequently when
> ACPI spec updates
> 
> Signed-off-by: Alex Hung <alex.hung@canonical.com>
> ---
>  src/lib/src/fwts_acpi_object_eval.c | 7 +++----
>  1 file changed, 3 insertions(+), 4 deletions(-)
> 
> diff --git a/src/lib/src/fwts_acpi_object_eval.c b/src/lib/src/fwts_acpi_object_eval.c
> index d980fd6..1151f4a 100644
> --- a/src/lib/src/fwts_acpi_object_eval.c
> +++ b/src/lib/src/fwts_acpi_object_eval.c
> @@ -1557,15 +1557,14 @@ void fwts_method_test_CRS_large_resource_items(
>  			fwts_failed(fw, LOG_LEVEL_MEDIUM, tmp,
>  				"%s GPIO Connection Descriptor has an invalid "
>  				"Connection Type 0x%" PRIx8 ".",
> -				name, data[2]);
> +				name, data[4]);
>  			*passed = false;
>  			fwts_advice(fw,
>  				"The GPIO pin connection type is "
>  				"not recognised. It should be either "
>  				"0x00 (interrupt connection) or "
> -				"0x01 (I/O connection). See table "
> -				"6-189 in section 6.4.3.8.1 of the ACPI "
> -                                "specification.");
> +				"0x01 (I/O connection). See section "
> +				"6.4.3.8.1 of the ACPI specification.");
>  		}
>  		if ((data[9] > 0x03) && (data[9] < 0x80)) {
>  			snprintf(tmp, sizeof(tmp), "Method%sGpioConnTypeInvalid", objname);
> 
Thanks Alex,

Acked-by: Colin Ian King <colin.king@canonical.com>
Ivan Hu Oct. 25, 2017, 6:40 a.m. UTC | #2
On 10/19/2017 06:44 AM, Alex Hung wrote:
> Table reference is also removed because it changes very frequently when
> ACPI spec updates
> 
> Signed-off-by: Alex Hung <alex.hung@canonical.com>
> ---
>   src/lib/src/fwts_acpi_object_eval.c | 7 +++----
>   1 file changed, 3 insertions(+), 4 deletions(-)
> 
> diff --git a/src/lib/src/fwts_acpi_object_eval.c b/src/lib/src/fwts_acpi_object_eval.c
> index d980fd6..1151f4a 100644
> --- a/src/lib/src/fwts_acpi_object_eval.c
> +++ b/src/lib/src/fwts_acpi_object_eval.c
> @@ -1557,15 +1557,14 @@ void fwts_method_test_CRS_large_resource_items(
>   			fwts_failed(fw, LOG_LEVEL_MEDIUM, tmp,
>   				"%s GPIO Connection Descriptor has an invalid "
>   				"Connection Type 0x%" PRIx8 ".",
> -				name, data[2]);
> +				name, data[4]);
>   			*passed = false;
>   			fwts_advice(fw,
>   				"The GPIO pin connection type is "
>   				"not recognised. It should be either "
>   				"0x00 (interrupt connection) or "
> -				"0x01 (I/O connection). See table "
> -				"6-189 in section 6.4.3.8.1 of the ACPI "
> -                                "specification.");
> +				"0x01 (I/O connection). See section "
> +				"6.4.3.8.1 of the ACPI specification.");
>   		}
>   		if ((data[9] > 0x03) && (data[9] < 0x80)) {
>   			snprintf(tmp, sizeof(tmp), "Method%sGpioConnTypeInvalid", objname);
> 

Acked-by: Ivan Hu <ivan.hu@canonical.com>
diff mbox series

Patch

diff --git a/src/lib/src/fwts_acpi_object_eval.c b/src/lib/src/fwts_acpi_object_eval.c
index d980fd6..1151f4a 100644
--- a/src/lib/src/fwts_acpi_object_eval.c
+++ b/src/lib/src/fwts_acpi_object_eval.c
@@ -1557,15 +1557,14 @@  void fwts_method_test_CRS_large_resource_items(
 			fwts_failed(fw, LOG_LEVEL_MEDIUM, tmp,
 				"%s GPIO Connection Descriptor has an invalid "
 				"Connection Type 0x%" PRIx8 ".",
-				name, data[2]);
+				name, data[4]);
 			*passed = false;
 			fwts_advice(fw,
 				"The GPIO pin connection type is "
 				"not recognised. It should be either "
 				"0x00 (interrupt connection) or "
-				"0x01 (I/O connection). See table "
-				"6-189 in section 6.4.3.8.1 of the ACPI "
-                                "specification.");
+				"0x01 (I/O connection). See section "
+				"6.4.3.8.1 of the ACPI specification.");
 		}
 		if ((data[9] > 0x03) && (data[9] < 0x80)) {
 			snprintf(tmp, sizeof(tmp), "Method%sGpioConnTypeInvalid", objname);