[igt-dev] [PATCH i-g-t] i915_pm_freq_mult: Compare scale factors as floats
Petri Latvala
petri.latvala at intel.com
Tue Nov 15 10:22:06 UTC 2022
igt_assert_eq converts parameters to ints. The checked values are
floats, so use igt_assert_eq_double instead.
Fixes: d47beef9b015 ("tests/i915_pm_freq_mult: New test for media freq factor")
Signed-off-by: Petri Latvala <petri.latvala at intel.com>
Cc: Ashutosh Dixit <ashutosh.dixit at intel.com>
Cc: Kamil Konieczny <kamil.konieczny at linux.intel.com>
Cc: Rodrigo Vivi <rodrigo.vivi at intel.com>
---
tests/i915/i915_pm_freq_mult.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tests/i915/i915_pm_freq_mult.c b/tests/i915/i915_pm_freq_mult.c
index 70cd7ffc..894ae294 100644
--- a/tests/i915/i915_pm_freq_mult.c
+++ b/tests/i915/i915_pm_freq_mult.c
@@ -102,7 +102,7 @@ static void media_freq(int gt, int dir)
igt_require(igt_sysfs_has_attr(dir, "media_freq_factor"));
igt_sysfs_scanf(dir, "media_freq_factor.scale", "%g", &scale);
- igt_assert_eq(scale, FREQ_SCALE_FACTOR);
+ igt_assert_eq_double(scale, FREQ_SCALE_FACTOR);
setup_freq(gt, dir);
--
2.30.2
More information about the igt-dev
mailing list