Commit 55a5cb5d authored by Pauli Nieminen's avatar Pauli Nieminen Committed by Dave Airlie

drm/radeon: Fix printf type warning in 64bit system.

Type of iterator was promoted to unsigned long in 64bit systems.

*header is small structure so it is alwas safe to cast return value
of sizeof operator to int.
Signed-off-by: default avatarPauli Nieminen <suokkos@gmail.com>
parent 0de1a57b
...@@ -767,7 +767,7 @@ static __inline__ int r300_emit_packet3(drm_radeon_private_t *dev_priv, ...@@ -767,7 +767,7 @@ static __inline__ int r300_emit_packet3(drm_radeon_private_t *dev_priv,
default: default:
DRM_ERROR("bad packet3 type %i at byte %d\n", DRM_ERROR("bad packet3 type %i at byte %d\n",
header.packet3.packet, header.packet3.packet,
cmdbuf->buffer->iterator - sizeof(header)); cmdbuf->buffer->iterator - (int)sizeof(header));
return -EINVAL; return -EINVAL;
} }
...@@ -1153,7 +1153,7 @@ int r300_do_cp_cmdbuf(struct drm_device *dev, ...@@ -1153,7 +1153,7 @@ int r300_do_cp_cmdbuf(struct drm_device *dev,
default: default:
DRM_ERROR("bad cmd_type %i at byte %d\n", DRM_ERROR("bad cmd_type %i at byte %d\n",
header->header.cmd_type, header->header.cmd_type,
cmdbuf->buffer->iterator - sizeof(*header)); cmdbuf->buffer->iterator - (int)sizeof(*header));
ret = -EINVAL; ret = -EINVAL;
goto cleanup; goto cleanup;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment