Re: module scanning in kgdb 2.x

From: Rusty Russell
Date: Tue Mar 16 2004 - 16:27:45 EST


On Fri, 2004-03-12 at 17:36, Amit S. Kale wrote:
> Hi,

Hi Amit,

FYI: you would have received a quicker response if you'd CC'd me.

> It does following things:
> 1. Adds MODULE_STATE_GONE to indicate that a module was removed. This is
> differnent from MODULE_STATE_GOING. gdb needs to be notified of a module
> event _after_ a module has been removed. Or else it'll still find the module
> during a module list scan and will not remove it from its core.

Makes sense.

> 2. Defines a structure mod_section which stores module section names and
> offsets preserved during loading of a module.
>
> 3. Adds a couple of fields to struct module to keep module section
> information.

Why not just set the section strings to SHF_ALLOC rather than copying
(and possibly truncating) the names into your struct mod_section?
struct mod_section is then simply void *addr; char *name;

Cheers,
Rusty.
--
Anyone who quotes me in their signature is an idiot -- Rusty Russell

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