Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 138954
b: refs/heads/master
c: 958a6f8
h: refs/heads/master
v: v3
  • Loading branch information
David Miller authored and Dave Airlie committed Mar 13, 2009
1 parent f39bea7 commit c6057d1
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: f1a2a9b6189f9f5c27672d4d32fec9492c6486b2
refs/heads/master: 958a6f8ccb1964adc3eec84cf401c5baeb4fbca0
6 changes: 5 additions & 1 deletion trunk/drivers/gpu/drm/radeon/r300_cmdbuf.c
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@
#include "radeon_drv.h"
#include "r300_reg.h"

#include <asm/unaligned.h>

#define R300_SIMULTANEOUS_CLIPRECTS 4

/* Values for R300_RE_CLIPRECT_CNTL depending on the number of cliprects
Expand Down Expand Up @@ -917,6 +919,7 @@ static int r300_scratch(drm_radeon_private_t *dev_priv,
{
u32 *ref_age_base;
u32 i, buf_idx, h_pending;
u64 ptr_addr;
RING_LOCALS;

if (cmdbuf->bufsz <
Expand All @@ -930,7 +933,8 @@ static int r300_scratch(drm_radeon_private_t *dev_priv,

dev_priv->scratch_ages[header.scratch.reg]++;

ref_age_base = (u32 *)(unsigned long)*((uint64_t *)cmdbuf->buf);
ptr_addr = get_unaligned((u64 *)cmdbuf->buf);
ref_age_base = (u32 *)(unsigned long)ptr_addr;

cmdbuf->buf += sizeof(u64);
cmdbuf->bufsz -= sizeof(u64);
Expand Down

0 comments on commit c6057d1

Please sign in to comment.