On Tue, Sep 23, 2008 at 11:30:32AM -0500, Anthony Liguori wrote:
>
>> + + (addr - r_access->e_physbase);
>> +
>> + if (r_access->debug & DEVICE_ASSIGNMENT_DEBUG_PIO) {
>> + fprintf(stderr, "%s: r_pio=%08x e_physbase=%08x"
>> + " r_virtbase=%08lx value=%08x\n",
>> + __func__, r_pio, (int)r_access->e_physbase,
>> + (unsigned long)r_access->r_virtbase, value);
>> + }
>> + iopl(3);
>> + outb(value, r_pio);
>>
>
> The formatting is wrong for this entire file. Also, you shouldn't
> have device specific debug. Should probably error check iopl(3).
> It's not necessary to call it every time you do an outb, just once
> when initialized.
We tried that at first, but ran into cases where even after iopl()
ran, pio's from qemu still failed. Does qemu do anything to drop
iopl() privileges? In any case calling iopl() unconditionally on every
pio fixed it, but is obviously not the right long-term solution.
Cheers,
Muli
--
The First Workshop on I/O Virtualization (WIOV '08)
Dec 2008, San Diego, CA, http://www.usenix.org/wiov08/
xxx
SYSTOR 2009---The Israeli Experimental Systems Conference
http://www.haifa.il.ibm.com/conferences/systor2009/
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html