[Intel-gfx] [PATCH v2] drm/i915/guc: Update syntax of GuC log functions

Michał Winiarski michal.winiarski at intel.com
Wed Mar 14 16:56:01 UTC 2018


On Wed, Mar 14, 2018 at 02:45:39PM +0000, Michal Wajdeczko wrote:
> We moved GuC log related data and code to separate files and
> definition but we didn't change functions syntax to follow
> object-verb pattern. Let's fix that before we continue with
> next round of code refactoring.
> 
> v2: rebased
> 
> Signed-off-by: Michal Wajdeczko <michal.wajdeczko at intel.com>
> Cc: Michal Winiarski <michal.winiarski at intel.com>
> Cc: Chris Wilson <chris at chris-wilson.co.uk>
> Reviewed-by: Michał Winiarski <michal.winiarski at intel.com>

One more comment, since I just noticed this while rebasing my guc patches on
this rename.

What about guc actions?
We now have guc_log_flush_complete, guc_log_flush and guc_log_control that are
using intel_guc rather than intel_guc_log.
Which is reasonable - because those don't touch guc->log, but it's also
inconsistent (I'm also adding guc_log_flush_irq_enable).

If you want to follow object-verb pattern, you should either rename or pass
intel_guc_log and do the log_to_guc dance there.

-Michał

> ---
>  drivers/gpu/drm/i915/i915_debugfs.c  |   4 +-
>  drivers/gpu/drm/i915/intel_guc.c     |   8 +-
>  drivers/gpu/drm/i915/intel_guc_log.c | 203 +++++++++++++++++++----------------
>  drivers/gpu/drm/i915/intel_guc_log.h |  18 ++--
>  drivers/gpu/drm/i915/intel_uc.c      |   4 +-
>  5 files changed, 126 insertions(+), 111 deletions(-)


More information about the Intel-gfx mailing list