Re: [PATCH i-g-t] i915/perf_pmu: Attempt to unload i915 while the PMU is active

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Quoting Chris Wilson (2020-04-30 19:28:59)
> +static void test_unload(void)
> +{
> +       igt_fork(child, 1) {
...
> +               igt_debug("Read %d events from perf and trial unload\n", count);
> +               pmu_read_multi(fd, count, buf);
> +               igt_assert_eq(unload_i915(), -EBUSY);
> +               pmu_read_multi(fd, count, buf);
> +               sleep(2);
> +
> +               igt_debug("Close perf\n");
> +               close(fd);
> +
> +               free(buf);
> +       }
> +       igt_waitchildren();
> +
> +       igt_debug("Final unload\n");
> +       sleep(5);
> +       igt_assert_eq(unload_i915(), 0);

The sleeps are not required, the child process is enough to kick the
perf_event_destroy.
-Chris
_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/intel-gfx



[Index of Archives]     [AMD Graphics]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux