All of lore.kernel.org
 help / color / mirror / Atom feed
From: Helge Deller <deller@gmx.de>
To: petkovbb@gmail.com
Cc: Linus <torvalds@linux-foundation.org>,
	Borislav Petkov <petkovbb@googlemail.com>,
	Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>,
	Kyle McMartin <kyle@mcmartin.ca>,
	linux-parisc <linux-parisc@vger.kernel.org>,
	"Rafael J. Wysocki" <rjw@sisk.pl>
Subject: Re: [PATCH] ide-cd: fix kernel crash on hppa regression
Date: Thu, 16 Apr 2009 22:26:06 +0200	[thread overview]
Message-ID: <49E7945E.7030508@gmx.de> (raw)
In-Reply-To: <20090416063735.GA21742@liondog.tnic>

Hi Borislav,

Borislav Petkov wrote:
> Hi,
> 
> On Thu, Apr 16, 2009 at 12:45:31AM +0200, Helge Deller wrote:
>> With 2.6.30-rc2 I face a kernel crash on the 32bit hppa architecture 
>> due to ide-cd when udev creates the device nodes at startup:
>>
>> Kernel Fault: Code=26 regs=8ed34c40 (Addr=00000024)
>> IASQ: 00000000 00000000 IAOQ: 1034b5ac 1034b5b0
>>  IIR: 4ab30048    ISR: 00000000  IOR: 00000024
>>  CPU:        0   CR30: 8ed34000 CR31: ffff55ff
>>  ORIG_R28: 00000000
>>  IAOQ[0]: ide_complete_rq+0x2c/0x70
>>  IAOQ[1]: ide_complete_rq+0x30/0x70
>>  RP(r2): cdrom_newpc_intr+0x178/0x46c
>> Backtrace:
>>  [<1035c608>] cdrom_newpc_intr+0x178/0x46c
>>  [<1034c494>] ide_intr+0x1b0/0x214
>>  [<1016d284>] handle_IRQ_event+0x70/0x150
>>  [<1016d4b0>] __do_IRQ+0x14c/0x1cc
>>  [<102f7864>] superio_interrupt+0x88/0xbc
>>  [<1016d284>] handle_IRQ_event+0x70/0x150
>>  [<1016d4b0>] __do_IRQ+0x14c/0x1cc
>>  [<10112efc>] do_cpu_irq_mask+0x9c/0xd0
>>  [<10116068>] intr_return+0x0/0x4
>>
>> This crash seems to happen due to an uninitialized variable "rc".
>> The compiler even warns about that:
>>   CC      drivers/ide/ide-cd.o                                                         
>> /mnt/sda4/home/cvs/parisc/git-kernel/linus-linux-2.6/drivers/ide/ide-cd.c: In function `cdrom_newpc_intr':
>> /mnt/sda4/home/cvs/parisc/git-kernel/linus-linux-2.6/drivers/ide/ide-cd.c:612: warning: `rc' might be used uninitialized in this function
> 
> can you do
> 
> gdb ./vmlinux
> 
> and then
> 
> (gdb) l *(cdrom_newpc_intr+0x178)
> 
> I think I have a suspect but I want to be sure. In order to do that
> you'll need a debug kernel (set CONFIG_DEBUG_INFO to 'y' in your
> .config). In case the oops above is not from a debug kernel, can you
> catch it again and _then_ do the gdb thing since the offset of 0x178 is
> most probably going to change. In that case, you have to do
> 
> (gdb) l *(cdrom_newpc_intr+NEW_OFFSET_FROM_THE_OOPS)

I tried to build a kernel with CONFIG_DEBUG_INFO.
There are two problem with that, because I'm cross-compiling:
a) I don't have a cross-gdb (but I could use addr2line instead though)
b) the resulting kernel is becoming too big and won't link/boot:
...
  SYSMAP  System.map
  SYSMAP  .tmp_System.map
/sbin/palo -f /mnt/sda4/home/cvs/parisc/git-kernel/linus-linux-2.6-32bit/palo.conf
palo version 1.14 deller@p100 Fri Jul 28 22:55:11 CEST 2006
ELF32 executable
ipl: addr 2048 size 36864 entry 0x0
 ko 0x0 ksz 0 k64o 0x0 k64sz 0 rdo 0 rdsz 0
<>
Your 32-bit-kernel is too big for your F0 partition
make[3]: *** [palo] Error 2

I could now just try to look into the assembly by hand and try
to find which line produces the problem. But reading hppa assembly code
for such a big function is not very easy though.

So, my question would be:
If you have an idea where the problem is, maybe you have a patch for me to try?
That would simplify the whole thing for me a lot, as just compiling/run-testing is much easier for me.

Best regards,
Helge

BTW, even with my patch ATAPI CDROM accesses don't work with the current kernel...

  reply	other threads:[~2009-04-16 20:26 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-04-15 22:45 [PATCH] ide-cd: fix kernel crash on hppa regression Helge Deller
2009-04-16  6:37 ` Borislav Petkov
2009-04-16 20:26   ` Helge Deller [this message]
2009-04-17  6:53     ` Borislav Petkov
2009-04-17  7:15       ` Helge Deller
2009-04-22  6:12         ` Borislav Petkov
2009-04-22 21:13           ` Helge Deller
2009-04-23 21:34             ` Bartlomiej Zolnierkiewicz
2009-04-25 11:19               ` Helge Deller
2009-04-25 14:32                 ` Bartlomiej Zolnierkiewicz
2009-04-25 22:51                   ` Helge Deller
2009-04-26  6:33                     ` Borislav Petkov
2009-04-26  9:52                       ` Bartlomiej Zolnierkiewicz
2009-04-22  6:10 ` Borislav Petkov
2009-04-22 18:27   ` Bartlomiej Zolnierkiewicz

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=49E7945E.7030508@gmx.de \
    --to=deller@gmx.de \
    --cc=bzolnier@gmail.com \
    --cc=kyle@mcmartin.ca \
    --cc=linux-parisc@vger.kernel.org \
    --cc=petkovbb@gmail.com \
    --cc=petkovbb@googlemail.com \
    --cc=rjw@sisk.pl \
    --cc=torvalds@linux-foundation.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.