[PATCH v8 00/11] GuC Scrub vol. 1

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

 



Reasoning
=========

General GuC/HuC cleanup simplifying logic and moving chunks around as the area
got pretty rusty.

This is the first part of effort to clean it up.

A lot of logic were extracted from intel_guc_load() to other functions - it did
not only handle the actual loading but had WA implementations and the code
that enabled submission baked into it.

Param sanitization and firmware selection are also extracted and streamlined.


Naming:
=======

I try to adhere to subject_verb_object naming and parameters.

e.g. for intel_guc_init_fw:

* intel_guc is the subject, it determines the first argument taken
* init      is the verb
* fw        is the object

intel_guc_ functions take intel_guc struct pointer
intel_huc_ functions take intel_guc struct pointer

There's no `struct intel_uc`, so this family of functions take `dev_priv`.


New structure looks like this:
==============================

1. sanitize params - module params + selecting firmware happens at this stage
   * this is done mostly in patch 8, and 9
   * some cleanups happen along th way (e.g. pushing check ups, and changeing
     prototypes)
   * patch 10 introduces new modules params to overload used firmware

2. init_fw - requesting and initial parsing of firmware
   * firmware is read and parsed, we also check for versions to match

3. init_hw - firmware is loaded into hardware and hardware is initalized
   * uc_init_hw has now all logic when it comes to retires and resetting fw to
     vanilla state
   * huc_init_hw and guc_init_hw no longer care about each other and
     submission



v2: rebase after HuC merge + feedback
v3: even more renaming that aims to make things more semantic
v4: some naming improvements, some bikeshedding
v5: coding style, some cleanup
    module params for huc and guc firmware path,
    separate fw select step from actual prepare
v6: feedback + pushed a couple of patches with r-b down the stack
v7: reorder, rename, rebase
v8: rebase, onion teardown, naming, added GuC enablement HAX

Arkadiusz Hiler (11):
  drm/i915/uc: Drop superfluous externs in intel_uc.h
  drm/i915/huc: Add huc_to_i915
  drm/i915/uc: Rename intel_?uc_{setup,load}() to _init_hw()
  drm/i915/uc: Move intel_uc_fw_fetch() to intel_uc.c
  drm/i915/uc: Introduce intel_uc_init_fw()
  drm/i915/guc: Extract param logic form guc_init_fw()
  drm/i915/guc: Simplify intel_guc_init_hw()
  drm/i915/uc: Simplify firmware path handling
  drm/i915/uc: Separate firmware selection and preparation
  drm/i915/uc: Add params for specifying firmware
  HAX enable GuC for CI

 drivers/gpu/drm/i915/i915_drv.c         |   5 +-
 drivers/gpu/drm/i915/i915_drv.h         |   5 +
 drivers/gpu/drm/i915/i915_gem.c         |   2 +-
 drivers/gpu/drm/i915/i915_params.c      |  14 +-
 drivers/gpu/drm/i915/i915_params.h      |   2 +
 drivers/gpu/drm/i915/intel_guc_loader.c | 379 ++++----------------------------
 drivers/gpu/drm/i915/intel_huc.c        | 109 ++++-----
 drivers/gpu/drm/i915/intel_uc.c         | 284 ++++++++++++++++++++++++
 drivers/gpu/drm/i915/intel_uc.h         |  23 +-
 9 files changed, 413 insertions(+), 410 deletions(-)

-- 
2.9.3

_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/intel-gfx




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux