Subject: bus_space_write_multi_* problems on i386
To: Chris G. Demetriou <>
From: Dave Huang <>
List: tech-kern
Date: 08/12/1997 20:05:28
On Tue, 12 Aug 1997, Chris G. Demetriou wrote:
> > I think it's a gcc optimizer bug, but I'm not sure... it looks like gcc
> > isn't paying attention to the list of registers that are used by the
> > __asm() code in bus_space_write_multi_4. The following demonstrates the
> > bug when compiled with -O or -O2:
> > [ ... ]
> This is interesting, but it may be unrelated to your problem (if
> you're using the wrong function 8-)
> I wonder if anybody is still seeing reboot problems with the lpt
> driver...

The lpt driver doesn't seem to use the write_multi functions... however,
if_ed.c does, and gcc's messing up on the bus_space_write_multi_2 on line
2369. It does the lodsw, then movw %ax, (%eax). Strangely, I haven't
noticed any problems on my 386 with NE2000 clone. Perhaps it's only using
the I/O ports, and not the card's shared memory space? I have "ed0 at isa?
port 0x300 iomem 0xcc000 irq 10" in my kernel config, but the boot message
only shows "ed0 at isa0 port 0x300-0x31f irq 10".
