[lkml]   [2006]   [Mar]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [RFC, PATCH 16/24] i386 Vmi io header
Eric W. Biederman wrote:
> Zachary Amsden <> writes:
>> Move I/O instruction building to the sub-arch layer. Some very crafty
>> but esoteric macros are used here to get optimized native instructions
>> for port I/O in Linux be writing raw instruction strings. Adding a
>> wrapper layer here is fairly easy, and makes the full range of I/O
>> instructions available to the VMI interface.
>> Also, slowing down I/O is not a useful operation in a VM, so there
>> is a VMI call specifically to allow making it a NOP. I could find
>> no place where SLOW_IO_BY_JUMPING is still used, and consider it
>> obsoleted. Even on older 386 systems, the I/O delay approximation
>> by touching the extra page register is likely to better.
> This sounds like a prime candidate for the alternate instruction interfaces
> and I don't see that being used here.

The problem is that floppy controllers and other crufty hardware
actually do need those slowing port operations to work reliably. If you
look at the usage of slow_down_io, you get scared pretty quick. If you
want your driver to use it, you have the option of defining
REALLY_SLOW_IO in your C file, then suffix your I/O calls with _p. The
definition of SLOW_DOWN_IO actually used to be raw assembly instructions
encapsulated in quotations. I just realized this does actually change
the semantics of drivers/net/de600.c, which really is the only driver
which defines SLOW_IO_BY_JUMPING.

This usage of predefined macros in the driver causing port I/O semantics
to change seems a little strange to try to wrap onto an alternate
instruction interfaces, since it is dependent definitions local to each
.C file, rather than global processor or derived feature bits.

The VMI call wrappers are very much similar to the alternate instruction
interfaces - they just leave the alternative to be defined by the
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2006-03-16 00:36    [from the cache]
©2003-2011 Jasper Spaans