All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm/i915: Drop const qualifiers from params in wait_for_register()
@ 2017-04-10  9:38 Michal Wajdeczko
  2017-04-10  9:43 ` Chris Wilson
  2017-04-10 10:00 ` ✓ Fi.CI.BAT: success for " Patchwork
  0 siblings, 2 replies; 4+ messages in thread
From: Michal Wajdeczko @ 2017-04-10  9:38 UTC (permalink / raw)
  To: intel-gfx

These params are passed by value, const qualifiers are ignored any way.
While around, unify timeout_ms type from long to int.

Signed-off-by: Michal Wajdeczko <michal.wajdeczko@intel.com>
Suggested-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
---
 drivers/gpu/drm/i915/i915_drv.h     | 20 ++++++++++----------
 drivers/gpu/drm/i915/intel_uncore.c | 14 +++++++-------
 2 files changed, 17 insertions(+), 17 deletions(-)

diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h
index bb6fc1e..ed079c2 100644
--- a/drivers/gpu/drm/i915/i915_drv.h
+++ b/drivers/gpu/drm/i915/i915_drv.h
@@ -3085,22 +3085,22 @@ void assert_forcewakes_inactive(struct drm_i915_private *dev_priv);
 
 int intel_wait_for_register(struct drm_i915_private *dev_priv,
 			    i915_reg_t reg,
-			    const u32 mask,
-			    const u32 value,
-			    const unsigned long timeout_ms);
+			    u32 mask,
+			    u32 value,
+			    unsigned int timeout_ms);
 int __intel_wait_for_register_fw(struct drm_i915_private *dev_priv,
 				 i915_reg_t reg,
-				 const u32 mask,
-				 const u32 value,
-				 const unsigned int fast_timeout_us,
-				 const unsigned int slow_timeout_ms,
+				 u32 mask,
+				 u32 value,
+				 unsigned int fast_timeout_us,
+				 unsigned int slow_timeout_ms,
 				 u32 *out_value);
 static inline
 int intel_wait_for_register_fw(struct drm_i915_private *dev_priv,
 			       i915_reg_t reg,
-			       const u32 mask,
-			       const u32 value,
-			       const unsigned int timeout_ms)
+			       u32 mask,
+			       u32 value,
+			       unsigned int timeout_ms)
 {
 	return __intel_wait_for_register_fw(dev_priv, reg, mask, value,
 					    2, timeout_ms, NULL);
diff --git a/drivers/gpu/drm/i915/intel_uncore.c b/drivers/gpu/drm/i915/intel_uncore.c
index ace0993..1deb1a4 100644
--- a/drivers/gpu/drm/i915/intel_uncore.c
+++ b/drivers/gpu/drm/i915/intel_uncore.c
@@ -1610,10 +1610,10 @@ static int gen6_reset_engines(struct drm_i915_private *dev_priv,
  */
 int __intel_wait_for_register_fw(struct drm_i915_private *dev_priv,
 				 i915_reg_t reg,
-				 const u32 mask,
-				 const u32 value,
-				 const unsigned int fast_timeout_us,
-				 const unsigned int slow_timeout_ms,
+				 u32 mask,
+				 u32 value,
+				 unsigned int fast_timeout_us,
+				 unsigned int slow_timeout_ms,
 				 u32 *out_value)
 {
 	u32 reg_value;
@@ -1651,9 +1651,9 @@ int __intel_wait_for_register_fw(struct drm_i915_private *dev_priv,
  */
 int intel_wait_for_register(struct drm_i915_private *dev_priv,
 			    i915_reg_t reg,
-			    const u32 mask,
-			    const u32 value,
-			    const unsigned long timeout_ms)
+			    u32 mask,
+			    u32 value,
+			    unsigned int timeout_ms)
 {
 
 	unsigned fw =
-- 
2.7.4

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

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] drm/i915: Drop const qualifiers from params in wait_for_register()
  2017-04-10  9:38 [PATCH] drm/i915: Drop const qualifiers from params in wait_for_register() Michal Wajdeczko
@ 2017-04-10  9:43 ` Chris Wilson
  2017-04-10 10:00 ` ✓ Fi.CI.BAT: success for " Patchwork
  1 sibling, 0 replies; 4+ messages in thread
From: Chris Wilson @ 2017-04-10  9:43 UTC (permalink / raw)
  To: Michal Wajdeczko; +Cc: intel-gfx

On Mon, Apr 10, 2017 at 09:38:17AM +0000, Michal Wajdeczko wrote:
> These params are passed by value, const qualifiers are ignored any way.

They are not completely ignored, it just means you are not allowed to
alter the value inside the function. But it doesn't improve code
generation.

> While around, unify timeout_ms type from long to int.
> 
> Signed-off-by: Michal Wajdeczko <michal.wajdeczko@intel.com>
> Suggested-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
> Cc: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
-Chris

-- 
Chris Wilson, Intel Open Source Technology Centre
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 4+ messages in thread

* ✓ Fi.CI.BAT: success for drm/i915: Drop const qualifiers from params in wait_for_register()
  2017-04-10  9:38 [PATCH] drm/i915: Drop const qualifiers from params in wait_for_register() Michal Wajdeczko
  2017-04-10  9:43 ` Chris Wilson
@ 2017-04-10 10:00 ` Patchwork
  2017-04-10 13:08   ` Chris Wilson
  1 sibling, 1 reply; 4+ messages in thread
From: Patchwork @ 2017-04-10 10:00 UTC (permalink / raw)
  To: Michal Wajdeczko; +Cc: intel-gfx

== Series Details ==

Series: drm/i915: Drop const qualifiers from params in wait_for_register()
URL   : https://patchwork.freedesktop.org/series/22763/
State : success

== Summary ==

Series 22763v1 drm/i915: Drop const qualifiers from params in wait_for_register()
https://patchwork.freedesktop.org/api/1.0/series/22763/revisions/1/mbox/

Test gem_exec_suspend:
        Subgroup basic-s4-devices:
                pass       -> DMESG-WARN (fi-kbl-7560u) fdo#100125
Test kms_pipe_crc_basic:
        Subgroup suspend-read-crc-pipe-a:
                pass       -> FAIL       (fi-skl-6700k) fdo#100367

fdo#100125 https://bugs.freedesktop.org/show_bug.cgi?id=100125
fdo#100367 https://bugs.freedesktop.org/show_bug.cgi?id=100367

fi-bdw-5557u     total:278  pass:267  dwarn:0   dfail:0   fail:0   skip:11  time:437s
fi-bdw-gvtdvm    total:278  pass:256  dwarn:8   dfail:0   fail:0   skip:14  time:426s
fi-bsw-n3050     total:278  pass:242  dwarn:0   dfail:0   fail:0   skip:36  time:574s
fi-bxt-j4205     total:278  pass:259  dwarn:0   dfail:0   fail:0   skip:19  time:507s
fi-bxt-t5700     total:278  pass:258  dwarn:0   dfail:0   fail:0   skip:20  time:560s
fi-byt-j1900     total:278  pass:254  dwarn:0   dfail:0   fail:0   skip:24  time:484s
fi-byt-n2820     total:278  pass:250  dwarn:0   dfail:0   fail:0   skip:28  time:481s
fi-hsw-4770      total:278  pass:262  dwarn:0   dfail:0   fail:0   skip:16  time:410s
fi-hsw-4770r     total:278  pass:262  dwarn:0   dfail:0   fail:0   skip:16  time:406s
fi-ilk-650       total:278  pass:228  dwarn:0   dfail:0   fail:0   skip:50  time:426s
fi-ivb-3520m     total:278  pass:260  dwarn:0   dfail:0   fail:0   skip:18  time:484s
fi-ivb-3770      total:278  pass:260  dwarn:0   dfail:0   fail:0   skip:18  time:471s
fi-kbl-7500u     total:278  pass:260  dwarn:0   dfail:0   fail:0   skip:18  time:459s
fi-kbl-7560u     total:278  pass:267  dwarn:1   dfail:0   fail:0   skip:10  time:566s
fi-skl-6260u     total:278  pass:268  dwarn:0   dfail:0   fail:0   skip:10  time:451s
fi-skl-6700hq    total:278  pass:261  dwarn:0   dfail:0   fail:0   skip:17  time:572s
fi-skl-6700k     total:278  pass:255  dwarn:4   dfail:0   fail:1   skip:18  time:459s
fi-skl-6770hq    total:278  pass:268  dwarn:0   dfail:0   fail:0   skip:10  time:499s
fi-skl-gvtdvm    total:278  pass:265  dwarn:0   dfail:0   fail:0   skip:13  time:431s
fi-snb-2520m     total:278  pass:250  dwarn:0   dfail:0   fail:0   skip:28  time:531s
fi-snb-2600      total:278  pass:249  dwarn:0   dfail:0   fail:0   skip:29  time:400s

d86f5fa557fdf089bdb5b51f625a7f5967f11015 drm-tip: 2017y-04m-10d-06h-38m-49s UTC integration manifest
a5fcad1 drm/i915: Drop const qualifiers from params in wait_for_register()

== Logs ==

For more details see: https://intel-gfx-ci.01.org/CI/Patchwork_4456/
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: ✓ Fi.CI.BAT: success for drm/i915: Drop const qualifiers from params in wait_for_register()
  2017-04-10 10:00 ` ✓ Fi.CI.BAT: success for " Patchwork
@ 2017-04-10 13:08   ` Chris Wilson
  0 siblings, 0 replies; 4+ messages in thread
From: Chris Wilson @ 2017-04-10 13:08 UTC (permalink / raw)
  To: intel-gfx

On Mon, Apr 10, 2017 at 10:00:30AM -0000, Patchwork wrote:
> == Series Details ==
> 
> Series: drm/i915: Drop const qualifiers from params in wait_for_register()
> URL   : https://patchwork.freedesktop.org/series/22763/
> State : success
> 
> == Summary ==
> 
> Series 22763v1 drm/i915: Drop const qualifiers from params in wait_for_register()
> https://patchwork.freedesktop.org/api/1.0/series/22763/revisions/1/mbox/
> 
> Test gem_exec_suspend:
>         Subgroup basic-s4-devices:
>                 pass       -> DMESG-WARN (fi-kbl-7560u) fdo#100125
> Test kms_pipe_crc_basic:
>         Subgroup suspend-read-crc-pipe-a:
>                 pass       -> FAIL       (fi-skl-6700k) fdo#100367
> 
> fdo#100125 https://bugs.freedesktop.org/show_bug.cgi?id=100125
> fdo#100367 https://bugs.freedesktop.org/show_bug.cgi?id=100367

Pushed, thanks for the patch.
-Chris

-- 
Chris Wilson, Intel Open Source Technology Centre
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2017-04-10 13:08 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-04-10  9:38 [PATCH] drm/i915: Drop const qualifiers from params in wait_for_register() Michal Wajdeczko
2017-04-10  9:43 ` Chris Wilson
2017-04-10 10:00 ` ✓ Fi.CI.BAT: success for " Patchwork
2017-04-10 13:08   ` Chris Wilson

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.