[PATCH i-g-t] tests: Add a test for device hot unplug
Chris Wilson
chris at chris-wilson.co.uk
Tue Apr 7 10:39:48 UTC 2020
Quoting Janusz Krzysztofik (2020-04-07 11:13:53)
> +struct hotunplug {
> + int chipset;
> + struct {
> + int drm;
> + int sysfs_dev;
> + int sysfs_bus;
> + } fd;
> +};
> +
> +/* Helpers */
> +
> +static void prepare(struct hotunplug *priv)
> +{
> + /* open the driver */
> + priv->fd.drm = __drm_open_driver(priv->chipset);
Hmm. How do we avoid chipset and use a specific device? For the
inevitable extension to multi-device validation.
I guess we will need an open_by_pciid(). Since we are simulating
hotplugs, we should be fortunate enough that the pci topology doesn't
actually change!
-Chris
More information about the Intel-gfx-trybot
mailing list