[PATCH] acpi: method: _CST test checks for wrong number of package elements
IvanHu
ivan.hu at canonical.com
Thu Jan 31 07:32:33 UTC 2013
On 01/09/2013 03:52 AM, Colin King wrote:
> From: Colin Ian King <colin.king at canonical.com>
>
> After running this through some of the various tables in my collection
> I discovered that the _CST test checks for the number of elements
> incorrectly. This fixes an off-by-one error.
>
> Signed-off-by: Colin Ian King <colin.king at canonical.com>
> ---
> src/acpi/method/method.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/acpi/method/method.c b/src/acpi/method/method.c
> index 2ac3155..fd7aac0 100644
> --- a/src/acpi/method/method.c
> +++ b/src/acpi/method/method.c
> @@ -2423,7 +2423,7 @@ static void method_test_CST_return(
> return;
>
> /* _CST has at least two elements */
> - if (obj->Package.Count < 3) {
> + if (obj->Package.Count < 2) {
> fwts_failed(fw, LOG_LEVEL_MEDIUM, "Method_CSTElementCount",
> "%s should return package of at least 2 elements, "
> "got %" PRIu32 " elements instead.",
>
Acked-by: Ivan Hu <ivan.hu at canonical.com>
More information about the fwts-devel
mailing list