[PATCH] drm/xe/vf: Don't register I2C devices if VF

Rodrigo Vivi rodrigo.vivi at intel.com
Thu Jul 17 19:49:32 UTC 2025


On Thu, Jul 17, 2025 at 05:54:20PM +0200, Lukasz Laguna wrote:
> VF drivers can't access I2C devices, so skip their registration when
> running as VF.
> 

Fixes: f0e53aadd702 ("drm/xe: Support for I2C attached MCUs")
Reviewed-by: Rodrigo Vivi <rodrigo.vivi at intel.com>

pushing soon, thanks for the patch.

> Signed-off-by: Lukasz Laguna <lukasz.laguna at intel.com>
> ---
>  drivers/gpu/drm/xe/xe_i2c.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/drivers/gpu/drm/xe/xe_i2c.c b/drivers/gpu/drm/xe/xe_i2c.c
> index 1f19718db559..bc7dc2099470 100644
> --- a/drivers/gpu/drm/xe/xe_i2c.c
> +++ b/drivers/gpu/drm/xe/xe_i2c.c
> @@ -283,6 +283,9 @@ int xe_i2c_probe(struct xe_device *xe)
>  	if (xe->info.platform != XE_BATTLEMAGE)
>  		return 0;
>  
> +	if (IS_SRIOV_VF(xe))
> +		return 0;
> +
>  	xe_i2c_read_endpoint(xe_root_tile_mmio(xe), &ep);
>  	if (ep.cookie != XE_I2C_EP_COOKIE_DEVICE)
>  		return 0;
> -- 
> 2.40.0
> 


More information about the Intel-xe mailing list