user_parameters : added RENDERCHECK_FORMATS variable

Submitted by Humberto Perez on Nov. 17, 2017, 4:07 p.m.

Details

Message ID 20171117160713.32721-1-humberto.i.perez.rodriguez@intel.com
State New
Headers show
Series "user_parameters : added RENDERCHECK_FORMATS variable" ( rev: 1 ) in EzBench

Not browsing as part of any series.

Commit Message

Humberto Perez Nov. 17, 2017, 4:07 p.m.
From: Humberto Israel Perez Rodriguez <humberto.i.perez.rodriguez@intel.com>

Changes on this revision :
- added RENDERCHECK_FORMATS variable to user_parameters.sh.sample
in order to be able to configure from a single format to all
availables by rendercheck (so far rendercheck has 23 formats)
- in rendercheck.test file was replaced the hardcoded formats for
RENDERCHECK_FORMATS variable
---
 tests.d/x11/rendercheck.test | 2 +-
 user_parameters.sh.sample    | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)

Patch hide | download patch | download mbox

diff --git a/tests.d/x11/rendercheck.test b/tests.d/x11/rendercheck.test
index 80af3e7..bb46982 100644
--- a/tests.d/x11/rendercheck.test
+++ b/tests.d/x11/rendercheck.test
@@ -6,7 +6,7 @@  RENDERCHECK="$RENDERCHECK_FOLDER/rendercheck"
 [ -e "$RENDERCHECK" ] || return 1
 
 x11:rendercheck_run() {
-    run_bench 0 "$RENDERCHECK" -r -f a8r8g8b8,x8r8g8b8 2>&1 > /dev/null | grep "^## " | sed 's/## \(.*\): \+\(.*\)/\1: str(\2)/g'
+    run_bench 0 "$RENDERCHECK" -r -f "$RENDERCHECK_FORMATS" 2>&1 > /dev/null | grep "^## " | sed 's/## \(.*\): \+\(.*\)/\1: str(\2)/g'
 
     # Go through all the subtests we wanted to get and check if all of them
     # are present. If not, mark them as missing.
diff --git a/user_parameters.sh.sample b/user_parameters.sh.sample
index 27481b0..1c010e3 100644
--- a/user_parameters.sh.sample
+++ b/user_parameters.sh.sample
@@ -146,6 +146,7 @@  WATCHDOG_TIMEOUT_REBOOT=120
 # Rendercheck: From https://cgit.freedesktop.org/~mperes/rendercheck/
 # Must point to the directory containing the 'rendercheck' binary
 RENDERCHECK_FOLDER=/opt/benchmarks/rendercheck/
+RENDERCHECK_FORMATS="a8r8g8b8,x8r8g8b8"
 
 # cairo-demos settings
 CAIRO_DEMOS=/opt/benchmarks/cairo-demos

Comments

On 17/11/17 18:07, Humberto Perez wrote:
> From: Humberto Israel Perez Rodriguez <humberto.i.perez.rodriguez@intel.com>
> 
> Changes on this revision :
> - added RENDERCHECK_FORMATS variable to user_parameters.sh.sample
> in order to be able to configure from a single format to all
> availables by rendercheck (so far rendercheck has 23 formats)
> - in rendercheck.test file was replaced the hardcoded formats for
> RENDERCHECK_FORMATS variable
> ---
>  tests.d/x11/rendercheck.test | 2 +-
>  user_parameters.sh.sample    | 1 +
>  2 files changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/tests.d/x11/rendercheck.test b/tests.d/x11/rendercheck.test
> index 80af3e7..bb46982 100644
> --- a/tests.d/x11/rendercheck.test
> +++ b/tests.d/x11/rendercheck.test
> @@ -6,7 +6,7 @@ RENDERCHECK="$RENDERCHECK_FOLDER/rendercheck"
>  [ -e "$RENDERCHECK" ] || return 1
>  
>  x11:rendercheck_run() {

Maybe we can keep the functionality working for people who have an old
user_parameters.sh by adding this:

RENDERCHECK_FORMATS="${RENDERCHECK_FORMATS:-a8r8g8b8,x8r8g8b8}"

This will set the default value to a8r8g8b8,x8r8g8b8 when the variable
has not be set before (in user_parameters.sh)

Can you re-spin your patch and send a v2? (git send-email -v2 ...)

I'll add my R-b and push it :)

Thanks a lot!

> -    run_bench 0 "$RENDERCHECK" -r -f a8r8g8b8,x8r8g8b8 2>&1 > /dev/null | grep "^## " | sed 's/## \(.*\): \+\(.*\)/\1: str(\2)/g'
> +    run_bench 0 "$RENDERCHECK" -r -f "$RENDERCHECK_FORMATS" 2>&1 > /dev/null | grep "^## " | sed 's/## \(.*\): \+\(.*\)/\1: str(\2)/g'
>  
>      # Go through all the subtests we wanted to get and check if all of them
>      # are present. If not, mark them as missing.
> diff --git a/user_parameters.sh.sample b/user_parameters.sh.sample
> index 27481b0..1c010e3 100644
> --- a/user_parameters.sh.sample
> +++ b/user_parameters.sh.sample
> @@ -146,6 +146,7 @@ WATCHDOG_TIMEOUT_REBOOT=120
>  # Rendercheck: From https://cgit.freedesktop.org/~mperes/rendercheck/
>  # Must point to the directory containing the 'rendercheck' binary
>  RENDERCHECK_FOLDER=/opt/benchmarks/rendercheck/
> +RENDERCHECK_FORMATS="a8r8g8b8,x8r8g8b8"
>  
>  # cairo-demos settings
>  CAIRO_DEMOS=/opt/benchmarks/cairo-demos
>