Re: [PATCH] show_trace() module_end = 0?

Hugh Dickins (hugh@veritas.com)
Thu, 2 Aug 2001 18:58:06 +0100 (BST)


On Thu, 2 Aug 2001, Kai Germaschewski wrote:
>
> As I need module back traces once in a while, I was not really happy with
> the current approach. I coded a patch which will reenable printing a call
> trace including addresses in modules.

Haven't tried it, but looks good to me.

> I'm not sure if this an approach you would accept. The code makes sure
> that only addresses within a vmalloc'ed module area are printed, not
> everything between VMALLOC_START and _END. However, we don't distinguish
> between module .text as opposed to .data, .bss... Doing so seems a lot
> harder to implement.

Much better than the original VMALLOC_START to VMALLOC_END, much better
than the current none-at-all, much better than going down the vmlist.

(The text could perhaps be identified at module load time, by looking
at the "__insmod_" symbols; but that would be a hack, you're right not
to try any such thing in this patch.)

> The other, minor problem is that we should walk the module_list under
> lock_kernel() only, but I wasn't brave enough to add this to the
> show_trace() code path.

I think it's just modlist_lock you'd need. Not sure whether better
to try for it or ignore it. CC'ed Andrew "spinlock-buster" Morton
for his opinion.

Hugh

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/