OpenCloudOS-Kernel/drivers/gpu/drm/i915
Pankaj Bharadiya 0d4c351a0f drm/i915/gt: Make WARN* drm specific where drm_priv ptr is available
drm specific WARN* calls include device information in the
backtrace, so we know what device the warnings originate from.

Covert all the calls of WARN* with device specific drm_WARN*
variants in functions where drm_i915_private struct pointer is readily
available.

The conversion was done automatically with below coccinelle semantic
patch. checkpatch errors/warnings are fixed manually.

@rule1@
identifier func, T;
@@
func(...) {
...
struct drm_i915_private *T = ...;
<+...
(
-WARN(
+drm_WARN(&T->drm,
...)
|
-WARN_ON(
+drm_WARN_ON(&T->drm,
...)
|
-WARN_ONCE(
+drm_WARN_ONCE(&T->drm,
...)
|
-WARN_ON_ONCE(
+drm_WARN_ON_ONCE(&T->drm,
...)
)
...+>
}

@rule2@
identifier func, T;
@@
func(struct drm_i915_private *T,...) {
<+...
(
-WARN(
+drm_WARN(&T->drm,
...)
|
-WARN_ON(
+drm_WARN_ON(&T->drm,
...)
|
-WARN_ONCE(
+drm_WARN_ONCE(&T->drm,
...)
|
-WARN_ON_ONCE(
+drm_WARN_ON_ONCE(&T->drm,
...)
)
...+>
}

command: spatch --sp-file <script> --dir drivers/gpu/drm/i915/gt \
					--linux-spacing --in-place

Signed-off-by: Pankaj Bharadiya <pankaj.laxminarayan.bharadiya@intel.com>
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20200115034455.17658-7-pankaj.laxminarayan.bharadiya@intel.com
2020-01-22 17:53:37 +02:00
..
display drm/i915/display: Make WARN* drm specific where encoder ptr is available 2020-01-22 17:51:53 +02:00
gem drm/i915/gem: Make WARN* drm specific where drm_priv ptr is available 2020-01-22 17:52:39 +02:00
gt drm/i915/gt: Make WARN* drm specific where drm_priv ptr is available 2020-01-22 17:53:37 +02:00
gvt drm/i915/gtt: split up i915_gem_gtt 2020-01-07 19:27:36 +00:00
oa drm/i915: reimplement header test feature 2020-01-02 12:24:10 +02:00
selftests drm/i915/gtt: split up i915_gem_gtt 2020-01-07 19:27:36 +00:00
.gitignore drm/i915: reimplement header test feature 2020-01-02 12:24:10 +02:00
Kconfig drm/i915: drop alpha_support for good in favour of force_probe 2020-01-22 10:51:32 +02:00
Kconfig.debug Merge drm/drm-next into drm-intel-next-queued 2019-12-11 11:13:50 +02:00
Kconfig.profile drm/i915: Default to a more lenient forced preemption timeout 2019-11-27 10:12:14 +02:00
Kconfig.unstable drm/i915/lmem: add the fake lmem region 2019-10-31 20:41:47 +00:00
Makefile drm/i915/params: add i915 parameters to debugfs 2020-01-15 15:10:16 +02:00
i915_active.c drm/i915: Satisfy smatch that a loop has at least one iteration 2020-01-17 13:27:10 +00:00
i915_active.h drm/i915: Specialise i915_active.work lock classes 2019-12-02 21:57:23 +00:00
i915_active_types.h drm/i915: Serialise i915_active_fence_set() with itself 2019-11-27 17:02:14 +00:00
i915_buddy.c drn/i915: Break up long i915_buddy_free_list() with a cond_resched() 2019-12-30 12:10:38 +00:00
i915_buddy.h
i915_cmd_parser.c Correct function name in comment 2019-12-16 23:13:12 +00:00
i915_debugfs.c drm/i915: Use intel_attached_dp() instead of hand rolling it 2020-01-21 18:17:06 +02:00
i915_debugfs.h
i915_debugfs_params.c drm/i915: Include the debugfs params header for its own definition 2020-01-17 13:00:16 +00:00
i915_debugfs_params.h drm/i915/params: add i915 parameters to debugfs 2020-01-15 15:10:16 +02:00
i915_drv.c Merge drm/drm-next into drm-intel-next-queued 2020-01-09 17:19:12 +02:00
i915_drv.h drm/i915: Update DRIVER_DATE to 20200114 2020-01-14 13:39:38 +02:00
i915_fixed.h
i915_gem.c drm/i915: Create dumb buffer from LMEM 2020-01-05 01:09:18 +00:00
i915_gem.h i915 features for v5.6: 2019-12-27 15:25:04 +10:00
i915_gem_evict.c drm/i915: Ignore most failures during evict-vm 2019-12-05 13:50:39 +00:00
i915_gem_fence_reg.c drm/i915: Early return for no-op i915_vma_pin_fence() 2020-01-09 08:53:15 +00:00
i915_gem_fence_reg.h drm/i915: Store i915_ggtt as the backpointer on fence registers 2019-10-16 19:41:36 +01:00
i915_gem_gtt.c drm/i915/gtt: split up i915_gem_gtt 2020-01-07 19:27:36 +00:00
i915_gem_gtt.h drm/i915/gtt: split up i915_gem_gtt 2020-01-07 19:27:36 +00:00
i915_getparam.c drm/i915: Introduce DRM_I915_GEM_MMAP_OFFSET 2019-12-04 15:11:44 +00:00
i915_globals.c drm/i915: Ratelimit i915_globals_park 2019-12-18 17:38:56 +00:00
i915_globals.h
i915_gpu_error.c drm/i915: Don't show the blank process name for internal/simulated errors 2020-01-21 22:27:26 +00:00
i915_gpu_error.h drm/i915: Fix i915_error_state_store error defination 2020-01-17 13:01:02 +00:00
i915_ioc32.c
i915_irq.c drm/i915: prefer 3-letter acronym for ivybridge 2019-12-28 13:38:08 -08:00
i915_irq.h drm/i915: Extract the GuC interrupt handlers 2019-10-26 19:28:59 +01:00
i915_memcpy.c drm/i915: Align start for memcpy_from_wc 2019-12-11 22:40:41 +00:00
i915_memcpy.h drm/i915: Align start for memcpy_from_wc 2019-12-11 22:40:41 +00:00
i915_mm.c drm/i915/gem: Extend mmap support for lmem 2020-01-04 17:57:46 +00:00
i915_params.c drm/i915: drop alpha_support for good in favour of force_probe 2020-01-22 10:51:32 +02:00
i915_params.h drm/i915: drop alpha_support for good in favour of force_probe 2020-01-22 10:51:32 +02:00
i915_pci.c drm/i915: drop alpha_support for good in favour of force_probe 2020-01-22 10:51:32 +02:00
i915_perf.c drm/i915: Pin the context as we work on it 2020-01-09 12:50:26 +00:00
i915_perf.h drm/i915/perf: Register sysctl path globally 2019-12-13 20:16:23 +00:00
i915_perf_types.h drm/i915/perf: Register sysctl path globally 2019-12-13 20:16:23 +00:00
i915_pmu.c drm/i915/pmu: Correct the rc6 offset upon enabling 2020-01-14 12:55:13 +00:00
i915_pmu.h drm/i915/pmu: Ensure monotonic rc6 2019-12-18 15:23:41 +00:00
i915_priolist_types.h drm/i915/gt: Replace hangcheck by heartbeats 2019-10-23 23:52:10 +01:00
i915_pvinfo.h
i915_query.c drm/i915/query: Align flavour of engine data lookup 2019-11-25 15:08:24 +02:00
i915_query.h
i915_reg.h drm/i915: add Wa_14010594013: icl,ehl 2020-01-16 09:33:41 -08:00
i915_request.c drm/i915: Keep track of request among the scheduling lists 2020-01-16 19:56:15 +00:00
i915_request.h drm/i915: Fix typo in kerneldoc function name 2020-01-17 13:20:18 +00:00
i915_scatterlist.c
i915_scatterlist.h
i915_scheduler.c drm/i915: Keep track of request among the scheduling lists 2020-01-16 19:56:15 +00:00
i915_scheduler.h drm/i915: Use a ctor for TYPESAFE_BY_RCU i915_request 2019-11-22 10:47:38 +00:00
i915_scheduler_types.h
i915_selftest.h drm/i915/selftests: Perform some basic cycle counting of MI ops 2019-11-11 18:30:13 +00:00
i915_suspend.c
i915_suspend.h
i915_sw_fence.c drm/i915: Propagate errors on awaiting already signaled dma-fences 2019-12-06 19:09:46 +00:00
i915_sw_fence.h drm/i915: Check for error before calling cmpxchg() 2019-12-06 19:09:33 +00:00
i915_sw_fence_work.c drm/i915: Unpin vma->obj on early error 2019-12-18 10:13:03 +00:00
i915_sw_fence_work.h
i915_switcheroo.c
i915_switcheroo.h
i915_syncmap.c
i915_syncmap.h
i915_sysfs.c drm/i915: Start chopping up the GPU error capture 2020-01-10 15:34:33 +00:00
i915_sysfs.h
i915_trace.h drm/i915/fbc: Add fbc tracepoints 2020-01-15 17:19:59 +02:00
i915_trace_points.c
i915_user_extensions.c
i915_user_extensions.h
i915_utils.c drm-misc-next for v5.6: 2019-12-17 13:57:54 +01:00
i915_utils.h drm/i915: Improve i915_inject_probe_error macro 2019-12-12 12:35:17 +00:00
i915_vgpu.c drm/i915: conversion to new logging macros in i915/i915_vgpu.c 2020-01-17 17:41:33 +02:00
i915_vgpu.h
i915_vma.c drm/i915: Clear the GGTT_WRITE bit on unbinding the vma 2020-01-22 13:21:16 +00:00
i915_vma.h drm/i915/gtt: split up i915_gem_gtt 2020-01-07 19:27:36 +00:00
i915_vma_types.h drm/i915/gtt: split up i915_gem_gtt 2020-01-07 19:27:36 +00:00
intel_csr.c drm/i915: conversion to new logging macros in i915/intel_csr.c 2020-01-17 17:41:33 +02:00
intel_csr.h
intel_device_info.c drm/i915: conversion to new logging macros in i915/intel_device_info.c 2020-01-17 17:41:33 +02:00
intel_device_info.h drm/i915: Flesh out device_info pretty printer 2019-12-09 09:58:51 +00:00
intel_gvt.c drm/i915: convert to new logging macros in i915/intel_gvt.c 2020-01-17 17:44:19 +02:00
intel_gvt.h
intel_memory_region.c drm/i915: convert to new logging macros in i915/intel_memory_region.c 2020-01-17 17:44:19 +02:00
intel_memory_region.h drm/i915: lookup for mem_region of a mem_type 2020-01-05 01:08:09 +00:00
intel_pch.c drm/i915/pch: convert to using the drm_dbg_kms() macro. 2020-01-10 16:10:35 +02:00
intel_pch.h drm/i915: Fix detection for a CMP-V PCH 2019-11-18 16:36:03 +02:00
intel_pm.c drm/i915: add Wa_14010594013: icl,ehl 2020-01-16 09:33:41 -08:00
intel_pm.h drm/i915: Pass dev_priv to ilk_disable_lp_wm() 2019-12-04 15:37:30 +02:00
intel_region_lmem.c drm/i915/lmem: use new struct drm_device based logging macros. 2020-01-10 16:11:04 +02:00
intel_region_lmem.h drm/i915/lmem: add the fake lmem region 2019-10-31 20:41:47 +00:00
intel_runtime_pm.c
intel_runtime_pm.h
intel_sideband.c drm/i915/gen11: Add additional pcode status values 2020-01-14 13:52:52 -08:00
intel_sideband.h
intel_uncore.c drm/i915/uncore: use new struct drm_device based macros. 2020-01-10 16:12:25 +02:00
intel_uncore.h
intel_wakeref.c drm/i915/gt: Flush ongoing retires during wait_for_idle 2020-01-03 00:33:07 +00:00
intel_wakeref.h drm/i915/gt: Flush ongoing retires during wait_for_idle 2020-01-03 00:33:07 +00:00
intel_wopcm.c
intel_wopcm.h