From: Thomas Gleixner <tglx@linutronix.de>
To: Stanislaw Gruszka <sgruszka@redhat.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2] debugobjects: print more data
Date: Mon, 21 Feb 2011 15:30:56 +0100 (CET) [thread overview]
Message-ID: <alpine.LFD.2.00.1102211530090.2701@localhost6.localdomain6> (raw)
In-Reply-To: <20110221142329.GA6105@redhat.com>
On Mon, 21 Feb 2011, Stanislaw Gruszka wrote:
> --- a/lib/Kconfig.debug
> +++ b/lib/Kconfig.debug
> @@ -276,6 +276,7 @@ config TIMER_STATS
> config DEBUG_OBJECTS
> bool "Debug object operations"
> depends on DEBUG_KERNEL
> + select KALLSYMS
Again, we don't enforce kallsyms with DO
> help
> If you say Y here, additional code will be inserted into the
> kernel to track the life time of various objects and validate
> diff --git a/lib/debugobjects.c b/lib/debugobjects.c
> index deebcc5..d5fcdeb 100644
> --- a/lib/debugobjects.c
> +++ b/lib/debugobjects.c
> @@ -14,6 +14,7 @@
> #include <linux/debugfs.h>
> #include <linux/slab.h>
> #include <linux/hash.h>
> +#include <linux/kallsyms.h>
Please remove.
>
> #define ODEBUG_HASH_BITS 14
> #define ODEBUG_HASH_SIZE (1 << ODEBUG_HASH_BITS)
> @@ -253,10 +254,13 @@ static void debug_print_object(struct debug_obj *obj, char *msg)
>
> if (limit < 5 && obj->descr != descr_test) {
> limit++;
> - WARN(1, KERN_ERR "ODEBUG: %s %s (active state %u) "
> - "object type: %s\n",
> + printk(KERN_ERR "ODEBUG: %s %s (active state %u) "
> + "object type: %s\n",
> msg, obj_states[obj->state], obj->astate,
> obj->descr->name);
> + dump_stack();
> + if (obj->descr->print)
> + obj->descr->print(obj->object);
> }
> debug_objects_warnings++;
> }
> --
> 1.7.1
>
prev parent reply other threads:[~2011-02-21 14:31 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-02-21 14:23 Stanislaw Gruszka
2011-02-21 14:30 ` Thomas Gleixner [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=alpine.LFD.2.00.1102211530090.2701@localhost6.localdomain6 \
--to=tglx@linutronix.de \
--cc=linux-kernel@vger.kernel.org \
--cc=sgruszka@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®