Sunday, 6 May 2012

Generate OOPS and kernel panic in kernel ( module )

From some mailing list :

For OOPS :
--------------------------------
create a module.... and in the init function.....

int init_module(void)
{
     /* deferencing a null pointer */
     *(int*)0 = 1 ;
     return 0;
}

the kernel will generate an oops when you insert this module.

---------------------------------

For Kernel panic , need to search still.  

No comments:

Post a Comment

Related Posts Plugin for WordPress, Blogger...