lkml.org 
[lkml]   [1996]   [Sep]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: writing to POST leds?


On Sun, 8 Sep 1996, Edward Welbon wrote:
>
> > However, the SLOW_DOWN_IO code in
> > asm/io.h writes random values to port 0x80, which tends to obscure the values
> > written by users.
>
> Oh yeah... Darn. Is this necessary? Can I change these calls back to the
> jumps or maybe to another address?

It is necessary for the "generic" kernel, because 0x80 is the only safe
IO port I know of that is guaranteed to not be used for any device that
could be hurt by it.

However, for a custom kernel (and you'd want to make a custom kernel for
driver debugging anyway) there is nothing very sacred about the 0x80 number,
or even about the outb in general. On most machines you don't need to do any
slowdowns at all (note the /MOST/. That's why we need to have it in the
generic kernel).

> How about a read CPUID, that is
> synchronizing and should slow down things nicely (though it does change a
> register... uk, never mind)? Would a write back invalidate of the
> current instruction L1 cache line be OK? That should cause a nice slow
> down.

Note that the "outb 0x80" is not just a small slowdown. It's a _huge_
slowdown. It's on the order of 1us, because that is generally what is safe.

But for personal testing you should be able to just remove it altogether.
Don't worry too much (unless you start seeing problems with drivers).

Linus

\
 
 \ /
  Last update: 2005-03-22 13:37    [W:0.042 / U:1.724 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site