drm/i915/display: Avoid full proxy f_ops for DRRS debug attributes
Subsystems (3)
PATCH 1/1 drm/i915/display: Avoid full proxy f_ops for DRRS debug attributes
Using DEFINE_SIMPLE_ATTRIBUTE macro with the debugfs_create_file() function adds the overhead of introducing a proxy file operation functions to wrap the original read/write inside file removal protection functions. This adds significant overhead in terms of introducing and managing the proxy factory file operations structure and function wrapping at runtime.
As a replacement, a combination of DEFINE_DEBUGFS_ATTRIBUTE macro paired with debugfs_create_file_unsafe() is suggested to be used instead. The DEFINE_DEBUGFS_ATTRIBUTE utilises debugfs_file_get() and debugfs_file_put() wrappers to protect the original read and write function calls for the debug attributes. There is no need for any runtime proxy file operations to be managed by the debugfs core.
This Change is reported by the debugfs_simple_attr.cocci Coccinelle semantic patch.
--- drivers/gpu/drm/i915/display/intel_drrs.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
drivers/gpu/drm/i915/display/intel_drrs.c +4 -4
@@ -374,16 +374,16 @@ static int intel_drrs_debugfs_ctl_set(void *data, u64 val)return ret; } -DEFINE_SIMPLE_ATTRIBUTE (intel_drrs_debugfs_ctl_fops, -NULL , intel_drrs_debugfs_ctl_set,"%llu\n" ); +DEFINE_DEBUGFS_ATTRIBUTE (intel_drrs_debugfs_ctl_fops, +NULL , intel_drrs_debugfs_ctl_set,"%llu\n" );void intel_drrs_crtc_debugfs_add (struct intel_crtc *crtc) {debugfs_create_file ("i915_drrs_status" ,0444 , crtc->base.debugfs_entry, crtc, &intel_drrs_debugfs_status_fops); -debugfs_create_file ("i915_drrs_ctl" ,0644 , crtc->base.debugfs_entry, - crtc, &intel_drrs_debugfs_ctl_fops); +debugfs_create_file_unsafe ("i915_drrs_ctl" ,0644 , crtc->base.debugfs_entry, + crtc, &intel_drrs_debugfs_ctl_fops); }static int intel_drrs_debugfs_type_show (struct seq_file *m,void *unused)
--
2.34.1
Patchwork
CI[Intel-gfx] ✗ Fi.CI.BAT: failure for drm/i915/display: Avoid full proxy f_ops for DRRS debug attributes
== Series Details ==
== Series Details ==
Series: drm/i915/display: Avoid full proxy f_ops for DRRS debug attributes
URL : https://patchwork.freedesktop.org/series/112248/
State : failure
== Summary ==
CI Bug Log - changes from CI_DRM_12526 -> Patchwork_112248v1
====================================================
Summary
-------
**FAILURE**
Serious unknown changes coming with Patchwork_112248v1 absolutely need to be verified manually.
If you think the reported changes have nothing to do with the changes introduced in Patchwork_112248v1, please notify your bug team to allow them to document this new failure mode, which will reduce false positives in CI.
External URL: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_112248v1/index.html
Participating hosts (45 -> 44)
------------------------------
Additional (1): fi-kbl-soraka
Missing (2): fi-bdw-gvtdvm bat-dg2-oem1
Possible new issues
-------------------
Here are the unknown changes that may have been introduced in Patchwork_112248v1:
### IGT changes ###
#### Possible regressions ####
* igt@i915_selftest@live@execlists:
- fi-bsw-nick: [PASS][1] -> [INCOMPLETE][2]
[1]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12526/fi-bsw-nick/igt@i915_selftest@[email protected]
[2]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_112248v1/fi-bsw-nick/igt@i915_selftest@[email protected]
Known issues
------------
Here are the changes found in Patchwork_112248v1 that come from known issues:
### IGT changes ###
#### Issues hit ####
* igt@gem_exec_gttfill@basic:
- fi-kbl-soraka: NOTRUN -> [SKIP][3] ([fdo#109271]) +7 similar issues
[3]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_112248v1/fi-kbl-soraka/igt@[email protected]
* igt@gem_huc_copy@huc-copy:
- fi-kbl-soraka: NOTRUN -> [SKIP][4] ([fdo#109271] / [i915#2190])
[4]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_112248v1/fi-kbl-soraka/igt@[email protected]
* igt@gem_lmem_swapping@basic:
- fi-kbl-soraka: NOTRUN -> [SKIP][5] ([fdo#109271] / [i915#4613]) +3 similar issues
[5]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_112248v1/fi-kbl-soraka/igt@[email protected]
* igt@i915_selftest@live@gt_pm:
- fi-kbl-soraka: NOTRUN -> [DMESG-FAIL][6] ([i915#1886])
[6]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_112248v1/fi-kbl-soraka/igt@i915_selftest@live@gt_pm.html
* igt@i915_selftest@live@late_gt_pm:
- fi-kbl-soraka: NOTRUN -> [INCOMPLETE][7] ([i915#7640])
[7]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_112248v1/fi-kbl-soraka/igt@i915_selftest@live@late_gt_pm.html
* igt@kms_chamelium@common-hpd-after-suspend:
- fi-rkl-guc: NOTRUN -> [SKIP][8] ([fdo#111827])
[8]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_112248v1/fi-rkl-guc/igt@[email protected]
* igt@kms_chamelium@hdmi-hpd-fast:
- fi-kbl-soraka: NOTRUN -> [SKIP][9] ([fdo#109271] / [fdo#111827]) +7 similar issues
[9]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_112248v1/fi-kbl-soraka/igt@[email protected]
* igt@runner@aborted:
- fi-bsw-nick: NOTRUN -> [FAIL][10] ([fdo#109271] / [i915#4312])
[10]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_112248v1/fi-bsw-nick/igt@[email protected]
#### Possible fixes ####
* igt@i915_selftest@live@hangcheck:
- fi-rkl-guc: [INCOMPLETE][11] ([i915#4983]) -> [PASS][12]
[11]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12526/fi-rkl-guc/igt@i915_selftest@[email protected]
[12]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_112248v1/fi-rkl-guc/igt@i915_selftest@[email protected]
* igt@i915_selftest@live@migrate:
- {bat-adlp-9}: [DMESG-FAIL][13] ([i915#7699]) -> [PASS][14]
[13]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12526/bat-adlp-9/igt@i915_selftest@[email protected]
[14]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_112248v1/bat-adlp-9/igt@i915_selftest@[email protected]
- {bat-atsm-1}: [DMESG-FAIL][15] ([i915#7699]) -> [PASS][16]
[15]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_12526/bat-atsm-1/igt@i915_selftest@[email protected]
[16]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_112248v1/bat-atsm-1/igt@i915_selftest@[email protected]
{name}: This element is suppressed. This means it is ignored when computing
the status of the difference (SUCCESS, WARNING, or FAILURE).
[fdo#109271]: https://bugs.freedesktop.org/show_bug.cgi?id=109271
[fdo#111827]: https://bugs.freedesktop.org/show_bug.cgi?id=111827
[i915#1886]: https://gitlab.freedesktop.org/drm/intel/issues/1886
[i915#2190]: https://gitlab.freedesktop.org/drm/intel/issues/2190
[i915#4312]: https://gitlab.freedesktop.org/drm/intel/issues/4312
[i915#4613]: https://gitlab.freedesktop.org/drm/intel/issues/4613
[i915#4983]: https://gitlab.freedesktop.org/drm/intel/issues/4983
[i915#5354]: https://gitlab.freedesktop.org/drm/intel/issues/5354
[i915#6257]: https://gitlab.freedesktop.org/drm/intel/issues/6257
[i915#7640]: https://gitlab.freedesktop.org/drm/intel/issues/7640
[i915#7699]: https://gitlab.freedesktop.org/drm/intel/issues/7699
Build changes
-------------
* Linux: CI_DRM_12526 -> Patchwork_112248v1
CI-20190529: 20190529
CI_DRM_12526: 34f2552b43d664ce4b76c6e356a57b7835f59c81 @ git://anongit.freedesktop.org/gfx-ci/linux
IGT_7102: bacfdc84a9c02556c5441deb21e3a3f18a07347d @ https://gitlab.freedesktop.org/drm/igt-gpu-tools.git
Patchwork_112248v1: 34f2552b43d664ce4b76c6e356a57b7835f59c81 @ git://anongit.freedesktop.org/gfx-ci/linux
### Linux commits
7c0e1564810b drm/i915/display: Avoid full proxy f_ops for DRRS debug attributes
== Logs ==
For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_112248v1/index.html