Re: [PATCH] drm/i915: Disable semaphore on vGPU for now

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

 



Quoting Zhenyu Wang (2019-03-27 09:06:36)
> This is to disable semaphore usage when on vGPU for now. Unfortunately
> GVT-g hasn't fully enabled semaphore usage yet, so current guest with
> semaphore use would cause vGPU failure.
> 
> Although current semaphore failure with vGPU can be simply resolved by
> allowing cmd parser to accept MI_SEMAPHORE_WAIT command with address
> audit, we're checking general usage of semaphore and how we should
> handle it properly for virtualization in consider of function and
> security concern. So we decide to request to disable it for now in
> guest driver. Once GVT could support it, we would add new compat bit
> to turn it on.
> 
> Cc: Kevin Tian <kevin.tian@xxxxxxxxx>
> Cc: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx>
> Cc: Rodrigo Vivi <rodrigo.vivi@xxxxxxxxx>
> Signed-off-by: Zhenyu Wang <zhenyuw@xxxxxxxxxxxxxxx>
> ---
> Note this needs to queue for -next otherwise next kernel i915 as guest
> would be broken for GVT.
> 
>  drivers/gpu/drm/i915/intel_lrc.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/i915/intel_lrc.c b/drivers/gpu/drm/i915/intel_lrc.c
> index 66bc3cd4e166..50075e24ae03 100644
> --- a/drivers/gpu/drm/i915/intel_lrc.c
> +++ b/drivers/gpu/drm/i915/intel_lrc.c
> @@ -2315,7 +2315,8 @@ void intel_execlists_set_default_submission(struct intel_engine_cs *engine)
>         engine->park = NULL;
>         engine->unpark = NULL;
>  
> -       engine->flags |= I915_ENGINE_HAS_SEMAPHORES;
> +       if (!intel_vgpu_active(engine->i915))
> +               engine->flags |= I915_ENGINE_HAS_SEMAPHORES;

Fwiw, this will have the desired effect so,

Acked-by: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx>

Just the question remains as this is being used by userspace, sweeping
it under the rug might be a bit more difficult.
-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