Skip to contentSkip to conversation

vdso: check the value of vdso_enabled

PATCH New WANG Cong 1 participant 1 message Jul 18, 2008 x86

lore
Share & tools
lore

WANG Cong

author
#0 lore raw

PATCH 1/1 vdso: check the value of vdso_enabled

When the value of 'vdso_enabled' is out of range, make it default.

---

arch/x86/vdso/vdso32-setup.c +2 -0
index 0bce542..3428448 100644
@@ -59,6 +59,8 @@ unsigned int __read_mostly vdso_enabled = VDSO_DEFAULT;
 static int __init vdso_setup(char *s)
 {
 	vdso_enabled = simple_strtoul(s, NULL, 0);
+	if (vdso_enabled > VDSO_COMPAT)
+		vdso_enabled = VDSO_DEFAULT;
 
 	return 1;
 }