Skip to contentSkip to conversation

DRM: Rename clamp variable

PATCH Applied Andi Kleen 2 participants 2 messages Dec 21, 2009

Subsystems (2)
lore
Share & tools
lore

Andi Kleen

author
#0 lore raw

PATCH 1/1 DRM: Rename clamp variable

DRM: Rename clamp variable

linux/kernel.h has a "clamp" macro, but r300_cmdbuf also uses a variable with the same name. Right now it doesn't seem to include the header, but sooner or later someone will. So better rename the variable now.

---
 drivers/gpu/drm/radeon/r300_cmdbuf.c |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/gpu/drm/radeon/r300_cmdbuf.c +3 -3
Index: linux-2.6.33-rc1-ak/drivers/gpu/drm/radeon/r300_cmdbuf.c
===================================================================
@@ -990,7 +990,7 @@ static inline int r300_emit_r500fp(drm_r
 	int sz;
 	int addr;
 	int type;
-	int clamp;
+	int isclamp;
 	int stride;
 	RING_LOCALS;
 
@@ -999,10 +999,10 @@ static inline int r300_emit_r500fp(drm_r
 	addr = ((header.r500fp.adrhi_flags & 1) << 8) | header.r500fp.adrlo;
 
 	type = !!(header.r500fp.adrhi_flags & R500FP_CONSTANT_TYPE);
-	clamp = !!(header.r500fp.adrhi_flags & R500FP_CONSTANT_CLAMP);
+	isclamp = !!(header.r500fp.adrhi_flags & R500FP_CONSTANT_CLAMP);
 
 	addr |= (type << 16);
-	addr |= (clamp << 17);
+	addr |= (isclamp << 17);
 
 	stride = type ? 4 : 6;
 
maintainer Applied
#1 lore raw
Quoted 8 lines · Andi Kleen

DRM: Rename clamp variable

linux/kernel.h has a "clamp" macro, but r300_cmdbuf also uses a variable with the same name. Right now it doesn't seem to include the header, but sooner or later someone will. So better rename the variable now.

Queued for drm-core-next, will push to Linus in next push.

Thanks,
Dave.