diff mbox

[1/3] acpi: method: add _GAI control method test (LP: #1249894)

Message ID 1384146340-2695-1-git-send-email-alex.hung@canonical.com
State Accepted
Headers show

Commit Message

Alex Hung Nov. 11, 2013, 5:05 a.m. UTC
Signed-off-by: Alex Hung <alex.hung@canonical.com>
---
 src/acpi/method/method.c | 13 +++++++++++--
 1 file changed, 11 insertions(+), 2 deletions(-)

Comments

Colin Ian King Nov. 11, 2013, 9:14 a.m. UTC | #1
On 11/11/13 05:05, Alex Hung wrote:
> Signed-off-by: Alex Hung <alex.hung@canonical.com>
> ---
>  src/acpi/method/method.c | 13 +++++++++++--
>  1 file changed, 11 insertions(+), 2 deletions(-)
> 
> diff --git a/src/acpi/method/method.c b/src/acpi/method/method.c
> index f46fdff..14a908a 100644
> --- a/src/acpi/method/method.c
> +++ b/src/acpi/method/method.c
> @@ -100,7 +100,7 @@
>   * _FPS  11.3.1.2	N
>   * _FSL  11.3.1.3	Y
>   * _FST  11.3.1.4	Y
> - * _GAI  10.4.5		N
> + * _GAI  10.4.5		Y
>   * _GCP  9.18.2		Y
>   * _GHL  10.4.7		N
>   * _GL   5.7.1		n/a
> @@ -3993,6 +3993,15 @@ static int method_test_PIF(fwts_framework *fw)
>  		"_PIF", NULL, 0, method_test_PIF_return, NULL);
>  }
>  
> +/*
> + * Section 10.4 Power Meters 
> + */
> +
> +static int method_test_GAI(fwts_framework *fw)
> +{
> +	return method_evaluate_method(fw, METHOD_OPTIONAL,
> +		"_GAI", NULL, 0, method_test_integer_return, NULL);
> +}
>  
>  /*
>   * Section 11.3 Fan Devices
> @@ -5002,7 +5011,7 @@ static fwts_framework_minor_test method_tests[] = {
>  	{ method_test_PSR, "Check _PSR (Power Source)." },
>  
>  	/* Section 10.4 Power Meters */
> -	/* { method_test_GAI, "Check _GAI (Get Averaging Level)." }, */
> +	{ method_test_GAI, "Check _GAI (Get Averaging Level)." },
>  	/* { method_test_GHL, "Check _GHL (Get Harware Limit)." }, */
>  	/* { method_test_PAI, "Check _PAI (Power Averaging Interval)." }, */
>  	/* { method_test_PMC, "Check _PMC (Power Meter Capabilities)." }, */
> 

Acked-by: Colin Ian King <colin.king@canonical.com>
Keng-Yu Lin Nov. 12, 2013, 7:28 a.m. UTC | #2
On Mon, Nov 11, 2013 at 1:05 PM, Alex Hung <alex.hung@canonical.com> wrote:
> Signed-off-by: Alex Hung <alex.hung@canonical.com>
> ---
>  src/acpi/method/method.c | 13 +++++++++++--
>  1 file changed, 11 insertions(+), 2 deletions(-)
>
> diff --git a/src/acpi/method/method.c b/src/acpi/method/method.c
> index f46fdff..14a908a 100644
> --- a/src/acpi/method/method.c
> +++ b/src/acpi/method/method.c
> @@ -100,7 +100,7 @@
>   * _FPS  11.3.1.2      N
>   * _FSL  11.3.1.3      Y
>   * _FST  11.3.1.4      Y
> - * _GAI  10.4.5                N
> + * _GAI  10.4.5                Y
>   * _GCP  9.18.2                Y
>   * _GHL  10.4.7                N
>   * _GL   5.7.1         n/a
> @@ -3993,6 +3993,15 @@ static int method_test_PIF(fwts_framework *fw)
>                 "_PIF", NULL, 0, method_test_PIF_return, NULL);
>  }
>
> +/*
> + * Section 10.4 Power Meters
> + */
> +
> +static int method_test_GAI(fwts_framework *fw)
> +{
> +       return method_evaluate_method(fw, METHOD_OPTIONAL,
> +               "_GAI", NULL, 0, method_test_integer_return, NULL);
> +}
>
>  /*
>   * Section 11.3 Fan Devices
> @@ -5002,7 +5011,7 @@ static fwts_framework_minor_test method_tests[] = {
>         { method_test_PSR, "Check _PSR (Power Source)." },
>
>         /* Section 10.4 Power Meters */
> -       /* { method_test_GAI, "Check _GAI (Get Averaging Level)." }, */
> +       { method_test_GAI, "Check _GAI (Get Averaging Level)." },
>         /* { method_test_GHL, "Check _GHL (Get Harware Limit)." }, */
>         /* { method_test_PAI, "Check _PAI (Power Averaging Interval)." }, */
>         /* { method_test_PMC, "Check _PMC (Power Meter Capabilities)." }, */
> --
> 1.8.3.2
>

