<div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Aug 6, 2013 at 10:43 AM, Saket Sinha <span dir="ltr"><<a href="mailto:saket.sinha89@gmail.com" target="_blank">saket.sinha89@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Actually I need to ask you something rather than offering a solution. Actually I have a similar sort of situation so I think I would ask here.<div>
</div></div></blockquote><div>Please don't do this. Ask the question separately. There are better chances of getting answer from looking at the topic of mail then piggybacking at some else's mail. Not to mention it is just bad mailing list netiquettes. <br>
</div><div>Secondly do not top post. I don't understand why is so hard to follow a simple rule which is pretty much a norm on all open source mailing list.<br></div><div>May be this will help<br><a href="http://kernelnewbies.org/mailinglistguidelines">http://kernelnewbies.org/mailinglistguidelines</a><br>
</div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div><div><div style="font-family:arial,sans-serif;font-size:13px">
The issue I am facing is that I have been developing a filesystem driver(over x86) which has become "unstable" by which I mean , at compile time it is building but during runtime it fails when I call the corresponding APIs from the user-space.</div>
<div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px">In order to find out exactly where it is failing, I need to debug the driver.</div></div><div style="font-family:arial,sans-serif;font-size:13px">
I am very new to kernel development. I have heard about KGDB and KDB but it takes quite a lot to get them working so waht are the other tools available?</div><div style="font-family:arial,sans-serif;font-size:13px"><br></div>
</div></div></blockquote><div>Well if you are debugging a kernel driver at filesystem level it will take time, there are really no shortcuts and kgdb might be your best bet. <br></div><div>You can have a look at debugfs which might be useful<br>
<a href="http://www.linuxforu.com/2010/10/debugging-linux-kernel-with-debugfs/">http://www.linuxforu.com/2010/10/debugging-linux-kernel-with-debugfs/</a><br></div><div>Another link I found by simple search<br><a href="http://confluence.jetbrains.com/display/~roman.shevchenko/Debugging+native+file+system+watcher+for+Linux">http://confluence.jetbrains.com/display/~roman.shevchenko/Debugging+native+file+system+watcher+for+Linux</a><br>
<br></div><div>Lastly there was some discussion on Filesystem debugging on *this* very mailing list, so I would suggest you search in archives.<br></div><div></div><div><br></div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div dir="ltr"><div><div style="font-family:arial,sans-serif;font-size:13px"></div>
<div style="font-family:arial,sans-serif;font-size:13px">Regards,</div><div style="font-family:arial,sans-serif;font-size:13px">Saket Sinha</div><div style="font-family:arial,sans-serif;font-size:13px"><br></div><div style="font-family:arial,sans-serif;font-size:13px">
<br></div></div></div><div class="gmail_extra"><br><br><div class="gmail_quote"><div><div class="h5">On Tue, Aug 6, 2013 at 2:36 PM, nidhi mittal hada <span dir="ltr"><<a href="mailto:nidhimittal19@gmail.com" target="_blank">nidhimittal19@gmail.com</a>></span> wrote:<br>
</div></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div><div class="h5"><br><br><div class="gmail_quote">---------- Forwarded message ----------<br>
From: <b class="gmail_sendername">nidhi mittal hada</b> <span dir="ltr"><<a href="mailto:nidhimittal19@gmail.com" target="_blank">nidhimittal19@gmail.com</a>></span><br>
Date: Tue, Aug 6, 2013 at 2:16 PM<br>Subject: Understanding disassembly x86 + understanding function call + parameter pass and stack frame<br>To: Kernelnewbies <<a href="mailto:kernelnewbies@nl.linux.org" target="_blank">kernelnewbies@nl.linux.org</a>><br>
Cc: Mulyadi Santosa <<a href="mailto:mulyadi.santosa@gmail.com" target="_blank">mulyadi.santosa@gmail.com</a>><br><br><br>Hi All,<br><br>I am using crash tool to analyze core dump obtained from red hat linux on x86_64 platform.<br>
<br>And crash tool gives a stack trace of panic.<br>But its does not show function parameters which were passed in this stack trace.<br>
<br>So i have to disassemble and understand the value of parameters passed to these functions, while it panicked.<br>Which i am not able to understand much. <br><br>I would request help in knowing, how to understand disassembled function call , on x86_64 arch.<br>
<br>Putting some of the doubts.. <br><br>a)like which sequence the parameters, return address, etc are pushed on stack?<br>b)Which registers are used, if some registers play some spl. role ?<br>c)lets say for a program a.c i use gcc -S a.c ...do we have some other command to generate <br>
somewhat more clear assembly code, may be with some comments in english <br><br>Any kind of help in understanding this will be appreciated ..<br><br>Thanks<span><font color="#888888"><span><font color="#888888"><br>
Nidhi<br><br><br>
</font></span></font></span></div><span><font color="#888888"><br><br clear="all"><br>-- <br>Thanks & Regards <br>Nidhi Mittal Hada<br><br><a href="http://nidhi-searchingmyself.blogspot.com/" target="_blank">http://nidhi-searchingmyself.blogspot.com/</a><br>
<br>
</font></span><br></div></div>_______________________________________________<br>
Kernelnewbies mailing list<br>
<a href="mailto:Kernelnewbies@kernelnewbies.org" target="_blank">Kernelnewbies@kernelnewbies.org</a><br>
<a href="http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies" target="_blank">http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies</a><br>
<br></blockquote></div><br></div>
<br>_______________________________________________<br>
Kernelnewbies mailing list<br>
<a href="mailto:Kernelnewbies@kernelnewbies.org">Kernelnewbies@kernelnewbies.org</a><br>
<a href="http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies" target="_blank">http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies</a><br>
<br></blockquote></div><br><br clear="all"><br>-- <br>Thank you <br>Warm Regards<br>Anuz<br>
</div></div>