Hi,
Sometimes do you need to output more then a byte (e.g. when you configure PCI). Now you can use the Pentium i386+ 'outsd' instruction to archive that. Now is my question, are there other ways to archive that data output? Could you do 4 consecutive outb's, or does the CPU expect the data at once and not in several shots? Or is that defined by the device listening to the specific port (I mean, some device could be waiting until the buffer is full, and some other just return an error or something)..
Greets,
Bietje
Other methods of implementing inl/outl
- Owen
- Member
- Posts: 1700
- Joined: Fri Jun 13, 2008 3:21 pm
- Location: Cambridge, United Kingdom
- Contact:
Re: Other methods of implementing inl/outl
You must use the correctly sided access instruction, whether for memory mapped or port IO. If the specification says to do 32 bit writes, do 32 bit writes.
"outl" should be implemented using the "out dx, eax" instruction. "inl" should be implemented using the "in eax, dx" instruction. "outs" and "ins" are for writing multiple values consecutively to an IO port (Generally using a prefix from the "rep" family)
"outl" should be implemented using the "out dx, eax" instruction. "inl" should be implemented using the "in eax, dx" instruction. "outs" and "ins" are for writing multiple values consecutively to an IO port (Generally using a prefix from the "rep" family)
Re: Other methods of implementing inl/outl
That clarifies things,
Thank you
Thank you