Philippe Elie df9d177aa2 oProfile: oops when profile_pc() returns ~0LU
Instruction pointer returned by profile_pc() can be a random value.  This
break the assumption than we can safely set struct op_sample.eip field to a
magic value to signal to the per-cpu buffer reader side special event like
task switch ending up in a segfault in get_task_mm() when profile_pc()
return ~0UL.  Fixed by sanitizing the sampled eip and reject/log invalid
eip.

Problem reported by Sami Farin, patch tested by him.

Signed-off-by: Philippe Elie <phil.el@wanadoo.fr>
Tested-by: Sami Farin <safari-kernel@safari.iki.fi>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-11-14 18:45:37 -08:00
..
2007-10-17 08:42:52 -07:00
2007-11-02 08:47:06 +01:00
2007-11-14 18:45:37 -08:00
2007-10-29 17:27:50 -04:00
2007-10-16 09:43:09 -07:00
2007-10-19 11:53:42 -07:00
2007-10-20 01:34:40 +02:00
2007-11-05 15:12:31 -08:00
2007-11-05 21:54:41 +00:00
2007-11-05 15:12:31 -08:00
2007-10-20 01:34:40 +02:00
2007-10-25 17:43:46 -04:00
2007-11-10 11:59:49 +01:00
2007-10-23 09:49:31 +02:00
2007-10-19 11:53:41 -07:00
2007-10-19 11:53:41 -07:00
2007-11-14 18:45:36 -08:00
2007-10-20 15:04:06 -07:00
2007-10-29 07:41:33 -07:00
2007-10-17 08:42:57 -07:00
2007-11-02 08:47:06 +01:00
2007-11-14 18:45:36 -08:00
2007-10-23 15:49:54 +10:00