]> pilppa.com Git - linux-2.6-omap-h63xx.git/commit
tracing: replace the crude (unsigned) -1 hackery
authorThomas Gleixner <tglx@linutronix.de>
Wed, 18 Mar 2009 08:03:19 +0000 (09:03 +0100)
committerIngo Molnar <mingo@elte.hu>
Wed, 18 Mar 2009 09:10:17 +0000 (10:10 +0100)
commit2c7eea4c62ba090b7f4583c3d7337ea0019be900
tree2a85739caeef13035316d47f61cab11f3a91660f
parent18aecd362a1c991fbf5f7919ae051a77532ba2f8
tracing: replace the crude (unsigned) -1 hackery

Impact: cleanup

The command line recorder uses (unsigned) -1 to mark non mapped
entries in the pid to command line maps. The validity check is
completely unintuitive: idx >= SAVED_CMDLINES

There is no need for such casting games. Use a constant to mark
unmapped entries and check for that constant to make the code readable
and understandable.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Cc: Steven Rostedt <srostedt@redhat.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
LKML-Reference: <new-submission>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
kernel/trace/trace.c