[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] State of gdbsx in xen-4.0-testing.hg and debugger documentation.


  • To: Mukesh Rathor <mukesh.rathor@xxxxxxxxxx>
  • From: Bruce Edge <bruce.edge@xxxxxxxxx>
  • Date: Tue, 28 Sep 2010 09:55:59 -0700
  • Cc: xen-devel@xxxxxxxxxxxxxxxxxxx, Konrad Rzeszutek Wilk <konrad.wilk@xxxxxxxxxx>
  • Delivery-date: Tue, 28 Sep 2010 09:56:54 -0700
  • Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=fKYtJ7exaF3D+/YYm0FQlsgH8dCQ9vyv0j2KboMzOwFEe7NzACBQYQZ7jRD9FqIPeb QL+Ga4AXOIM1HEupvR6MlI0Ce1Lxn6PC2F5Y8lurxzaQ7pY1jFPSnZVGFdfySNxWu72Z l3WcL+tNukdsuouVktC4ym38hVBU/TX0OXGQ4=
  • List-id: Xen developer discussion <xen-devel.lists.xensource.com>

On Wed, Jul 14, 2010 at 2:10 PM, Mukesh Rathor <mukesh.rathor@xxxxxxxxxx> wrote:
>
>
> On Tue, 13 Jul 2010 22:29:48 -0700
> Bruce Edge <bruce.edge@xxxxxxxxx> wrote:
>> The docs for using gdbsx state:
>>
>>    - Additionally, to debug loadable kernel modules, please do
>> following: (gdb) p init_mm.pgd[3]
>>       $1 = {pgd = 0x1b874f027}
>>       (gdb) monitor pgd3 0x1b874f027  (Make sure value is in HEX)
>>       pgd3val set to: 0x1b874f027
>>
>> When I try to use this to access a module, I get:
>>
>> (gdb) p init_mm.pgd[3]
>> $10 = {pgd = 0}
>> (gdb)
>>
>> I assume that the value of pgd should not be 0 as the makes the next
>> command it the docs meaningless.
>>
>> Is it possible that the field [3] offset has changed?
>> What field are we after with this command?
>>
>
> Bruce,
>
> This for 32bit domU kernel only. I guess the README is not updated in
> all trees.. I'll submit patch to do this.
>
> Thanks,
> Mukesh
>
>

Mukesh,
I'm getting back to working on the debugger and have not been able to
use it with any modules. How does one set breakpoints for modules that
are not loaded?
This may be a lack of experience with kernel/gdb context, but how does
one go about setting a breakpoint in a module's init code?
Is there any method to use to put in a symbolic function name as a
breakpoint for a module that is not yet loaded?

Are there any tutorials illustrating the use of gdbsx with a custom
kernel module? This would be most helpful.

Thanks

-Bruce

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.