Acked-by: Keng-Yu Lin <kengyu@canonical.com>
Colin Ian King Nov. 14, 2013, 3:46 p.m. UTC | #3
On 11/11/13 05:05, Alex Hung wrote:
> Signed-off-by: Alex Hung <alex.hung@canonical.com>
> ---
>  src/acpi/method/method.c | 13 +++++++++++--
>  1 file changed, 11 insertions(+), 2 deletions(-)
> 
> diff --git a/src/acpi/method/method.c b/src/acpi/method/method.c
> index f46fdff..14a908a 100644
> --- a/src/acpi/method/method.c
> +++ b/src/acpi/method/method.c
> @@ -100,7 +100,7 @@
>   * _FPS  11.3.1.2	N
>   * _FSL  11.3.1.3	Y
>   * _FST  11.3.1.4	Y
> - * _GAI  10.4.5		N
> + * _GAI  10.4.5		Y
>   * _GCP  9.18.2		Y
>   * _GHL  10.4.7		N
>   * _GL   5.7.1		n/a
> @@ -3993,6 +3993,15 @@ static int method_test_PIF(fwts_framework *fw)
>  		"_PIF", NULL, 0, method_test_PIF_return, NULL);
>  }
>  
> +/*
> + * Section 10.4 Power Meters 
> + */
> +
> +static int method_test_GAI(fwts_framework *fw)
> +{
> +	return method_evaluate_method(fw, METHOD_OPTIONAL,
> +		"_GAI", NULL, 0, method_test_integer_return, NULL);
> +}
>  
>  /*
>   * Section 11.3 Fan Devices
> @@ -5002,7 +5011,7 @@ static fwts_framework_minor_test method_tests[] = {
>  	{ method_test_PSR, "Check _PSR (Power Source)." },
>  
>  	/* Section 10.4 Power Meters */
> -	/* { method_test_GAI, "Check _GAI (Get Averaging Level)." }, */
> +	{ method_test_GAI, "Check _GAI (Get Averaging Level)." },
>  	/* { method_test_GHL, "Check _GHL (Get Harware Limit)." }, */
>  	/* { method_test_PAI, "Check _PAI (Power Averaging Interval)." }, */
>  	/* { method_test_PMC, "Check _PMC (Power Meter Capabilities)." }, */
> 

Just a reminder, you probably want to update fwts-test to sync with
these patches once they land in the fwts repo.
diff mbox

Patch

diff --git a/src/acpi/method/method.c b/src/acpi/method/method.c
index f46fdff..14a908a 100644
--- a/src/acpi/method/method.c
+++ b/src/acpi/method/method.c
@@ -100,7 +100,7 @@ 
  * _FPS  11.3.1.2	N
  * _FSL  11.3.1.3	Y
  * _FST  11.3.1.4	Y
- * _GAI  10.4.5		N
+ * _GAI  10.4.5		Y
  * _GCP  9.18.2		Y
  * _GHL  10.4.7		N
  * _GL   5.7.1		n/a
@@ -3993,6 +3993,15 @@  static int method_test_PIF(fwts_framework *fw)
 		"_PIF", NULL, 0, method_test_PIF_return, NULL);
 }
 
+/*
+ * Section 10.4 Power Meters 
+ */
+
+static int method_test_GAI(fwts_framework *fw)
+{
+	return method_evaluate_method(fw, METHOD_OPTIONAL,
+		"_GAI", NULL, 0, method_test_integer_return, NULL);
+}
 
 /*
  * Section 11.3 Fan Devices
@@ -5002,7 +5011,7 @@  static fwts_framework_minor_test method_tests[] = {
 	{ method_test_PSR, "Check _PSR (Power Source)." },
 
 	/* Section 10.4 Power Meters */
-	/* { method_test_GAI, "Check _GAI (Get Averaging Level)." }, */
+	{ method_test_GAI, "Check _GAI (Get Averaging Level)." },
 	/* { method_test_GHL, "Check _GHL (Get Harware Limit)." }, */
 	/* { method_test_PAI, "Check _PAI (Power Averaging Interval)." }, */
 	/* { method_test_PMC, "Check _PMC (Power Meter Capabilities)." }, */