== Series Details == Series: series starting with [1/6] drm/i915: Move a bunch of workaround-related code to its own file URL : https://patchwork.freedesktop.org/series/38397/ State : warning == Summary == $ dim checkpatch origin/drm-tip 349d068aa6d4 drm/i915: Move a bunch of workaround-related code to its own file -:720: WARNING: added, moved or deleted file(s), does MAINTAINERS need updating? #720: new file mode 100644 -:752: WARNING: Macros with flow control statements should be avoided #752: FILE: drivers/gpu/drm/i915/intel_workarounds.c:28: +#define WA_REG(addr, mask, val) do { \ + const int r = wa_add(dev_priv, (addr), (mask), (val)); \ + if (r) \ + return r; \ + } while (0) -:758: CHECK: Macro argument reuse 'mask' - possible side-effects? #758: FILE: drivers/gpu/drm/i915/intel_workarounds.c:34: +#define WA_SET_BIT_MASKED(addr, mask) \ + WA_REG(addr, (mask), _MASKED_BIT_ENABLE(mask)) -:761: CHECK: Macro argument reuse 'mask' - possible side-effects? #761: FILE: drivers/gpu/drm/i915/intel_workarounds.c:37: +#define WA_CLR_BIT_MASKED(addr, mask) \ + WA_REG(addr, (mask), _MASKED_BIT_DISABLE(mask)) -:764: CHECK: Macro argument reuse 'mask' - possible side-effects? #764: FILE: drivers/gpu/drm/i915/intel_workarounds.c:40: +#define WA_SET_FIELD_MASKED(addr, mask, value) \ + WA_REG(addr, mask, _MASKED_FIELD(mask, value)) -:772: CHECK: Prefer kernel type 'u32' over 'uint32_t' #772: FILE: drivers/gpu/drm/i915/intel_workarounds.c:48: + const uint32_t index = wa->hw_whitelist_count[engine->id]; -:862: WARNING: line over 80 characters #862: FILE: drivers/gpu/drm/i915/intel_workarounds.c:138: + (IS_BDW_GT3(dev_priv) ? HDC_FENCE_DEST_SLM_DISABLE : 0)); -:891: WARNING: line over 80 characters #891: FILE: drivers/gpu/drm/i915/intel_workarounds.c:167: + I915_WRITE(GEN9_CSFE_CHICKEN1_RCS, _MASKED_BIT_ENABLE(GEN9_PREEMPT_GPGPU_SYNC_SWITCH_DISABLE)); -:1119: WARNING: line over 80 characters #1119: FILE: drivers/gpu/drm/i915/intel_workarounds.c:395: + _MASKED_BIT_ENABLE(GEN9_POOLED_EU_LOAD_BALANCING_FIX_DISABLE)); -:1182: ERROR: spaces required around that '=' (ctx:VxW) #1182: FILE: drivers/gpu/drm/i915/intel_workarounds.c:458: + ret= wa_ring_whitelist_reg(engine, GEN8_CS_CHICKEN1); ^ -:1226: CHECK: Lines should not end with a '(' #1226: FILE: drivers/gpu/drm/i915/intel_workarounds.c:502: + WA_SET_BIT_MASKED( -:1286: CHECK: Lines should not end with a '(' #1286: FILE: drivers/gpu/drm/i915/intel_workarounds.c:562: + WA_SET_BIT_MASKED( total: 1 errors, 5 warnings, 6 checks, 1327 lines checked 28111c392ca3 drm/i915: Split out functions for different kinds of workarounds -:382: CHECK: Lines should not end with a '(' #382: FILE: drivers/gpu/drm/i915/intel_workarounds.c:322: + WA_SET_BIT_MASKED( -:429: CHECK: Lines should not end with a '(' #429: FILE: drivers/gpu/drm/i915/intel_workarounds.c:357: + WA_SET_BIT_MASKED( -:484: CHECK: braces {} should be used on all arms of this statement #484: FILE: drivers/gpu/drm/i915/intel_workarounds.c:408: + if (INTEL_GEN(dev_priv) < 8) [...] + else if (IS_BROADWELL(dev_priv)) [...] + else if (IS_CHERRYVIEW(dev_priv)) [...] + else if (IS_SKYLAKE(dev_priv)) [...] + else if (IS_BROXTON(dev_priv)) [...] + else if (IS_KABYLAKE(dev_priv)) [...] + else if (IS_GEMINILAKE(dev_priv)) [...] + else if (IS_COFFEELAKE(dev_priv)) [...] + else if (IS_CANNONLAKE(dev_priv)) [...] + else { [...] -:502: CHECK: Unbalanced braces around else statement #502: FILE: drivers/gpu/drm/i915/intel_workarounds.c:426: + else { -:630: WARNING: line over 80 characters #630: FILE: drivers/gpu/drm/i915/intel_workarounds.c:553: + _MASKED_BIT_ENABLE(GEN9_POOLED_EU_LOAD_BALANCING_FIX_DISABLE)); -:806: CHECK: Prefer kernel type 'u32' over 'uint32_t' #806: FILE: drivers/gpu/drm/i915/intel_workarounds.c:655: + const uint32_t index = wa->hw_whitelist_count[engine->id]; -:862: WARNING: Missing a blank line after declarations #862: FILE: drivers/gpu/drm/i915/intel_workarounds.c:692: + int ret = gen9_whitelist_workarounds_apply(engine); + if (ret) -:877: WARNING: Missing a blank line after declarations #877: FILE: drivers/gpu/drm/i915/intel_workarounds.c:706: + int ret = gen9_whitelist_workarounds_apply(engine); + if (ret) -:886: WARNING: Missing a blank line after declarations #886: FILE: drivers/gpu/drm/i915/intel_workarounds.c:715: + int ret = gen9_whitelist_workarounds_apply(engine); + if (ret) -:900: WARNING: Missing a blank line after declarations #900: FILE: drivers/gpu/drm/i915/intel_workarounds.c:729: + int ret = gen9_whitelist_workarounds_apply(engine); + if (ret) -:914: WARNING: Missing a blank line after declarations #914: FILE: drivers/gpu/drm/i915/intel_workarounds.c:743: + int ret = gen9_whitelist_workarounds_apply(engine); + if (ret) -:941: CHECK: braces {} should be used on all arms of this statement #941: FILE: drivers/gpu/drm/i915/intel_workarounds.c:770: + if (INTEL_GEN(dev_priv) < 9) { [...] + } else if (IS_SKYLAKE(dev_priv)) [...] + else if (IS_BROXTON(dev_priv)) [...] + else if (IS_KABYLAKE(dev_priv)) [...] + else if (IS_GEMINILAKE(dev_priv)) [...] + else if (IS_COFFEELAKE(dev_priv)) [...] + else if (IS_CANNONLAKE(dev_priv)) [...] + else { [...] -:956: CHECK: Unbalanced braces around else statement #956: FILE: drivers/gpu/drm/i915/intel_workarounds.c:785: + else { total: 0 errors, 6 warnings, 7 checks, 907 lines checked 88298b5b30d5 drm/i915: Apply context workarounds directly 5af41d9d456c drm/i915: Move WA BB stuff to the workarounds file as well -:6: WARNING: Possible unwrapped commit description (prefer a maximum 75 chars per line) #6: Since we are trying to put all WA stuff together, do not forget about the BB WAs. -:346: WARNING: line over 80 characters #346: FILE: drivers/gpu/drm/i915/intel_workarounds.c:709: + * constant value with bit21 set and then we restore it back with the saved value. -:385: WARNING: line over 80 characters #385: FILE: drivers/gpu/drm/i915/intel_workarounds.c:748: + * on a criteria. At the moment this batch always start at the beginning of the page -:440: CHECK: Lines should not end with a '(' #440: FILE: drivers/gpu/drm/i915/intel_workarounds.c:803: + *batch++ = _MASKED_BIT_DISABLE( -:598: CHECK: multiple assignments should be avoided #598: FILE: drivers/gpu/drm/i915/intel_workarounds.c:961: + batch = batch_ptr = kmap_atomic(page); -:617: WARNING: Avoid crashing the kernel - try using WARN_ON & recovery code rather than BUG() or BUG_ON() #617: FILE: drivers/gpu/drm/i915/intel_workarounds.c:980: + BUG_ON(batch_ptr - batch > CTX_WA_BB_OBJ_SIZE); total: 0 errors, 4 warnings, 2 checks, 609 lines checked 78079494271e drm/i915: Create a new category of display WAs -:624: WARNING: Missing a blank line after declarations #624: FILE: drivers/gpu/drm/i915/intel_workarounds.c:779: + u32 val = I915_READ(CHICKEN_MISC_2); + val &= ~(GLK_CL0_PWR_DOWN | -:654: WARNING: Missing a blank line after declarations #654: FILE: drivers/gpu/drm/i915/intel_workarounds.c:809: + u32 val; + cnp_display_workarounds_apply(dev_priv); total: 0 errors, 2 warnings, 0 checks, 671 lines checked c5dc8cf7ebe8 drm/i915: Classify GT & Display WAs correctly -:73: CHECK: Please don't use multiple blank lines #73: FILE: drivers/gpu/drm/i915/intel_workarounds.c:417: + + -:77: CHECK: Please don't use multiple blank lines #77: FILE: drivers/gpu/drm/i915/intel_workarounds.c:421: + + -:82: CHECK: Please don't use multiple blank lines #82: FILE: drivers/gpu/drm/i915/intel_workarounds.c:426: + + total: 0 errors, 0 warnings, 3 checks, 279 lines checked _______________________________________________ Intel-gfx mailing list Intel-gfx@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/intel-gfx