[Intel-gfx] [PATCH] drm/i915/gvt: avoid useless use of inline

Zhenyu Wang zhenyuw at linux.intel.com
Thu Dec 3 05:07:13 UTC 2020


On 2020.11.30 13:13:53 +0200, Jani Nikula wrote:
> In most cases, we are better off letting the compiler decide whether to
> inline static functions in .c files or not. In this case, the inline
> will be ignored anyway as mmio_pm_restore_handler() is passed as a
> function pointer.
> 
> Fixes: 5f60b12edcd0 ("drm/i915/gvt: Save/restore HW status to support GVT suspend/resume")
> Cc: Zhenyu Wang <zhenyuw at linux.intel.com>
> Cc: Hang Yuan <hang.yuan at linux.intel.com>
> Cc: Colin Xu <colin.xu at intel.com>
> Cc: Zhi Wang <zhi.a.wang at intel.com>
> Cc: intel-gvt-dev at lists.freedesktop.org
> Signed-off-by: Jani Nikula <jani.nikula at intel.com>
> ---
>  drivers/gpu/drm/i915/gvt/handlers.c | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/gvt/handlers.c b/drivers/gpu/drm/i915/gvt/handlers.c
> index 6f0706e885cb..69e725b95bcf 100644
> --- a/drivers/gpu/drm/i915/gvt/handlers.c
> +++ b/drivers/gpu/drm/i915/gvt/handlers.c
> @@ -3686,8 +3686,7 @@ void intel_gvt_restore_fence(struct intel_gvt *gvt)
>  	}
>  }
>  
> -static inline int mmio_pm_restore_handler(struct intel_gvt *gvt,
> -					  u32 offset, void *data)
> +static int mmio_pm_restore_handler(struct intel_gvt *gvt, u32 offset, void *data)
>  {
>  	struct intel_vgpu *vgpu = data;
>  	struct drm_i915_private *dev_priv = gvt->gt->i915;
> -- 

Reviewed-by: Zhenyu Wang <zhenyuw at linux.intel.com>

Queued this. Thanks!

-- 

$gpg --keyserver wwwkeys.pgp.net --recv-keys 4D781827
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 195 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/intel-gfx/attachments/20201203/33b503ad/attachment.sig>


More information about the Intel-gfx mailing list