2010/4/8 Onkar Mahajan <kern.devel@xxxxxxxxx>: > What is LIST_POISON1 and LIST_POISON2 ?? > > #define LIST_POISON1 ((void *) 0x00100100 + POISON_POINTER_DELTA) > #define LIST_POISON2 ((void *) 0x00200200 + POISON_POINTER_DELTA) > > and why they are used ? > > Regards, > Onkar > Hi Onkar, A "poison" value is a convenient value that you can detect when debugging. For instance if you find out that a pointer is 0xdeadbeef, you can easily imagine this is some uninitialized value. If you had used a NULL value, it would be harder to determine whether it's something uninitialized ... Hope this helps, Cédric -- To unsubscribe from this list: send an email with "unsubscribe kernelnewbies" to ecartis@xxxxxxxxxxxx Please read the FAQ at http://kernelnewbies.org/FAQ