Skip to content

Commit

Permalink
drm/i915: Fix build warning on 32-bit
Browse files Browse the repository at this point in the history
The gtt.stolen_size field is of type size_t, and so should be printed
using %zu to avoid build warnings on either 32-bit and 64-bit builds.

Signed-off-by: Thierry Reding <treding@nvidia.com>
Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
  • Loading branch information
Thierry Reding authored and Jani Nikula committed Aug 26, 2015
1 parent 5f8b253 commit 8e9d597
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/gpu/drm/i915/i915_gem_stolen.c
Original file line number Diff line number Diff line change
Expand Up @@ -348,7 +348,7 @@ int i915_gem_init_stolen(struct drm_device *dev)
* memory, so just consider the start. */
reserved_total = stolen_top - reserved_base;

DRM_DEBUG_KMS("Memory reserved for graphics device: %luK, usable: %luK\n",
DRM_DEBUG_KMS("Memory reserved for graphics device: %zuK, usable: %luK\n",
dev_priv->gtt.stolen_size >> 10,
(dev_priv->gtt.stolen_size - reserved_total) >> 10);

Expand Down

0 comments on commit 8e9d597

Please sign in to comment.