Skip to contentSkip to conversation

Use constant instead of raw number in x86_64 ioperm.c

PATCH New Glauber de Oliveira Costa 1 participant 1 message Jan 4, 2007

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Use constant instead of raw number in x86_64 ioperm.c

This is a tiny cleanup to increase readability

Signature · 3 lines
Glauber de Oliveira Costa
Red Hat Inc.
"Free as in Freedom"
arch/x86_64/kernel/ioport.c +1 -1
diff -Nrup linux-2.6.19.1/arch/x86_64/kernel/ioport.c linux-2.6.19.1-devel/arch/x86_64/kernel/ioport.c
@@ -114,6 +114,6 @@ asmlinkage long sys_iopl(unsigned int le
 		if (!capable(CAP_SYS_RAWIO))
 			return -EPERM;
 	}
-	regs->eflags = (regs->eflags &~ 0x3000UL) | (level << 12);
+	regs->eflags = (regs->eflags &~ X86_EFLAGS_IOPL) | (level << 12);
 	return 0;
 }