diff options
author | Pauli Nieminen <suokkos@gmail.com> | 2010-03-01 04:37:11 -0500 |
---|---|---|
committer | Dave Airlie <airlied@ppcg5.localdomain> | 2010-03-01 06:21:37 -0500 |
commit | 55a5cb5d594c18b3147a2288b00ea359c1a38cf8 (patch) | |
tree | b256f63a4ee7bc5ef7fc81035b4e28636c8fcde2 /drivers/gpu | |
parent | 0de1a57bedce0899c98da4c0910d4f38c9b7c8f4 (diff) |
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: Pauli Nieminen <suokkos@gmail.com>
Diffstat (limited to 'drivers/gpu')
-rw-r--r-- | drivers/gpu/drm/radeon/r300_cmdbuf.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/radeon/r300_cmdbuf.c b/drivers/gpu/drm/radeon/r300_cmdbuf.c index 7f59352cd637..ea46d558e8f3 100644 --- a/drivers/gpu/drm/radeon/r300_cmdbuf.c +++ b/drivers/gpu/drm/radeon/r300_cmdbuf.c | |||
@@ -767,7 +767,7 @@ static __inline__ int r300_emit_packet3(drm_radeon_private_t *dev_priv, | |||
767 | default: | 767 | default: |
768 | DRM_ERROR("bad packet3 type %i at byte %d\n", | 768 | DRM_ERROR("bad packet3 type %i at byte %d\n", |
769 | header.packet3.packet, | 769 | header.packet3.packet, |
770 | cmdbuf->buffer->iterator - sizeof(header)); | 770 | cmdbuf->buffer->iterator - (int)sizeof(header)); |
771 | return -EINVAL; | 771 | return -EINVAL; |
772 | } | 772 | } |
773 | 773 | ||
@@ -1153,7 +1153,7 @@ int r300_do_cp_cmdbuf(struct drm_device *dev, | |||
1153 | default: | 1153 | default: |
1154 | DRM_ERROR("bad cmd_type %i at byte %d\n", | 1154 | DRM_ERROR("bad cmd_type %i at byte %d\n", |
1155 | header->header.cmd_type, | 1155 | header->header.cmd_type, |
1156 | cmdbuf->buffer->iterator - sizeof(*header)); | 1156 | cmdbuf->buffer->iterator - (int)sizeof(*header)); |
1157 | ret = -EINVAL; | 1157 | ret = -EINVAL; |
1158 | goto cleanup; | 1158 | goto cleanup; |
1159 | } | 1159 | } |