qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH] Implement PC port80 debug register.


From: Jamie Lokier
Subject: Re: [Qemu-devel] [PATCH] Implement PC port80 debug register.
Date: Mon, 29 Jun 2009 22:53:45 +0100
User-agent: Mutt/1.5.13 (2006-08-11)

Avi Kivity wrote:
> On 06/29/2009 06:26 PM, Jordan Justen wrote:
> >Avi,
> >
> >Well, I am not sure if this it globally the case for PC motherboards, 
> >but in my experience, it has been read/write.
> 
> It's just some random memory that might not actually be grounded in reality.

It is not memory, and it's not even an I/O port.

On many PCs, at least historically, it resolves to an ISA bus cycle
which no device responds to, and therefore takes about 1 microsecond
with side effects which help some ISA devices (on other I/O ports) to
work.  Including 2MHz ISA devices on an 8MHz ISA bus... so it has to
be a port which isn't on the device it's helping :-)

(Good) modern chipsets tend to not need the delay or side effects, but
they emulate the delay anyway.

When an ISA BIOS POST debugging card is plugged in, or if there's one
on the motherboard, then it catches the writes and displays them as
hex on LEDs.  That changes the timing and can in principle break some
things...

Some Linux distros write to port 0xed instead of 0x80 now, because
some HP/Compaq laptops break when writing to port 0x80 after ACPI is
enabled.  (Silly BIOS bugs).  But 0xed breaks some old ISA systems,
because it doesn't have quite the same bus side effects.  Enjoy.

> >At least for a system such as qemu, it make it difficult to use the 
> >port80 checkpoint of software without being able to read the last 
> >value written.
> 
> Why would software ever need to read it?  You want a monitor command so 
> the user can read it.  I don't recall ever seeing a read of port 80 (I 
> don't have any objections to that though).

Because most ISA PCs don't have anything there, reading won't return
anything interesting.  It won't return the value written.

But maybe with a BIOS POST debugging card, and/or maybe with some 
chipsets which are emulating the port... I don't know.

-- Jamie




reply via email to

[Prev in Thread] Current Thread [Next in Thread]