From: Russell King <rmk@arm.linux.org.uk>
To: Zwane Mwaikambo <zwane@holomorphy.com>
Cc: Linux Kernel <linux-kernel@vger.kernel.org>
Subject: Re: 2.5.45 odd deref in serial_in
Date: Tue, 5 Nov 2002 10:20:55 +0000 [thread overview]
Message-ID: <20021105102055.B20224@flint.arm.linux.org.uk> (raw)
In-Reply-To: <Pine.LNX.4.44.0211042323410.27141-100000@montezuma.mastecende.com>; from zwane@holomorphy.com on Mon, Nov 04, 2002 at 11:27:28PM -0500
On Mon, Nov 04, 2002 at 11:27:28PM -0500, Zwane Mwaikambo wrote:
> 0xc023b428 <serial_in+24>: je 0xc023b461 <serial_in+81>
> 0xc023b42a <serial_in+26>: cmp $0x2,%eax
> 0xc023b42d <serial_in+29>: je 0xc023b440 <serial_in+48>
> 0xc023b42f <serial_in+31>: mov 0x8(%ebx),%eax
> 0xc023b432 <serial_in+34>: add %eax,%edx
> 0xc023b434 <serial_in+36>: in (%dx),%al
>
> eax: 00000000 ebx: 81acc5f0 ecx: 00000000 edx: 00000005
>
> ...
> default:
> return inb(up->port.iobase + offset); <--
> }
Ok, if I'm reading this correctly:
offset = %edx
up->port.iobase = 0x8(%ebx)
up = %ebx
To get to this return statement, we would have had to execute:
static _INLINE_ unsigned int serial_in(struct uart_8250_port *up, int offset)
{
offset <<= up->port.regshift;
switch (up->port.iotype) {
which also dereferences "up". So something may have corrupted %ebx
between executing that switch statement and executing the inb().
Could the NMI handler be corrupting %ebx ?
--
Russell King (rmk@arm.linux.org.uk) The developer of ARM Linux
http://www.arm.linux.org.uk/personal/aboutme.html
next prev parent reply other threads:[~2002-11-05 10:14 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-11-05 4:27 2.5.45 odd deref in serial_in Zwane Mwaikambo
2002-11-05 4:38 ` Zwane Mwaikambo
2002-11-05 9:02 ` Russell King
2002-11-05 9:20 ` Zwane Mwaikambo
2002-11-05 10:16 ` Russell King
2002-11-07 15:17 ` David Woodhouse
2002-11-07 15:24 ` Zwane Mwaikambo
2002-11-05 10:20 ` Russell King [this message]
2002-11-05 14:30 ` Zwane Mwaikambo
2002-11-06 3:23 ` Philippe Elie
2002-11-06 8:37 ` Zwane Mwaikambo
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=20021105102055.B20224@flint.arm.linux.org.uk \
--to=rmk@arm.linux.org.uk \
--cc=linux-kernel@vger.kernel.org \
--cc=zwane@holomorphy.com \
/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.