Add Propolice support

git-svn-id: svn://coreboot.org/openbios/openbios-devel@422 f158a5a8-5612-0410-a976-696ce0be7e32
This commit is contained in:
Blue Swirl
2009-01-24 08:23:33 +00:00
parent 7a00116a9f
commit 037d00c9b5
3 changed files with 26 additions and 4 deletions

View File

@@ -75,3 +75,24 @@ strtol( const char *nptr, char **endptr, int base )
return sum * sign;
}
// Propolice support
long __guard[8] = {
#ifdef CONFIG_BIG_ENDIAN
(0 << 24) | (0 << 16) | ('\n' << 8) | 255,
#else
(255 << 24) | ('\n' << 16) | (0 << 8) | 0,
#endif
0, 0, 0, 0, 0, 0, 0
};
void __stack_smash_handler(const char *func, int damaged)
{
printk("Propolice detected a stack smashing attack %x at function %s,"
" freezing\n", damaged, func);
// Freeze
// XXX: Disable interrupts?
for(;;)
;
}